Commit Graph

116975 Commits

Author SHA1 Message Date
itojun 186bd1ad6a initialize fragment ID with arc4random, not by time.tv_sec 2003-09-05 22:09:38 +00:00
itojun 761c22ff58 use arc4random instead of random (mask with INT32_MAX to avoid getting
negative numbers unexpectedly).
2003-09-05 21:58:35 +00:00
itojun 3efe781f15 plug memory leak. PR bin/22694 2003-09-05 20:16:50 +00:00
dsl fc3574d3bf Correctly fix pty majors 2003-09-05 17:11:30 +00:00
dsl 35bb292640 Put back port specific majors for ptys 2003-09-05 17:02:52 +00:00
bouyer d2c13c7513 width needs to be updated before each loop, because svc_maxfd may have
changed.
2003-09-05 14:59:37 +00:00
simonb a409be525d Fix a tyop. 2003-09-05 14:52:26 +00:00
pooka 8446050ba0 Add support for loading firmware to a controller using the firmware
keyword in the controller section (kernel counterpart already exists).

similar to what's in FreeBSD
2003-09-05 13:31:03 +00:00
mycroft 4d89e946a7 Some of the table entries are now noops. Remove them. 2003-09-05 11:24:56 +00:00
mycroft 61c35f890c Take vigilante action and remove all the NO_MAX_LUN, NOMODESENSE and
NOBIGMODESENSE "quirks".  These problems should be fixed without klugery
now.
2003-09-05 11:18:25 +00:00
mrg 71889b67f5 make sure we build the unwind handlers with "-fexception". they were
supposed to, but the wrong variable was used as a base...

should fix PR#22673.
2003-09-05 09:54:30 +00:00
tron 1b7c775558 Add a few more devices which are known to work with this driver.
Some of them were suggested by Rich Neswold in PR kern/22684.
2003-09-05 09:04:40 +00:00
mycroft 80605e4feb Use SMS_DBD in a several places to avoid even thinking about block descriptors. 2003-09-05 09:04:26 +00:00
mycroft 677da6684c Forgot to commit this. Add the "rpm" field to the flex geometry page. 2003-09-05 09:00:08 +00:00
tron 90ef1d5718 From FreeBSD as suggested by Nicolas Joly in PR kern/22682:
Do not initalize the LED's to 0x00.  The default configuration
the chip comes up in should yeild proper operation of the LED's.
2003-09-05 08:53:23 +00:00
mycroft 5c195383ca In addition to skipping a variable-length list of block descriptors, we also
have to adjust for whether he have a "small" or "large" mode sense response.

sd_scsibus_getcache(), sd_scsibus_setache(): Set SMS_DBD so that we don't
have to deal with block descriptors here.

sd_scsibus_mode_sense(): Add a new parameter, "int *big", which tells the
caller whether it's a small or large header.

sd_scsibus_get_parms(), sd_scsibus_getcache(), sd_scsibus_setcache(): Use
the "big" value to find the data following the mode sense header correctly.

sd_scsibus_mode_sense(): Disable PQUIRK_NOBIGMODESENSE for now, as the
reasons for it were dubious and most likely fixed now.

sd_scsibus_get_parms(): Now that we're actually locating the right data,
check the returned page code to see if it's correct before using the mode
page info.

sd_scsibus_get_parms(): Get the rotational rate from the flex geometry page
too, if present.

XXX sd_scsibus_get_{opt,simplifiedparms}() need some work.
2003-09-05 08:12:09 +00:00
wiz 91f2a1b827 Whitespace nits. 2003-09-05 06:55:46 +00:00
sjg 9ab525fdf0 Allow -V '${FOO}' to print the expanded version of FOO.
A side effect of adding and removing a -E option for the above is that
the cases in MainParseArgs are now ordered correctly?
2003-09-05 06:52:11 +00:00
itojun 891811de60 add DIAGNOSTIC check for AN_DEFAULT_xx 2003-09-05 05:38:44 +00:00
matt d671884ac3 pty (pts) is major 4, not 6 2003-09-05 03:10:36 +00:00
itojun 95b95dbc37 call tcp_drain() if IPv4-less kernel 2003-09-05 01:35:08 +00:00
mycroft a9e1f75ec7 Several changes to eliminate bogus controllers and sockets from being found:
PCIC_VENDOR_NONE: New.
PCIC_VENDOR_CIRRUS_*: Collapse the 2 chips into one vendor ID.

pcic_ident_ok(): Check the ID revision field -- if it's 0, punt.

pcic_vendor(): Check the ID revision field -- if it's 0, or the ID register
is all-1s, assume there is no chip present.  (Previously this would return
"Unknown controller" -- which, AFAICT, *never* resulted in a working device.)
Do the Cirrus check only after verifying that we got the Intel ID.

pcic_attach(): Use a priori knowledge of the Cirrus chips to determine the
number of sockets rather than trying (unsuccessfully) to probe.  Also, just
blast all of PCIC_INTR -- we do this in pcic_deactivate_card() anyway.
2003-09-05 01:02:51 +00:00
mycroft 8b228f0d42 sd_scsibus_get_parms():
* Use the "block descriptor length" to find the beginning of the mode page
  data.  This is critical, since some devices do not return a block descriptor
  at all.  (XXX There is disgusting structure hackery here.)
* Always use scsipi_size() (i.e. READ CAPACITY) to get the total disk size.
* Get the rotational rate from the rigid geometry page.
* Don't read the block size from the block descriptor if there was none.
* Get the block size from the flexible geometry page if possible.
* If we don't like the way page 4 smells, try page 5, rather than just punting.
2003-09-05 00:28:55 +00:00
thorpej 2f2b9c7cb0 GMII works on the i82543 now. 2003-09-04 19:32:19 +00:00
wrstuden d9f694842d Adjust struct sockbuf and sorflush() so that we don't zero out
every field; some need to stay around.

Fixes a bug where by calling shutdown() on a socket with knotes
will cause the kernel to panic when the kernel closes the socket.
Other access, such as calling kevent() may also trigger the panic.

Debugged with help from Jason and Allen. Patch reviewed by same plus
Itojun and Matt Thomas.

This problem seems to be the same one that FreeBSD saw in their PR
number 54331.

Kernel version _not_ bumped as we will piggyback the bump earlier today.
2003-09-04 16:44:05 +00:00
itojun 3f4f8a9b61 s/0x7fffffff/INT32_MAX/ 2003-09-04 15:31:58 +00:00
itojun bb71295ab0 use arc4random(3). it is at least better than random(3)
XXX masked topmost bit so that values don't go negative, is it the right thing
to do?
2003-09-04 15:30:37 +00:00
tsutsui 419db7b25c Shingo WATANABE has kindly consented to remove advertising clauses
from his code.
2003-09-04 15:26:35 +00:00
tsutsui 4189ddf652 Remove advertising clauses from code written by Shingo WATANABE.
He has kindly consented it.
2003-09-04 15:17:38 +00:00
yamt 01e41ddfe3 don't call LFS_DEBUG_COUNTLOCKED after bread().
lfs_countlocked doesn't count buffers that isn't on the freelist.
2003-09-04 12:28:53 +00:00
he 9ac0a9ed26 Um, undo last; libsa printf doesn't do %z. 2003-09-04 12:02:10 +00:00
he bd42895755 Use the %zu format for size_t printing instead of cast + %lu. 2003-09-04 11:42:52 +00:00
dsl fe89b1db32 Add memcmp, memcpy and memset
Fix strncmp(x, y, 0)
Use unsigned compares for strcmp and memcmp (and bcmp).
Compiles but untested
AFAICT http://h71000.www7.hp.com/doc/72final/4515/4515pro_025.html#4515ch9_146
cmpc3/5 set %r4 and %r5 to zero, It doesn't look as though the procedure
call is set to preserve these, and I doubt that gcc is treating them as
scratch registers - does our vax pcs actually have %r2 and %r3 as scratch regs?
2003-09-04 10:40:44 +00:00
itojun 0162be23d0 synchronize w/ inpcb/in6pcb change 2003-09-04 09:23:35 +00:00
wiz 1579d37ceb In `openfiles' attribute, clarify that it's the number of open file
descriptors (which could include sockets, etc.).
From jmc@openbsd.
2003-09-04 09:19:36 +00:00
itojun cdb260b823 welcome to 1.6Y (for inpcb/in6pcb change) 2003-09-04 09:17:40 +00:00
itojun 495906ca8e revamp inpcb/in6pcb so that they are more aligned with each other.
in6pcb lookup now uses hash(9).
2003-09-04 09:16:57 +00:00
wiz dea83a9f43 Clarify that the user's full name (not username) goes into the GECOS field.
From Jeff Ross via jmc@openbsd.
2003-09-04 08:37:59 +00:00
lukem 959cbfd166 revert previous; there's too much hairy crap in sys/lkm/compat involving
the order that Makefile.inc is pulled in to get this to work.

this stuff needs a rototill (for another day). for example, having every
sys/lkm/** directory make their own  machine ${MACHINE_CPU} and possibly
${SHARED_MACHINE_CPU} (e.g, x86 for i386/x86_64) is not the most optimal
situation ...
2003-09-04 08:27:08 +00:00
mrg 70ab3cd1bf make "sh64--netbsdelf" use 32 bit by default. per advice from thorpej. 2003-09-04 08:04:18 +00:00
lukem 7237dbc136 missing rcsid 2003-09-04 07:51:21 +00:00
christos a0e952bddb bump the buffer size from 15 to 63 bytes. 2003-09-04 07:46:47 +00:00
lukem f7fe23abb3 use LNFILES to simplify creation of symlinks in .OBJDIR for builds 2003-09-04 07:18:01 +00:00
lukem f212488840 simplify include symlink creation with LNFILES 2003-09-04 07:15:43 +00:00
lukem 49fb32cb30 use LNFILES instead of homegrown equivalent 2003-09-04 06:42:50 +00:00
mrg 57b205e71d in-tree toolchain support for sh5el. not really tested yet, but it
seems to mostly work..  libcurses.so fails to link with an out of memory
error i haven't looked at yet, and nothing has actually been run..

XXX: gdb53 missing.
2003-09-04 04:34:14 +00:00
matt 12588bd8b6 Adapt to the new calling conventions of unp_connect2 2003-09-04 04:33:49 +00:00
matt e3bf7b7e7d Adjust to the new calling convention of unp_connect2. 2003-09-04 04:30:25 +00:00
mrg cd7d35dbec install a "cccp" man page for now. 2003-09-04 04:19:08 +00:00
mrg 02fdaf3a7a backout rev 1.16 (wrong tree), and 1.17 and 1.18 trying to fix 1.16... 2003-09-04 04:17:01 +00:00