Commit Graph

139919 Commits

Author SHA1 Message Date
Robert Watson
65c577c01d Drop read lock on udbinfo earlier during delivery to the last matching
UDP socket for a datagram; the inpcb read lock is sufficient to provide
inpcb stability during udp6_append().

MFC after:      1 month
2008-07-07 10:11:17 +00:00
Poul-Henning Kamp
69301d4c17 Apply learning from RAIEC (Redundant Array of Independeng English Courses)
kindly provided by four different correspondents since my last commit.
2008-07-07 10:04:16 +00:00
Konstantin Belousov
7054ee4e38 The kqueue_register() function assumes that it is called from the top of
the syscall code and acquires various event subsystem locks as needed.
The handling of the NOTE_TRACK for EVFILT_PROC is currently done by
calling the kqueue_register() from filt_proc() filter, causing recursive
entrance of the kqueue code. This results in the LORs and recursive
acquisition of the locks.

Implement the variant of the knote() function designed to only handle
the fork() event. It mostly copies the knote() body, but also handles
the NOTE_TRACK, removing the handling from the filt_proc(), where it
causes problems described above. The function is called from the fork1()
instead of knote().

When encountering NOTE_TRACK knote, it marks the knote as influx
and drops the knlist and kqueue lock. In this context call to
kqueue_register is safe from the problems.

An error from the kqueue_register() is reported to the observer as
NOTE_TRACKERR fflag.

PR:	108201
Reviewed by:	jhb, Pramod Srinivasan <pramod juniper net> (previous version)
Discussed with:	jmg
Tested by:	pho
MFC after:	2 weeks
2008-07-07 09:30:11 +00:00
David Malone
0d1532e0ef Update man page for addition of BIOCSETFNR. Subversion didn't want
to commit this at the same time for some reason.
2008-07-07 09:27:02 +00:00
Robert Watson
10cc62b7a6 Drop read lock on udbinfo earlier during delivery to the last matching
UDP socket for a datagram; the inpcb read lock is sufficient to provide
inpcb stability during udp_append().

MFC after:	1 month
2008-07-07 09:26:52 +00:00
David Malone
f11c35082b Add a new ioctl for changing the read filter (BIOCSETFNR). This is
just like BIOCSETF but it doesn't drop all the packets buffered on
the discriptor and reset the statistics.

Also, when setting the write filter, don't drop packets waiting to
be read or reset the statistics.

PR:		118486
Submitted by:	Matthew Luckie <mluckie@cs.waikato.ac.nz>
MFC after:	1 month
2008-07-07 09:25:49 +00:00
Konstantin Belousov
e1a32fd42b The r178914 I erronously put the setting of the KQ_FLUXWAIT flag before
KQ_FLUX_WAKEUP(). Since the later macro clears the KQ_FLUXWAIT, the
kqueue_scan() thread may be not woken up.

Move the setting of KQ_FLUXWAIT after wakeup to correct the issue.

Reported and tested by:	pho
MFC after:	3 days
2008-07-07 09:15:29 +00:00
Weongyo Jeong
55f2aa7451 correct device name errors and wrong informations that currently malo(4)
don't support ad-hoc mode and there's no a man page like malofw(4).
2008-07-07 02:39:39 +00:00
Christian S.J. Peron
f9655da0fb Add hard sentence breaks.
Pointed out by:	rwatson
MFC after:	1 week
2008-07-06 22:47:10 +00:00
Alan Cox
4a7c66163b Change create_pagetables() and pmap_init() so that many fewer page table
pages have to be preallocated by create_pagetables().
2008-07-06 22:36:28 +00:00
Warner Losh
4d9ac6c76f As discussed on IRC and at BSDcan, move the mips32/* directories up a
level.  The distinction was artificial.  Some more movement around the
deck charis is likely depending on the fallout from this one.

Paths were corrected after the svn mv.  Hope that's OK.
2008-07-06 21:09:29 +00:00
Marcel Moolenaar
c4c9b9f50c Obsolete bsdlabel(8) on powerpc. Use gpart(8) instead. 2008-07-06 20:57:35 +00:00
Christian S.J. Peron
bc068d93d1 Document default ACLs and how to use them.
MFC after:	1 week
2008-07-06 20:29:35 +00:00
Daniel Gerzo
5fd5badfa9 - This code was intially obtained from NetBSD, but it's missing licence
statement. Add the one from the current NetBSD version.
- Also bump a date to reflect my content changes I have done in previous
  revision

Approved by:	imp
MFC after:	3 days
2008-07-06 17:03:37 +00:00
Tim Kientzle
af03c60c06 Preserve ownership if cpio is run as root. 2008-07-06 16:39:18 +00:00
Rui Paulo
ded2471528 Fix comment: s/before/after. 2008-07-06 16:18:58 +00:00
Daniel Gerzo
6d05da1dc9 - Add description about a missing return value
PR:		docs/75995
Submitted by:	Tarc <tarc@po.cs.msu.su>
MFC after:	3 days
2008-07-06 12:17:53 +00:00
Daniel Gerzo
408425ce37 - remove superfluous word
- remove contractions

MFC after:	3 days
2008-07-06 11:31:20 +00:00
Daniel Gerzo
4436c3559f - avoid future breakage: cnw(4), sbni(4) and sbsh(4) have been removed 2008-07-06 10:57:58 +00:00
Daniel Gerzo
e4189245c3 - fix build; oltr(4) has been removed in r180259 2008-07-06 10:44:34 +00:00
Mike Makonnen
9300b74ce4 Remove the $DUMPDIR variable. It's redundant and the rest of the
script uses $dumpdir directly.
2008-07-06 08:31:29 +00:00
Mike Makonnen
f562910214 Make checking for the availability of core dumps work in the case
that $dumpdev is not set to "AUTO".

Reported by: Paul B. Mahol <onemda@gmail.com>
2008-07-06 07:51:29 +00:00
Warner Losh
278324026c Add two corega cards and annotate 8041 V2 chipset. 2008-07-06 06:24:02 +00:00
Warner Losh
86f96d387b Add two corega cards from NetBSD: FETEHR II PCC TXD and LAPCCTXD. 2008-07-06 06:19:19 +00:00
Warner Losh
b98165b03f Merge from NetBSD's pcmciadev file (rev ~1.208 - 1.226) where
appropriate (versions not appropriate to merge omitted):
o 1.226 imp nop, save for NetBSD string (minor merging the other way)
o 1.225 jnemeth Coreage LAPCCTXD
o 1.224 martin (remove 3rd and 4th clauses)
o 1.223 kiyohara (TDK bluetooth PC Card)
o 1.222 kiyohara (Anycom BlueCard)
o 1.221 ichiro (NEC Infrontia AX420N)
o 1.219 jmcneill (EDIMAX EP-4101)
o 1.213 tsutsui (TEAC IDECARDII entry fix)

Also, while I'm here, fix some tab problems that have crept in.
2008-07-06 06:17:39 +00:00
Rui Paulo
847ea26fbb Add a missing call to config_intrhook_establish(). 2008-07-05 23:54:02 +00:00
Rui Paulo
fe4944de64 Use config_intrhook API to create the dev.cpu.N.temperature sysctl node.
Our hook creates the sysctl node before root is mounted, but after cpu
is probed. It seems that k8temp can be loaded before the cpu module and,
in those cases, dev.cpu.0.temperature was not created.

PR:	124939
2008-07-05 23:19:37 +00:00
Alan Cox
13e0058451 Increase the kernel map's size to 7GB, making room for a kmem map of size
greater than 4GB.  (Auto-sizing will set the ceiling on the kmem map size
to 4.2GB.)
2008-07-05 20:44:55 +00:00
Christian S.J. Peron
29f612ec71 Make sure we are clearing the ZBUF_FLAG_IMMUTABLE any time a free buffer
is reclaimed by the kernel.  This fixes a bug resulted in the kernel
over writing packet data while user-space was still processing it when
zerocopy is enabled.  (Or a panic if invariants was enabled).

Discussed with:	rwatson
2008-07-05 20:11:28 +00:00
Sam Leffler
4d5ed46093 correct construction of delba action frame; don't shift+mask the initiator
argument

Submitted by:	Marvell
2008-07-05 19:56:47 +00:00
Alan Cox
b89eaf4e9f Enable the creation of a kmem map larger than 4GB.
Submitted by: Tz-Huan Huang

Make several variables related to kmem map auto-sizing static.
Found by: CScout
2008-07-05 19:34:33 +00:00
Robert Watson
ba8cd2c528 Clarify comments and prototypes in raw_cb.h:
- the protosw entries are used directly
- the usrreq functions are library routines, generally wrapped by
  consumers rather than being used directly
- the usrreq structure entries are likewise typically wrapped

Remove the rather incorrect #if 0'd pr_input_t prototype for raw_input.

MFC after:	3 days
2008-07-05 19:12:55 +00:00
Robert Watson
cec9ffee22 Rename raw_append() to rip_append(): the raw_ prefix is generally used
for functions in the generic raw socket library (raw_cb.c, raw_usrreq.c),
and they are not used for IPv4 raw sockets.

MFC after:	3 days
2008-07-05 18:55:03 +00:00
Robert Watson
0ae76120da Improve approximation of style(9) in raw socket code. 2008-07-05 18:03:39 +00:00
Robert Watson
6a27071e54 Rename several functions in if_lmc with potential name collisions with
global symbols, such as raw_input and raw_output, to have lmc_ prefixes.
This doesn't affect actual functionality since the functions are static,
but will limit the opportunities for current confusion and future
difficulty.

MFC after:	3 days
2008-07-05 16:39:24 +00:00
Yoshihiro Takahashi
48d0e1242e Add i386_memio_compare() to compare two resources.
It's used by uart(4) in the future.
2008-07-05 16:31:58 +00:00
Marius Strobl
ac5bdea17e - Merge macros depending on the flags being preserved between calls
into a single "__asm"-statement as GCC doesn't guarantee their
  consecutive output even when using consecutive "__asm __volatile"-
  statement for them. Remove the otherwise unnecessary "__volatile". [1]
- The inline assembler instructions used here alter the condition
  codes so add them to the clobber list accordingly.
- The inline assembler instructions used here uses output operands
  before all input operands are consumed so add appropriate modifiers.

Pointed out by:	bde [1]
MFC after:	2 weeks
2008-07-05 15:44:56 +00:00
Marius Strobl
681f038fd9 - Fix spelling and style.
- Use __FBSDID.
2008-07-05 15:30:07 +00:00
Marius Strobl
6a92796332 Revert the addition of "__volatile" to "__asm" done in r180011, since
the condition codes where added to the clobber lists in r180073 the
former is unnecessary.
2008-07-05 15:28:30 +00:00
Mike Makonnen
7a711eb359 No need to display the result of enabling the ipfw sysctl if it's
successfull. Issue a warning if it fails, however.
2008-07-05 15:27:39 +00:00
Mike Makonnen
8144c9ac9b There's no need to announce that we're mounting local filesystems when
running in quiet mode since if we fail to mount any of them the boot
process gets interrupted.
2008-07-05 15:19:58 +00:00
Mike Makonnen
c5a80a7a3b Quiet down rc.d/nfsclient by not printing anything in 'quiet' mode. Instead
issue a warning of it fails to set the sysctls.
2008-07-05 15:13:21 +00:00
Robert Watson
4f7d1876d5 Introduce a new lock, hostname_mtx, and use it to synchronize access
to global hostname and domainname variables.  Where necessary, copy
to or from a stack-local buffer before performing copyin() or
copyout().  A few uses, such as in cd9660 and daemon_saver, remain
under-synchronized and will require further updates.

Correct a bug in which a failed copyin() of domainname would leave
domainname potentially corrupted.

MFC after:	3 weeks
2008-07-05 13:10:10 +00:00
Poul-Henning Kamp
e1747bd4de Two quotes too good to miss. 2008-07-05 08:54:58 +00:00
Colin Percival
a6d7fc3469 Move duplicated code from tar_mode_[cru] into archive_write.
Fix a bug I introduced 7 minutes ago: clean up properly from archive_write
if we exit the argv-handling loop due to -C not having an argument.
2008-07-05 08:10:55 +00:00
Colin Percival
d47b2ddb21 Use malloc in write_archive to allocate a 64kB buffer for holding file data
instead of using 64kB of stack space in copy_file_data and write_file_data.
2008-07-05 08:03:08 +00:00
John Birrell
3a877a1d93 Add CTF conversion to the objects compiled from generated code.
This allows DTrace scripts to access variables like 'ostype'.
2008-07-05 06:12:14 +00:00
Colin Percival
85f32b2087 Clean up write_entry by eliminating fd except in the #ifdef __linux block
where it is used. [1]

Don't leak file descriptors in write_entry_backend if archive_write_header
returns ARCHIVE_FAILED.

Found by:	Coverity Prevent [1]
2008-07-05 06:05:34 +00:00
Tim Kientzle
ba779d5afd bsdcpio is now at version 1.0.0. 2008-07-05 05:17:33 +00:00
Tim Kientzle
0d35b0da0c In -pl mode, only hardlink regular files. I need to test
other implementations, but it's clear that dirs and symlinks,
at least, shouldn't be hardlinked.
2008-07-05 05:16:23 +00:00