Commit Graph

39516 Commits

Author SHA1 Message Date
truckman
79b9eea6e8 VOP_FSYNC() expects to be called with the vnode locked, so lock fvp in
nfs_rename() before calling VOP_FSYNC() and unlock fvp immediately after.

Reviewed by:	bde
2003-04-24 20:39:40 +00:00
peter
88151c4f8c Fix a bug with df on large (>1TB) nfsv3 file servers on 32 bit client
machines where the 'long' number of blocks in struct statfs wont fit.
Instead of chosing an artificial 512 byte block size, simply scale it up
until we avoid an overflow.  NFSv3 reports the sizes in bytes, and the
blocksize is a figment of nfsclient's imagination.
2003-04-24 20:36:32 +00:00
jhb
58bf1340a6 Fail to mount a device if the bytes per sector in the BPB is less than
DEV_BSIZE or if the number of FAT sectors is zero.
2003-04-24 18:19:19 +00:00
wes
2e72e0ae30 Make P_PROTECTED not conflict with P_STOPPED_SIG. Replace
P_UNUSED100000 which is *truly* unused, until now.

Submitted by:	Robert Drehmel <robert@zoot.drehmel.com>
2003-04-24 16:20:14 +00:00
simokawa
0998f1bbfe Fix printf warnings for i386 with PAE.
Submitted by: harti
2003-04-24 15:27:06 +00:00
kan
571d62789f Fix a typo in UINT_MAX definition. 2003-04-24 14:25:38 +00:00
des
4e35cc9041 It seems that 1 was not a magic value as I thought, but a coincidence.
Instead of applying the adjustment to processes with a start time of 1,
apply it to all processes with a start time of less than 3600.

None of this would be necessary if the start times were recorded in ticks
instead of seconds and microseconds.
2003-04-24 12:12:06 +00:00
tjr
bf8bb3cbd9 Do a better job of calculating the RSS for swapped-out processes:
don't include the kernel stacks of swapped-out threads in the page count,
but do include the alternate kernel stack. jhb provided some helpful
comments on this.

PR:		49102
2003-04-24 11:03:04 +00:00
simokawa
5f3a7ead43 Fix printf warning for RELENG_4. 2003-04-24 09:27:17 +00:00
tjr
2b308e25a0 Free mount credentials (mnt_cred) when freeing the mount struct
in failure cases to avoid leaking struct ucreds, and ultimately
leaking struct uidinfo references.
2003-04-24 08:16:06 +00:00
simokawa
453509aad1 Add some IEEE 1394 OHCI chips.
Partially submitted by: Tetsuya Ryuchi <ryuchi@ryuchi.org>
PR: misc/51336
2003-04-24 07:29:52 +00:00
alc
a91c48e613 - Move swap_pager_isswapped()'s prototype to a more logical place. 2003-04-24 05:29:27 +00:00
alc
87da2c3cf3 - Acquire the vm_object's lock when performing vm_object_page_clean().
- Add a parameter to vm_pageout_flush() that tells vm_pageout_flush()
   whether its caller has locked the vm_object.  (This is a temporary
   measure to bootstrap vm_object locking.)
2003-04-24 04:31:25 +00:00
des
51f01cb3f7 When filling out a kinfo_proc structure, if we come across a process
whose p_stats->p_start has the magic value 1, replace it with boottime.
Some users were apparently confused by the fact that ps(1) reported a
start time in early 1970 for system processes.
2003-04-24 03:37:59 +00:00
davidxu
7dbf40d20d Don't print anything for fault at cpu_switch_load_gs, just like other
code to recover fault in doreti because of invalid segment registers,
silently push error to userland.
2003-04-24 01:48:59 +00:00
archie
6649125e4d Tweak to previous commit: increment ifp->if_iqdrops if the m_copy() fails.
Suggested by:	Neelkanth Natu <neelnatu@yahoo.com>
2003-04-23 23:45:57 +00:00
imp
5c827309fc 1. Allow drivers to query CIS strings from OLDCARD.
2. Include backwards compatibility good for the moment (eventually will
   be turned off in current, but allow for a short transition period).

PR:	51333
Submited by: Scott Mitchell (1)
MFC after:	2 weeks
2003-04-23 23:39:21 +00:00
imp
1848692e44 Add accessor for cis4 string. Neither OLDCARD nor NEWCARD support
this yet, but that will change soon.

Pr: 51333
Submited by: Scott Mitchell
2003-04-23 23:32:53 +00:00
kan
b86b779077 Add a new sys/limits.h file which in turn depends on machine/_limits.h
to get actual constant values. This is in preparation for machine/limits.h
retirement.

Discussed on:	standards@
Submitted by:	Craig Rodrigues <rodrigc@attbi.com>  (*)
Modified by:	kan
2003-04-23 21:41:59 +00:00
phk
ffd04bfbdd Introduce a g_waitfor_event() function which posts an event and waits for
it to be run (or cancelled) and use this instead of home-rolled versions.
2003-04-23 21:28:27 +00:00
phk
7a7d406136 More of the event stuff can now be private to geom_event.c 2003-04-23 20:54:42 +00:00
phk
3bbfe9f43b Rename g_call_me() to g_post_event(), and give it a flag
argument to determine if we can M_WAITOK in malloc.
2003-04-23 20:46:12 +00:00
phk
b4c26d2e1a Remove the now unused hardcoded g_post_event() event support. 2003-04-23 20:25:33 +00:00
jhay
7c3a9405f3 Use bus_space*() instead of in*() and out*(). 2003-04-23 20:22:32 +00:00
phk
7c462ceb2b Turn EV_NEW_PROVIDER into a g_call_me() event. 2003-04-23 20:16:13 +00:00
phk
67a31a6107 Convert EV_SPOILED event to use g_call_me(). 2003-04-23 20:06:38 +00:00
jhb
9b55ca02a0 Remove Giant from osigblock(), osigsetmask(), and kern_sigaltstack(). 2003-04-23 19:49:18 +00:00
phk
16bcc257a6 Turn the hardwired NEW_CLASS event into a g_call_me() event. 2003-04-23 19:34:38 +00:00
phk
51e68a1f27 Move the shutdown eventhandler stuff to a more logical place. 2003-04-23 19:15:27 +00:00
jhb
fe0dcbf0db Update many of the locking notes and comments for struct
thread/kse/ksegroup/proc.
2003-04-23 18:54:30 +00:00
jhb
2c416d197d The signotify() sanity check in userret() doesn't need Giant anymore. 2003-04-23 18:51:55 +00:00
jhb
26097c18e1 Add lock assertions for various proc/thread/kse/ksegroup fields to the
scheduler functions.
2003-04-23 18:51:05 +00:00
jhb
89c52cff2e - Reorganize osigstack() to do the copyin first, grab the proc lock once,
do all the various sigstack dances, unlock the proc lock, and finally do
  the copyout.  This more closely resembles the behavior of
  kern_sigaltstack() and closes a small race.
- Remove Giant from osigstack as it is no longer needed.
2003-04-23 18:50:25 +00:00
jhb
2958cf621b Remove Giant from [gs]etpriority(). 2003-04-23 18:48:55 +00:00
jhb
a0bf3a3e6f - Protect p_numthreads with the sched_lock.
- Protect p_singlethread with both the sched_lock and the proc lock.
- Protect p_suspcount with the proc lock.
2003-04-23 18:46:51 +00:00
archie
84db389df4 Fix a case where the return value from m_copy() was not being checked
for NULL before proceeding, causing a crash if mbufs were exhausted.

MFC after:	3 days
Reported by:	Mark Gooderum <mark@verniernetworks.com>
2003-04-23 18:35:40 +00:00
jhb
485007051a Fix compiling in the NO_SWAPPING case.
Submitted by:	bde (partially)
2003-04-23 18:21:41 +00:00
jhb
3df03e8316 Fix a lock order reversal. Unlock the proc before calling fget().
Reported by:	kris
2003-04-23 18:13:26 +00:00
jhb
df96ff7f37 Comment out the mixer entry for igain for the mic 20dB boost for now since
it can cause feedback problems on some laptops.

Reviewed by:	orion
2003-04-23 16:49:53 +00:00
des
649f6ec094 Add constants for USB programming interfaces. These are already defined
(with other names) in the USB driver sources, but I felt that pcireg.h
should have a complete list - at least of classes and interfaces that we
know about and use.
2003-04-23 15:51:36 +00:00
jhay
f639676ede Get rid of kvtop().
Change inb() and outb() to use bus_space*().
2003-04-23 15:40:11 +00:00
phk
15a332bfd6 Implement CONFIG_GEOM verbs "write label" and "write bootcode". 2003-04-23 08:23:01 +00:00
phk
cc4a9d46fe Introduce a #define for the length of the bootloader code. 2003-04-23 08:04:30 +00:00
phk
2d7e7620e8 Introduce gctl_get_paraml() which gets a parameter only if it has the
right length.
2003-04-23 08:03:47 +00:00
phk
90684346d6 Make gctl_error() take printfline varargs. 2003-04-23 07:50:01 +00:00
phk
ee10d53986 Remove unused event pointers in object structures.
Remove KASSERTS which checked that they were unused.
2003-04-23 06:54:44 +00:00
obrien
590e10e4ac Add /dev to the Alpha manual mount root example. 2003-04-23 05:02:40 +00:00
truckman
b8272feca3 Release the vnode interlock in nfs_flush() before calling nfs_sigintr(),
and grab it again later if necessary.  This prevents a lock order reversal
because nfs_sigintr() calls PROC_LOCK().
2003-04-23 02:58:26 +00:00
phk
1e2ee18100 Change the locking so that the _modify function is called with topology
held.

The only place where we want to not hold topology is when we read
(or write) the label to disk: in the case of a disk error with a
long recovery time, holding topology would prevent open/close of
any disk device.
2003-04-22 21:29:58 +00:00
phk
5d4dba6264 We don't need to have a slice->start() function. 2003-04-22 21:24:37 +00:00