Marcel Moolenaar [Wed, 25 Aug 1999 15:23:54 +0000 (15:23 +0000)]
Fix linux_newlstat in that it doesn't return the attributes of its containing
directory. Also, update arguments of NDINIT for both newstat and newlstat.
While I'm at it, fix style bugs in all {s|ls|fs}tat syscalls.
Marcel Moolenaar [Wed, 25 Aug 1999 14:11:01 +0000 (14:11 +0000)]
Fix {g|s}etgroups semantics. We use cr_groups[0] to hold egid. This means that
egid will be twice in the set and that setting cr_groups[0] will change egid.
This is simply solved by ignoring cr_groups[0]. That is; linux_getgroups does
not return cr_groups[0] and linux_setgroups does not touch it.
Noticed by: bde
Brought to my attention by: sheldonh
Marcel Moolenaar [Wed, 25 Aug 1999 11:19:03 +0000 (11:19 +0000)]
Change all UNIMPL syscalls to STD and add them to linux_dummy. Now we always
know if and when an unimplemented or obsoleted syscall is being used. Make the
message more end-user friendly.
And as long as we're here, rename some unimplemeted syscalls (linux_phys ->
linux_umount2, linux_vm86 -> linux_vm86old, linux_new_vm86 -> linux_vm86).
Change prototype for linux_newuname from `struct linux_newuname_t *' into
`struct linux_new_utsname *'. This change is reflected in linux.h and
linux_misc.c.
Marcel Moolenaar [Wed, 25 Aug 1999 11:17:36 +0000 (11:17 +0000)]
Change all UNIMPL syscalls to STD and add them to linux_dummy. Now we always
know if and when an unimplemented or obsoleted syscall is being used. Make the
message more end-user friendly.
And as long as we're here, rename some unimplemeted syscalls (linux_phys ->
linux_umount2, linux_vm86 -> linux_vm86old, linux_new_vm86 -> linux_vm86).
Change prototype for linux_newuname from `struct linux_newuname_t *' into
`struct linux_new_utsname *'. This change is reflected in linux.h and
linux_misc.c.
Lastly, make line-continuation and indentation more uniform.
Marcel Moolenaar [Wed, 25 Aug 1999 09:05:29 +0000 (09:05 +0000)]
Fix stack misalignment for Linux binaries caused by `linux_sigcode' not being
a multiple of 4 bytes in size. This solves the recent SIGBUS errors for
glibc2.1 configurations.
Peter Wemm [Wed, 25 Aug 1999 06:44:32 +0000 (06:44 +0000)]
Use the far jump for the base of the page arithmatic rather than the
calling function, otherwise Bad Things Happen(tm) when bios16_call is
not in the same page as bios_jmp.
Bruce Evans [Wed, 25 Aug 1999 03:01:54 +0000 (03:01 +0000)]
Don't open the swap file. The open descriptor for it hasn't been used
for over 5 years since we switched to using procfs for kvm_uread().
This cleanup was motivated by recent breakage of the default swap file
(/dev/drum) when swapon() has not been called.
Julian Elischer [Wed, 25 Aug 1999 02:04:40 +0000 (02:04 +0000)]
Make DEVFS ops reflect some of the changes that have recently occured in the
specfs version of the same ops. Merging with phk's dev_t changes is not yet
complete.
i.e. devfs still uses it's own devsw pointer rather than following
devsw(a_vp->v_rdev), and it's own copy of the dev_t.
This fixes some broken actions re: syscons and DEVFS due to bitrot in
devfs vops.
Mike Smith [Tue, 24 Aug 1999 16:42:08 +0000 (16:42 +0000)]
Work around a bad design in some PnP BIOS code whereby the BIOS can reach
off the top of our constructed stack segment while it's trying to copy a
maximally-sized PnP argument frame around.
Sheldon Hearn [Tue, 24 Aug 1999 08:39:41 +0000 (08:39 +0000)]
Fix bug introduced in rev 1.28, which causes kernel build to break for
the case where DEBUG is defined but not DIAGNOSTIC. ffs_checkblk is
declared conditionally on DIAGNOSTIC, not DEBUG.
Brian Feldman [Tue, 24 Aug 1999 05:58:35 +0000 (05:58 +0000)]
When the SYSINIT() was removed, it was replaced with a make_dev on-demand
creation of /dev/drum via calling swapon. However, the make_dev has a
bogus (insofar that it hasn't been added yet) cdevsw, so later we end
up crashing with a null pointer dereference on the swap vp's specinfo.
The specinfo points to a dev_t with a major of 254 (uninitialized), and
we get a crash on its d_strategy being called.
The simple solution to this is to call cdevsw_add before the make_dev
is ever used. This fixes the panic which occurred upon swapping.
Kazutaka YOKOTA [Tue, 24 Aug 1999 04:26:54 +0000 (04:26 +0000)]
Correct the mode information for the VGA mode X.
- This mode uses four planes rather than one.
- "# of bytes in a scan line" = "# of pixels in the line"/2
Bill Paul [Tue, 24 Aug 1999 03:19:45 +0000 (03:19 +0000)]
Change PN_RXLEN from 1518 bytes to 1536 bytes. The chip always DMAs data
in 4 byte chunks. It turns out that with the 82c169C on the Netgear
FA-310TX Rev D2, if you tell the chip you have reserved a buffer of 1518
bytes, it will actually treat it as 1516 bytes since 1518 is divisible
by four. Consequently, a packet of 1514 bytes will always end up consuming
two buffers: the last coupleof bytes will spill over into the next
descriptor. This causes the pn_rx_bug_war() routine to trip unnecessarily.
I'm not sure if the 82c169B or 82c168 chips behave the same way; I'll
have to check them. In any case, this change should work just as well
with them. Note that the FA-310TX Rev D2 also has a Broadcom PHY
instead of a Level One LXT970 PHY, however this shouldn't make any
difference as far as the driver is concerned.
This change also allows me to do a way with one rounding overation in
pn_rx-buf_war().
Greg Lehey [Tue, 24 Aug 1999 02:31:19 +0000 (02:31 +0000)]
Tidy up some indentation and comments.
vinum_init(): Change name of variable plexindex to objindex, which
better describes its purpose.
initsd(): Add a second parameter to determine whether it should wait
for completion or not. This allows it to DTRT when called
with the -w flag either directly or via initplex().
Add 'setstate' command (function vinum_setstate ()) to implement the
VINUM_SETSTATE_FORCE ioctl for diddling individual object states.
This is a repair tool which can also be used for panicing the system.
Use with utmost care if at all.
Add unimplemented commands 'checkparity' and 'rebuildparity'. Watch
this space.
Greg Lehey [Tue, 24 Aug 1999 02:29:41 +0000 (02:29 +0000)]
set_sd_state: Correct the conditions for bringing up empty or
initialized subdisks.
Tidy up some comments.
Eliminate sddownstate(); it wasn't being used any more. Return
REQUEST_DOWN instead.
Add setstate_by_force() to implement the VINUM_SETSTATE_FORCE ioctl
for diddling individual object states. This is a repair tool which
can also be used for panicing the system. Use with utmost care if at
all.
Greg Lehey [Tue, 24 Aug 1999 02:28:37 +0000 (02:28 +0000)]
Lock stripes of striped and RAID-5 plexes before writing them. This
avoids a race condition where multiple RAID-5 subdisks are being
revived at the same time. The locks should also prevent conflicts
with user requests on concatenated and striped plexes, but this needs
more work.
Greg Lehey [Tue, 24 Aug 1999 02:26:15 +0000 (02:26 +0000)]
Add VINUM_SETSTATE_FORCE ioctl for diddling individual object states.
This is a repair tool which can also be used for panicing the system.
Use with utmost care if at all.
Greg Lehey [Tue, 24 Aug 1999 02:20:30 +0000 (02:20 +0000)]
give_sd_to_drive: If we don't have space, deallocate the subdisk.
Previously we could end up with a valid subdisk
entry pointing to offset -1 on the drive.
Bruce Evans [Tue, 24 Aug 1999 00:48:19 +0000 (00:48 +0000)]
Cast pointers to [u]intptr_t instead of casting them to [u_]long. Don't
depend on gcc's feature of casting lvalues, especially for direct
assignment where it doesn't even simplify the syntax. Cosmetic.
Bruce Evans [Tue, 24 Aug 1999 00:38:52 +0000 (00:38 +0000)]
Cast pointers to uintptr_t instead of casting them to u_long. They
are still converted to u_long by assignment of the uintptr_t, and
address calculations are still done using u_long. This is OK for
currently supported machines, but addresses should be represented
by vm_offset_t or uintptr_t in case pointers are longer than longs.
"Fixed" size of linker_path[]. MAXPATHLEN + 1 was 1 too large for
search paths with only one file path in them, but much too small
for search paths with several long file paths in them.
Now that we can bind cdevsw to the individual dev_t, divorce the PERFMON
stuff from mem.c. If PERFMON is there, it will "steal" a minor from
mem.c, but mem.c doesn't need to know about this.
Bruce Evans [Mon, 23 Aug 1999 21:07:13 +0000 (21:07 +0000)]
Initialise fsids with (user) device numbers again. Bitrot when dev_t's
were changed to pointers was obscured by casting dev_t's to longs.
fsids haven't even been comprised of longs since the Lite2 merge.
Peter Wemm [Mon, 23 Aug 1999 19:23:33 +0000 (19:23 +0000)]
The nexus_attach() code works a lot better if it's actually connected to
the device methods... Also, don't fail to add eisa/isa because a previous
device failed to attach.
Alan Cox [Mon, 23 Aug 1999 18:08:34 +0000 (18:08 +0000)]
struct vm_map:
The lock structure cannot be the first element of the vm_map
because this can result in livelock between two or more system
processes trying to kmem_alloc_wait.
Nick Hibma [Mon, 23 Aug 1999 14:49:22 +0000 (14:49 +0000)]
Recognise the GPS receiver from Trimble
in NMEA mode (without date).
Trimble OEM Ace-II receiver. Low cost PCB with single
voltage input, external active antenna and two serial
ports with either NMEA and ITAPs output. Programmable
to be tuned for 'time' accuracy in fixed station config.
Author of tool notified.
Submitted by: Dirk van Gulik <dirk.vangulik@jrc.it>
Peter Wemm [Mon, 23 Aug 1999 12:59:03 +0000 (12:59 +0000)]
Fix a few problems on the Alpha, and fix -Wall while here.
Before:
isab0@pci0:8:0: class=0x060100 card=0x00000000 chip=0xffffffffc6931080 ...
After:
isab0@pci0:8:0: class=0x060100 card=0x00000000 chip=0xc6931080 ...