Commit Graph

81366 Commits

Author SHA1 Message Date
Archie Cobbs
5f384e6a34 Add MLINKS to kse.2. 2002-10-08 17:43:40 +00:00
Kenneth D. Merry
ead5f16cef Fix the location of the length bytes in the 12-byte read/write CDB
structure.  This has been broken since 1998, but probably hasn't been
noticed because it takes a read/write of 64K blocks (32MB with 512 byte
blocks) to trigger using the 12 byte read/write CDB in scsi_read_write().

Submitted by:	"Moore, Eric Dean" <emoore@lsil.com>
MFC after:	3 days
2002-10-08 17:12:44 +00:00
Poul-Henning Kamp
c80ba0ad1b Now that ufsread.c doesn't do 64bit divide remainder operations,
don't bother with libkern.

Sponsored by:	DARPA & NAI Labs.
2002-10-08 15:49:35 +00:00
Poul-Henning Kamp
26baf05377 Save a couple of bytes by not returning ints nobody care about.
Sponsored by:	DARPA & NAI labs
2002-10-08 15:48:43 +00:00
Poul-Henning Kamp
7cf5744b6b It seems that the only problem with UFS2 booting on i386 is the 64bit
divide/remainder calls.  For reasons not resolved, compiling the
relevant routines from libkern into boot2 results in stack corruption.

Do the simple thing: Don't use 64bit divide/remainder operations.

Sponsored by:	DARPA & NAI Labs
2002-10-08 15:46:45 +00:00
John Baldwin
422971d7d9 Don't panic for a bad ivar request, just return ENOENT. 2002-10-08 15:44:35 +00:00
Yoshihiro Takahashi
cee67b9980 MFi386: revision 1.67. 2002-10-08 12:54:56 +00:00
Yoshihiro Takahashi
de62287d07 MFi386: revisions 1.539, 1.540 and 1.541. 2002-10-08 12:53:26 +00:00
Yoshihiro Takahashi
6d8c8fabad Fix to support pc98. 2002-10-08 12:13:19 +00:00
Brian Feldman
3cfeca5326 Reinstate rev 1.36 with an important line that got missed. Note this
also improves the "random undocumented offsets into various memory
spaces" a little bit.
2002-10-08 12:09:16 +00:00
Tim J. Robbins
c121fd80b8 Do not strip CTL* escapes from redirection filenames in argstr(); they
are later stripped with rmescapes() in expandarg(). If the filename has
already been unescaped, doing it again in rmescapes() can walk off the
end of the string, leading to memory corruption and eventually SIGSEGV.

Noticed by:	kris
2002-10-08 11:22:49 +00:00
Poul-Henning Kamp
ae02ceb621 Remove unused TYPE_WD and TYPE_WFD. 2002-10-08 10:17:16 +00:00
Poul-Henning Kamp
ed025d6983 Correctly calculate dmadat: We need to take the address of _end, it's
contents is irrelevant and likely to be zero;

This doesn't change the resultant value, but it does save a couple of bytes
because &_end is constant.
2002-10-08 10:15:42 +00:00
Juli Mallett
d06c7584b6 Make it possible to kldload(8) many modules.
MFC after:	2 months
Sponsored by:	Bright Path Solutions
Reviewed by:	tjr
2002-10-08 09:57:03 +00:00
Poul-Henning Kamp
a201162d71 Unbreak boot2 by backing out rev 1.36 to Makefile, which does not
work as advertised:

	bang# pwd
	/bang/src/sys/boot/i386/boot2
	bang# make clean >& /dev/null
	bang# cvs -q update -r 1.35 Makefile >& /dev/null
	bang# make >& /dev/null
	bang# cat /usr/obj/`pwd`/boot2.h
	#define XREADORG 0x725
	bang# cvs -q update -r 1.36 Makefile > & /dev/null
	bang# make clean > & /dev/null
	bang# make > & /dev/null
	bang# cat /usr/obj/`pwd`/boot2.h
	#define XREADORG 0x25
	bang#
2002-10-08 07:52:28 +00:00
Poul-Henning Kamp
943e5db958 Allow for multiple #includes of this file. 2002-10-08 07:24:19 +00:00
Poul-Henning Kamp
68541f7c16 Save four bytes by shortening a string two chars.
Sponsored by:	DARPA & NAI Labs.
2002-10-08 07:06:24 +00:00
Poul-Henning Kamp
068088370c For now, don't wait for drives to stop returning EBUSY. There is too
much broken harware around it seems.

Sponsored by:	DARPA & NAI Labs.
2002-10-08 07:03:58 +00:00
Murray Stokely
8595a93d04 FreeBSD 4.7 enters the BSD family tree sometime on October 8, 2002. 2002-10-08 05:25:58 +00:00
Bruce A. Mah
b07931e581 Teach pkg_add -r how to find 4.7-RELEASE packages with an appropriate
osreldate.

(Actually, due to differences in package compression formats, I'm
not sure that a -CURRENT pkg_add -r will do the right thing in
this case, once it finds them.)
2002-10-08 05:15:21 +00:00
Murray Stokely
4760a4b25e We now use XFree86-4 packages rather than a special XFree86-3
distribution, so this script is no longer needed.
2002-10-08 05:06:05 +00:00
Dima Dorfman
e5d09546b8 Treat the pathptrn field as a real pattern with the aid of fnmatch(). 2002-10-08 04:21:54 +00:00
Dima Dorfman
20a6cb8cb8 Import the libc fnmatch() into the kernel. This will be used by,
among other things, the DEVFS rule subsystem to match nodes against a
path pattern supplied by the user.

fnmatch.c was repo-copied from src/lib/libc/gen/fnmatch.c, and the
only changes to it are those necessary to make it compile in the
kernel.  The relevant parts of fnmatch.h were imported into libkern.h.

Approved by:	-arch
2002-10-08 04:15:55 +00:00
Warner Losh
c4598a8916 Make kldunload cbb work:
o Implement the thread killing interlock as described by jhb in arch@
  while talking to markm.
o Hold Giant around cbb_insert()/cbb_remove().  Deep in the belly of
  the vm code we panic if we don't hold this when we activate the memory
  for reading the CIS.
o If we had to do the kludge alloc, then do a kludge free.
2002-10-08 03:53:52 +00:00
Alexander Kabaev
7d59efa9a8 Add device driver for Belkin F5U103 and compatible USB-to-serial adapters.
Reviewed by:	n_hibma
Approved by:	obrien
2002-10-08 03:09:57 +00:00
Alexander Kabaev
139b2d67cd Regen after usbdevs rev. 1.102.
Reviewed by:	n_hibma
Approved by:	obrien
2002-10-08 03:04:14 +00:00
Alexander Kabaev
469f01ba8c Add entries for:
Belkin F5U103
	Belkin F5U120-PC Hub
	GoHubs GoCOM232
	Peracom single port
USB-to-serial adapters.

Reviewed by:	n_hibma
Approved by:	obrien
2002-10-08 03:00:37 +00:00
Tim J. Robbins
363a99169a Re-add the code which maps POSIX standard library names into the ones
FreeBSD uses; f.e. -lpthread -> -pthread, -lxnet -> nothing.
2002-10-08 02:19:54 +00:00
Warner Losh
0b294f891d Introducing /dev/devctl. This device reports events in the
configuration device hierarchy.  Device arrival, departure and not
matched are presently reported.  This will be the basis for devd, which
I still need to polish a little more before I commit it.  If you don't
use /dev/devctl, it will be a noop.
2002-10-07 23:17:44 +00:00
Warner Losh
c17fdbe3a9 Two minor bugfixes:
o Allow the bus_debug variable to be set via the bus.debug tunable.
o Return pnpinfo and location info via the devinfo interface to userland.
  devinfo(8) needs to be updated to print it.
2002-10-07 23:15:40 +00:00
Warner Losh
01d8ff4dfd MFp4:
o Better resume code.  Move the comments around.  Force the socket state to
  be querried.  Ack the interrupts properly.
o Intercept the interrupt requests and keep a list of interrupts to service
  ourselves.  When the card attaches, set its OK bit.  When we get a card
  status change interrupt for that card, clear the OK bit.  Don't call the
  ISR if the OK bit is cleared.  Iwasaki-san and yamamoto-san have both
  sent me patches that fix the same problem this fixes, but at the pccard
  level.
o Try to get the signalling of the thread to actually die.  This might not be
  100% right, but it is less wrong than before.
o Add a SIC next to a TI type that looks like it could be wrong, but isn't.
2002-10-07 23:11:29 +00:00
Warner Losh
3688a119c4 o Add a nomatch routine so we whine when we don't know what to attach to
the card.
o Add comments about how we're doing the CIS activation.
o Add location and pnp info functions.
o Add better code to hopefully deal with ata cards better (and other drivers
  that allocate resources that we didn't preallocate from the CIS).  OLDCARD
  used to allow it, but NEWCARD was pickier.  I'm not 100% sure this works,
  but it doesn't break anything.
2002-10-07 23:05:33 +00:00
Warner Losh
a95bed74b3 Merge changes from NetBSD through version 1.17 of this file. These
give us slightly better error checking than before and interpret what
default bits mean better.  See the NetBSD CVS tree for the authors of
these changes (revs 1.10 .. 1.17).
2002-10-07 23:03:17 +00:00
Warner Losh
aa7bc3b3fc o Add routines to return the location and pnpinfo for this card.
Note, we return the PCI pnp info, but in fact that's wrong to do
  since that data is not defined for CardBus cards.  CardBus says that
  these registers are undefined and one should use the CIS to do
  device matching.  To date, all CardBus cards have had these
  registered defined, no doubt because they are using common silicon
  to produce both the PCI cards and the CardBus cards.  However, it isn't
  any worse than the rest of the system, so just note it in passing and
  move on.
o Also sort prototypes while I'm here.
2002-10-07 23:00:51 +00:00
Warner Losh
0a9e69cc6f Don't abuse the fact that -a == ~a + 1. Signed vs unsigned checkers
complain when a is a unsigned type.  So instead use the latter here
and be on our way.

Spotted by: flexlint by way of phk
2002-10-07 22:58:24 +00:00
Warner Losh
c5d5c855b7 Add extra set of parens around the barbit macro to make it clear what
we're intending to shift.

Spotted by: flexlint by way of phk (should fix about 40 messages)
2002-10-07 22:57:07 +00:00
Brian Feldman
6c598ff615 Correct a bug in adding 0x700 to a number. 2002-10-07 22:21:16 +00:00
Poul-Henning Kamp
15cfc1833c Conditionalize the number of sectors loaded by boot1.s on UFS1/UFS12.
Conditionalize the "XX bytes left" checks reference on UFS1/UFS12.

Conditionally build the necessary 64bit math for boot2 if UFS12.

Sponsored by:	DARPA & NAI Labs.
2002-10-07 21:36:06 +00:00
Mike Barcroft
5b0f380cdd Remove duplicate uninstalled aio.h header. 2002-10-07 21:18:30 +00:00
Thomas Quinot
2aeb6b2708 Document behaviour change in reboot(8) introduced in reboot.c rev. 1.17:
when using '-p' with reboot, and the power down action failds, reboot
the system normally. The behaviour of 'halt -p' and of shutdown(8) is
unchanged.

Approved by:	roberto
2002-10-07 21:18:20 +00:00
Poul-Henning Kamp
b410146034 Change the comment character from # to // in boot1.s and run
it through CPP so we can conditionalized things.

Sponsored by:	DARPA & NAI Labs
2002-10-07 20:56:09 +00:00
Ian Dowse
197b023b1b Add back a fdrop() call at the end of kern_open() that got lost in
revision 1.218. This bug caused a "struct file" reference to be
leaked if VOP_ADVLOCK(), vn_start_write(), or mac_check_vnode_write()
failed during the open operation.

PR:		kern/43739
Reported by:	Arne Woerner <woerner@mediabase-gmbh.de>
2002-10-07 20:49:22 +00:00
Sam Leffler
f96d19da13 Track openbsd changes that don't affect us yet (PK supoprt is
currently disabled):

o Don't use constants for the output parameter, use the iparam count as a
  pointer to the first result location.
o Fix bits vs bytes counting problems.
o Split out the hardware and software normalization versions of modexp.
o Enable hardware normalization for chips that support it.
o On reset, disable hardware normalization for 582x and make sure the
  chip is in little endian mode.
o Since sw normalization is now the only option, simplify normalization
  handling.

Also fix RNG harvesting: disabling PK support (for the moment) had disabled
the MCR2 interrupt; consider both KEY support and RNG support when deciding
whether or not to enable it.

Obtained from:	openbsd
2002-10-07 20:02:34 +00:00
Poul-Henning Kamp
10aabd9039 Correctly adjust for moved start address.
It seems that the existence of a "depend" target in src/sys/boot is not
to be taken as an indication that it actually does what one would expect,
at least it clearly threw my testing off.

Apologies to:	jhb
2002-10-07 19:12:36 +00:00
Sam Leffler
1a91ccccc6 o split crypto_proc into two threads: one for processing requests and one
for processing callbacks.  This closes race conditions caused by locking
  too many things with a single mutex.
o reclaim crypto requests under certain (impossible) failure conditions
2002-10-07 18:46:38 +00:00
Sam Leffler
b4c408e0fe remove CIOGSSESSION (get software session); it was added only for testing 2002-10-07 18:37:31 +00:00
Mike Barcroft
9383ade4b0 Remove unneeded <sys/_posix.h> include. 2002-10-07 17:31:02 +00:00
Yoshihiro Takahashi
8b16930349 Added '#include <sys/diskpc98.h>'.
Submitted by:	kawanobe@st.rim.or.jp (Kawanobe Koh)
2002-10-07 15:26:10 +00:00
Poul-Henning Kamp
dfaf0d8cf1 Correctly compensate for both offset and unoffset on-disk BSD disklabels.
Sponsored by:	DARPA & NAI Labs.
2002-10-07 13:11:28 +00:00
Yoshihiro Takahashi
88b2247e41 Merged from sys/isa/fd.c revisions 1.224 and 1.241. 2002-10-07 13:05:45 +00:00