Commit Graph

95398 Commits

Author SHA1 Message Date
dwmalone
be405a4cbd falloc allocates a file structure and adds it to the file descriptor
table, acquiring the necessary locks as it works. It usually returns
two references to the new descriptor: one in the descriptor table
and one via a pointer argument.

As falloc releases the FILEDESC lock before returning, there is a
potential for a process to close the reference in the file descriptor
table before falloc's caller gets to use the file. I don't think this
can happen in practice at the moment, because Giant indirectly protects
closes.

To stop the file being completly closed in this situation, this change
makes falloc set the refcount to two when both references are returned.
This makes life easier for several of falloc's callers, because the
first thing they previously did was grab an extra reference on the
file.

Reviewed by:	iedowse
Idea run past:	jhb
2003-10-19 20:41:07 +00:00
alc
676085d671 - Add vm object locking to vfs_clean_pages() and vfs_bio_set_validclean().
This is to synchronize access to the vm page's valid field by
   vm_page_set_validclean().
2003-10-19 20:39:06 +00:00
phk
b7c9250fa7 Remove KASSERT check for negative bio_offsets, add "normal" EIO
error return for same.
2003-10-19 19:06:54 +00:00
bmah
69b08878f3 The re(4) driver works on CURRENT/alpha.
Reported by:	naddy@mips.inka.de (Christian Weisgerber) on alpha@
2003-10-19 18:35:40 +00:00
bmah
ea573c499c Modified release notes: Fixed minor grammatical bugs in atkbd(4) bug
and safe(4).
2003-10-19 18:32:48 +00:00
imp
92be84c4b4 Finish the removal of the bst/bsh confusion. 2003-10-19 17:38:04 +00:00
mux
d16b904dfe Remove debug printf(). 2003-10-19 14:33:00 +00:00
cognet
82c805f917 Implement partially /proc/<pid>/maps.
It looks enough to make SImics run.

Reviewed by:	des
2003-10-19 14:13:51 +00:00
des
d5e5722561 Various NFS-related bug fixes (mostly related to using variable_get()
instead of variable_cmp() to test boolean rc.conf variables).

Submitted by:	hmp
2003-10-19 13:37:12 +00:00
hrs
945df0bf16 Modified release note:
Fix a typo in IP_ONESBCAST item.

MFC noted:
	ipfw(4) limit rule processing fix.
2003-10-19 12:58:57 +00:00
nyan
eb1cd59204 MFi386: revision 1.577. 2003-10-19 11:35:44 +00:00
phk
cda626230e s/5.0-CURRENT/FreeBSD 5.x/ 2003-10-19 10:24:59 +00:00
bms
6360d0a43d Fix LINT build by correcting a missed change. 2003-10-19 09:31:07 +00:00
njl
432ff6a541 Disable irqs before entering the power-off state. This is not known
to fix any problems but is similar to how Linux implements this
function.
2003-10-19 05:56:59 +00:00
peter
7b3a8f1308 Tidy up loose ends in the idle process. Call the MI cpu_idle() function
for all platforms now.

XXX alpha/sparc64/powerpc should fill in the function.

Submitted by:  bde
2003-10-19 02:43:57 +00:00
peter
05de20ae7a Add a stub cpu_idle() function for sparc64, alpha, powerpc. This is a
MI declared function so it should be everywhere.
2003-10-19 02:36:07 +00:00
cognet
eb4121cb0d Fix broken su -m behaviour :
chshell must return 0 if the shell is not a standard shell, or else it is
possible to use an account without a valid shell.

Reviewed by:	des
2003-10-19 02:09:36 +00:00
davidxu
f2c5a17d79 Use npxdrop in cpu_thread_exit to save some cycles.
Clear FPU pcb flags for new upcall thread, these flags needn't
be inherited, the new thread should start from clean FPU status.
2003-10-19 00:57:10 +00:00
gshapiro
b767de36df Before trying to restart/stop the MTA or MSP queue runner, make sure
we are configured to use an MTA or MSP queue runner.  Otherwise the
script used to complain about the missing PID file.

PR:		conf/57075
Submitted by:	Jonathan Chen <jonc@chen.org.nz>
MFC after:	2 weeks
2003-10-19 00:31:50 +00:00
gshapiro
7d4f685f3e Adding WorkAroundBrokenAAAA seems a necessity even in the submit.mc given
the number of broken DNS servers out there in the world.  Since we are
diverging from the sendmail.org submit.mc, it's time to make our own
freebsd.submit.mc.

PR:		conf/57733
Reviewed by:	nork
MFC after:	2 weeks
2003-10-19 00:03:13 +00:00
imp
61abce2611 Don't confuse tags and handles. 2003-10-19 00:03:10 +00:00
alc
cc2c1485cf - Synchronize access to a vm page's valid field using the containing
vm object's lock.
 - Reduce the scope of the vm page queues lock in two places.
2003-10-19 00:01:56 +00:00
simon
509f7279a8 Note that PAE has been MFC'd into RELENG_4 and will appear in FreeBSD
4.9.
2003-10-18 22:54:45 +00:00
njl
8689796a4b Add the cpu_idle_hook() function pointer so that other idlers can be
hooked at runtime.  Make C1 sleep (e.g., HLT) be the default.  This
prepares the way for further ACPI sleep states.
2003-10-18 22:25:07 +00:00
alc
fb13ea0aa9 - Synchronize access to the page's valid field in
vnode_pager_generic_getpages() using the containing object's lock.
2003-10-18 21:30:29 +00:00
alc
bccf1d15ab - Increase the object lock's scope in vm_contig_launder() so that access
to the object's type field and the call to vm_pageout_flush() are
   synchronized.
 - The above change allows for the eliminaton of the last parameter
   to vm_pageout_flush().
 - Synchronize access to the page's valid field in vm_pageout_flush()
   using the containing object's lock.
2003-10-18 21:09:21 +00:00
bms
39bde695bf Fix a typo. The module has the EISA front-end commented out, therefore the
error may not have been picked up right away.

Reviewed by:	mdodd
Submitted by:	Stuart Walsh
2003-10-18 20:44:23 +00:00
phk
50ecf36141 Initialize b_iooffset before calling VOP_[SPEC]STRATEGY 2003-10-18 19:49:46 +00:00
phk
4b7ade98cd Initialize b_iooffset before calling strategy 2003-10-18 19:48:21 +00:00
phk
2d32752eb9 Only automatically create an 'a' partition when there is nothing
but a 'c' partition.
2003-10-18 19:32:35 +00:00
alc
d9e9583e64 Corrections to revision 1.305
- Specifying VM_MAP_WIRE_HOLESOK should not assume that the start
   address is the beginning of the map.  Instead, move to the first
   entry after the start address.
 - The implementation of VM_MAP_WIRE_HOLESOK was incomplete.  This
   caused the failure of mlockall(2) in some circumstances.
2003-10-18 18:48:17 +00:00
hrs
8354a73c7f New release note:
Fix ipfw(4) limit rule processing.
2003-10-18 18:18:17 +00:00
phk
ba114823c5 Retire b_pblkno which was an alias for a bio field which is for
device drivers only.
2003-10-18 18:17:55 +00:00
phk
80b79c02da Don't report b_pblkno, it is going away. 2003-10-18 17:59:02 +00:00
phk
36a05b5ad5 Do not initialize bp->b_pblkno, it is going away. 2003-10-18 17:57:48 +00:00
phk
b3eb57c5d4 Retire bio_blkno entirely.
bio_offset is the field drivers should use.
bio_pblkno remains as a convenient place to store the number of
the device drivers.
2003-10-18 17:53:34 +00:00
phk
5a1c5c9c13 Eliminate use bio_blkno. 2003-10-18 17:51:26 +00:00
ume
42120d22ea rtfree() must be called in lock context.
Reported by:	jhay
2003-10-18 17:46:23 +00:00
phk
313310b9a6 Discontinue bio_blkno usage. 2003-10-18 17:45:45 +00:00
phk
583ddf14d7 Discontinue bio_blkno, use bio_offset instead. 2003-10-18 17:44:01 +00:00
phk
8714e3267f Eliminate reporting of bio_blkno. 2003-10-18 17:28:36 +00:00
phk
adc5cdd07a Report bio_pblkbo instead of bio_blkno. 2003-10-18 17:27:10 +00:00
phk
94a1f5bcd6 Use bio_offset instead of bio_blkno 2003-10-18 17:26:13 +00:00
phk
466d3b80d8 No need to initialize bio_pblkno from bio_blkno, disksort uses bio_offset. 2003-10-18 17:24:51 +00:00
phk
b60969a35e Make bioq_disksort() sort on the bio_offset field instead of bio_pblkno. 2003-10-18 15:50:56 +00:00
imp
cec43b43e0 Transition to using bus_space macros rather than the inb/outb/etc.
Use EP_{READ,WRITE}{,_MULTI}_{1,2,4} instead.  I've had several people
submit patches like this over the years of varying qualities, markm
being the last.  The names were chosen in consulation with mdodd on
irc.

I've tested this with only PCMCIA cards: 3CCE589EC and 3CCSH572BT.
I've not tried with my more extensive ISA, EISA and cbus collection.

Reviewed by: mdodd
2003-10-18 15:22:43 +00:00
phk
4c2cb3f397 DuH!
bp->b_iooffset (the spot on the disk), not bp->b_offset (the offset in
the file)
2003-10-18 14:10:28 +00:00
phk
d004fc1e31 I think rwatson got the sign wrong here... 2003-10-18 12:16:17 +00:00
phk
d985a757f9 Don't initialize unused bio_blkno field. 2003-10-18 11:25:42 +00:00
phk
3905ba5d0a Initialize bp->b_offset before calling VOP_[SPEC]STRATEGY() 2003-10-18 11:16:33 +00:00