]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
16 years agoAdd #include <inttypes.h> for the strtoimax().
kib [Mon, 7 Jul 2008 12:20:34 +0000 (12:20 +0000)]
Add #include <inttypes.h> for the strtoimax().

Submitted by: Jilles Tjoelker <jilles stack nl>
MFC after: 3 days

16 years agoAdd additional udbinfo and inpcb locking assertions to udp_output(); for
rwatson [Mon, 7 Jul 2008 12:14:10 +0000 (12:14 +0000)]
Add additional udbinfo and inpcb locking assertions to udp_output(); for
some code paths, global or inpcb write locks are required, but for other
code paths, read locks or no locking at all are sufficient for the data
structures.

MFC after: 1 month

16 years agoAdd missing information for geom_mirror metadata.
remko [Mon, 7 Jul 2008 11:44:57 +0000 (11:44 +0000)]
Add missing information for geom_mirror metadata.

PR: 124434
Submitted by: Philip M. Golluci <pgolluci at p6m7g8 dot com>
MFC after: 3 days

Prodded through: bugbusters@

16 years agoFirst step towards parallel transmit in UDP: if neither a specific
rwatson [Mon, 7 Jul 2008 10:56:55 +0000 (10:56 +0000)]
First step towards parallel transmit in UDP: if neither a specific
source or a specific destination address is requested as part of a send
on a UDP socket, read lock the inpcb rather than write lock it.  This
will allow fully parallel transmit down to the IP layer when sending
simultaneously from multiple threads on a connected UDP socket.

Parallel transmit for more complex cases, such as when sendto(2) is
invoked with an address and there's already a local binding, will
follow.

MFC after: 1 month

16 years agoDrop read lock on udbinfo earlier during delivery to the last matching
rwatson [Mon, 7 Jul 2008 10:11:17 +0000 (10:11 +0000)]
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

16 years agoApply learning from RAIEC (Redundant Array of Independeng English Courses)
phk [Mon, 7 Jul 2008 10:04:16 +0000 (10:04 +0000)]
Apply learning from RAIEC (Redundant Array of Independeng English Courses)
kindly provided by four different correspondents since my last commit.

16 years agoThe kqueue_register() function assumes that it is called from the top of
kib [Mon, 7 Jul 2008 09:30:11 +0000 (09:30 +0000)]
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

16 years agoUpdate man page for addition of BIOCSETFNR. Subversion didn't want
dwmalone [Mon, 7 Jul 2008 09:27:02 +0000 (09:27 +0000)]
Update man page for addition of BIOCSETFNR. Subversion didn't want
to commit this at the same time for some reason.

16 years agoDrop read lock on udbinfo earlier during delivery to the last matching
rwatson [Mon, 7 Jul 2008 09:26:52 +0000 (09:26 +0000)]
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

16 years agoAdd a new ioctl for changing the read filter (BIOCSETFNR). This is
dwmalone [Mon, 7 Jul 2008 09:25:49 +0000 (09:25 +0000)]
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

16 years agoThe r178914 I erronously put the setting of the KQ_FLUXWAIT flag before
kib [Mon, 7 Jul 2008 09:15:29 +0000 (09:15 +0000)]
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

16 years agocorrect device name errors and wrong informations that currently malo(4)
weongyo [Mon, 7 Jul 2008 02:39:39 +0000 (02:39 +0000)]
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).

16 years agoAdd hard sentence breaks.
csjp [Sun, 6 Jul 2008 22:47:10 +0000 (22:47 +0000)]
Add hard sentence breaks.

Pointed out by: rwatson
MFC after: 1 week

16 years agoChange create_pagetables() and pmap_init() so that many fewer page table
alc [Sun, 6 Jul 2008 22:36:28 +0000 (22:36 +0000)]
Change create_pagetables() and pmap_init() so that many fewer page table
pages have to be preallocated by create_pagetables().

16 years agoAs discussed on IRC and at BSDcan, move the mips32/* directories up a
imp [Sun, 6 Jul 2008 21:09:29 +0000 (21:09 +0000)]
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.

16 years agoObsolete bsdlabel(8) on powerpc. Use gpart(8) instead.
marcel [Sun, 6 Jul 2008 20:57:35 +0000 (20:57 +0000)]
Obsolete bsdlabel(8) on powerpc. Use gpart(8) instead.

16 years agoDocument default ACLs and how to use them.
csjp [Sun, 6 Jul 2008 20:29:35 +0000 (20:29 +0000)]
Document default ACLs and how to use them.
MFC after: 1 week

16 years ago- This code was intially obtained from NetBSD, but it's missing licence
danger [Sun, 6 Jul 2008 17:03:37 +0000 (17:03 +0000)]
- 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

16 years agoPreserve ownership if cpio is run as root.
kientzle [Sun, 6 Jul 2008 16:39:18 +0000 (16:39 +0000)]
Preserve ownership if cpio is run as root.

16 years agoFix comment: s/before/after.
rpaulo [Sun, 6 Jul 2008 16:18:58 +0000 (16:18 +0000)]
Fix comment: s/before/after.

16 years ago- Add description about a missing return value
danger [Sun, 6 Jul 2008 12:17:53 +0000 (12:17 +0000)]
- Add description about a missing return value

PR: docs/75995
Submitted by: Tarc <tarc@po.cs.msu.su>
MFC after: 3 days

16 years ago- remove superfluous word
danger [Sun, 6 Jul 2008 11:31:20 +0000 (11:31 +0000)]
- remove superfluous word
- remove contractions

MFC after: 3 days

16 years ago- avoid future breakage: cnw(4), sbni(4) and sbsh(4) have been removed
danger [Sun, 6 Jul 2008 10:57:58 +0000 (10:57 +0000)]
- avoid future breakage: cnw(4), sbni(4) and sbsh(4) have been removed

16 years ago- fix build; oltr(4) has been removed in r180259
danger [Sun, 6 Jul 2008 10:44:34 +0000 (10:44 +0000)]
- fix build; oltr(4) has been removed in r180259

16 years agoRemove the $DUMPDIR variable. It's redundant and the rest of the
mtm [Sun, 6 Jul 2008 08:31:29 +0000 (08:31 +0000)]
Remove the $DUMPDIR variable. It's redundant and the rest of the
script uses $dumpdir directly.

16 years agoMake checking for the availability of core dumps work in the case
mtm [Sun, 6 Jul 2008 07:51:29 +0000 (07:51 +0000)]
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>

16 years agoAdd two corega cards and annotate 8041 V2 chipset.
imp [Sun, 6 Jul 2008 06:24:02 +0000 (06:24 +0000)]
Add two corega cards and annotate 8041 V2 chipset.

16 years agoAdd two corega cards from NetBSD: FETEHR II PCC TXD and LAPCCTXD.
imp [Sun, 6 Jul 2008 06:19:19 +0000 (06:19 +0000)]
Add two corega cards from NetBSD: FETEHR II PCC TXD and LAPCCTXD.

16 years agoMerge from NetBSD's pcmciadev file (rev ~1.208 - 1.226) where
imp [Sun, 6 Jul 2008 06:17:39 +0000 (06:17 +0000)]
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.

16 years agoAdd a missing call to config_intrhook_establish().
rpaulo [Sat, 5 Jul 2008 23:54:02 +0000 (23:54 +0000)]
Add a missing call to config_intrhook_establish().

16 years agoUse config_intrhook API to create the dev.cpu.N.temperature sysctl node.
rpaulo [Sat, 5 Jul 2008 23:19:37 +0000 (23:19 +0000)]
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

16 years agoIncrease the kernel map's size to 7GB, making room for a kmem map of size
alc [Sat, 5 Jul 2008 20:44:55 +0000 (20:44 +0000)]
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.)

16 years agoMake sure we are clearing the ZBUF_FLAG_IMMUTABLE any time a free buffer
csjp [Sat, 5 Jul 2008 20:11:28 +0000 (20:11 +0000)]
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

16 years agocorrect construction of delba action frame; don't shift+mask the initiator
sam [Sat, 5 Jul 2008 19:56:47 +0000 (19:56 +0000)]
correct construction of delba action frame; don't shift+mask the initiator
argument

Submitted by: Marvell

16 years agoEnable the creation of a kmem map larger than 4GB.
alc [Sat, 5 Jul 2008 19:34:33 +0000 (19:34 +0000)]
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

16 years agoClarify comments and prototypes in raw_cb.h:
rwatson [Sat, 5 Jul 2008 19:12:55 +0000 (19:12 +0000)]
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

16 years agoRename raw_append() to rip_append(): the raw_ prefix is generally used
rwatson [Sat, 5 Jul 2008 18:55:03 +0000 (18:55 +0000)]
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

16 years agoImprove approximation of style(9) in raw socket code.
rwatson [Sat, 5 Jul 2008 18:03:39 +0000 (18:03 +0000)]
Improve approximation of style(9) in raw socket code.

16 years agoRename several functions in if_lmc with potential name collisions with
rwatson [Sat, 5 Jul 2008 16:39:24 +0000 (16:39 +0000)]
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

16 years agoAdd i386_memio_compare() to compare two resources.
nyan [Sat, 5 Jul 2008 16:31:58 +0000 (16:31 +0000)]
Add i386_memio_compare() to compare two resources.
It's used by uart(4) in the future.

16 years ago- Merge macros depending on the flags being preserved between calls
marius [Sat, 5 Jul 2008 15:44:56 +0000 (15:44 +0000)]
- 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

16 years ago- Fix spelling and style.
marius [Sat, 5 Jul 2008 15:30:07 +0000 (15:30 +0000)]
- Fix spelling and style.
- Use __FBSDID.

16 years agoRevert the addition of "__volatile" to "__asm" done in r180011, since
marius [Sat, 5 Jul 2008 15:28:30 +0000 (15:28 +0000)]
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.

16 years agoNo need to display the result of enabling the ipfw sysctl if it's
mtm [Sat, 5 Jul 2008 15:27:39 +0000 (15:27 +0000)]
No need to display the result of enabling the ipfw sysctl if it's
successfull. Issue a warning if it fails, however.

16 years agoThere's no need to announce that we're mounting local filesystems when
mtm [Sat, 5 Jul 2008 15:19:58 +0000 (15:19 +0000)]
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.

16 years agoQuiet down rc.d/nfsclient by not printing anything in 'quiet' mode. Instead
mtm [Sat, 5 Jul 2008 15:13:21 +0000 (15:13 +0000)]
Quiet down rc.d/nfsclient by not printing anything in 'quiet' mode. Instead
issue a warning of it fails to set the sysctls.

16 years agoIntroduce a new lock, hostname_mtx, and use it to synchronize access
rwatson [Sat, 5 Jul 2008 13:10:10 +0000 (13:10 +0000)]
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

16 years agoTwo quotes too good to miss.
phk [Sat, 5 Jul 2008 08:54:58 +0000 (08:54 +0000)]
Two quotes too good to miss.

16 years agoMove duplicated code from tar_mode_[cru] into archive_write.
cperciva [Sat, 5 Jul 2008 08:10:55 +0000 (08:10 +0000)]
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.

16 years agoUse malloc in write_archive to allocate a 64kB buffer for holding file data
cperciva [Sat, 5 Jul 2008 08:03:08 +0000 (08:03 +0000)]
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.

16 years agoAdd CTF conversion to the objects compiled from generated code.
jb [Sat, 5 Jul 2008 06:12:14 +0000 (06:12 +0000)]
Add CTF conversion to the objects compiled from generated code.
This allows DTrace scripts to access variables like 'ostype'.

16 years agoClean up write_entry by eliminating fd except in the #ifdef __linux block
cperciva [Sat, 5 Jul 2008 06:05:34 +0000 (06:05 +0000)]
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]

16 years agobsdcpio is now at version 1.0.0.
kientzle [Sat, 5 Jul 2008 05:17:33 +0000 (05:17 +0000)]
bsdcpio is now at version 1.0.0.

16 years agoIn -pl mode, only hardlink regular files. I need to test
kientzle [Sat, 5 Jul 2008 05:16:23 +0000 (05:16 +0000)]
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.

16 years agoRemove an unused define.
kientzle [Sat, 5 Jul 2008 05:15:07 +0000 (05:15 +0000)]
Remove an unused define.

16 years agoRevert CVS revision 1.68; it is now possible for entry to be NULL at the end
cperciva [Sat, 5 Jul 2008 02:21:51 +0000 (02:21 +0000)]
Revert CVS revision 1.68; it is now possible for entry to be NULL at the end
of write_entry.  (This was perfectly safe, since archive_entry_free(NULL) is
a no-op, but adding the check back makes the style more consistent.)

16 years agoFreeBSD-CURRENT bsdtar is synched up with libarchive-portable 2.5.5.
kientzle [Sat, 5 Jul 2008 02:09:54 +0000 (02:09 +0000)]
FreeBSD-CURRENT bsdtar is synched up with libarchive-portable 2.5.5.

16 years agoRemove HAVE_STRUCT_STAT_ST_RDEV, as it's not used anywhere.
kientzle [Sat, 5 Jul 2008 02:09:13 +0000 (02:09 +0000)]
Remove HAVE_STRUCT_STAT_ST_RDEV, as it's not used anywhere.

16 years agoStop using the deprecated linux/ext2_fs.h.
kientzle [Sat, 5 Jul 2008 02:06:55 +0000 (02:06 +0000)]
Stop using the deprecated linux/ext2_fs.h.

16 years agoUse %H:%M for strftime() time formatting instead of the non-portable %R.
kientzle [Sat, 5 Jul 2008 02:05:55 +0000 (02:05 +0000)]
Use %H:%M for strftime() time formatting instead of the non-portable %R.

16 years agolibarchive in FreeBSD-CURRENT is now synched with libarchive-portable 2.5.5.
kientzle [Sat, 5 Jul 2008 01:50:40 +0000 (01:50 +0000)]
libarchive in FreeBSD-CURRENT is now synched with libarchive-portable 2.5.5.

16 years agoRemove a couple of capability definitions that are never used.
kientzle [Sat, 5 Jul 2008 01:50:07 +0000 (01:50 +0000)]
Remove a couple of capability definitions that are never used.

16 years agoWhen ARCHIVE_EXTRACT_PERM is requested (e.g., by "tar -p"), always
kientzle [Sat, 5 Jul 2008 01:48:33 +0000 (01:48 +0000)]
When ARCHIVE_EXTRACT_PERM is requested (e.g., by "tar -p"), always
schedule a chmod() fixup for directories.  In particular, this fixes
sgid handling on systems where the sgid bit is inherited from the
parent directory (which means that the actual mode of the dir
does not match the mode used in the mkdir() system call.

It may be possible to tighten this condition a bit.  In
working through this, I also found a few other places where
it looks like we can avoid a redundant syscall or two.  I've
commented those here but not yet tried to address them.

16 years agoDon't use the deprecated linux/ext2_fs.h include file.
kientzle [Sat, 5 Jul 2008 01:45:31 +0000 (01:45 +0000)]
Don't use the deprecated linux/ext2_fs.h include file.

16 years agoFix my previous commit. We actually should pass evaluation args in
rpaulo [Fri, 4 Jul 2008 23:40:53 +0000 (23:40 +0000)]
Fix my previous commit. We actually should pass evaluation args in
AcpiEvaluateObject() calls, otherwise, we are not able to bring devices
back up (NULL means 0, hence always off).
While there add missing WLAN on/off support.

MFC after: 3 days
Pointy hat to: rpaulo

16 years agoRemove the sbsh(4) driver. No one responded to requests for testing the
jhb [Fri, 4 Jul 2008 21:24:35 +0000 (21:24 +0000)]
Remove the sbsh(4) driver.  No one responded to requests for testing the
MPSAFE patches on current@ and stable@.  This driver also has a fundamental
issue in that it sleeps when sending commands to the card including in the
if_init/if_start routines (which can be called from interrupt context).  As
such, the driver shouldn't be working reliably even on 4.x.

16 years agoMake sbsh(4) MPSAFE:
jhb [Fri, 4 Jul 2008 21:13:18 +0000 (21:13 +0000)]
Make sbsh(4) MPSAFE:
- Add a mutex to the softc and use it to protect the softc and device
  hardware.
- Setup interrupt handler after ether_ifattach().
- Remove unused sbsh_watchdog() routine.
- Protect against concurrent attempts to load firmware.

16 years agoRemove the sbni(4) driver. No one responded to calls to test it on
jhb [Fri, 4 Jul 2008 21:06:57 +0000 (21:06 +0000)]
Remove the sbni(4) driver.  No one responded to calls to test it on
current@ and stable@.

16 years agoEnqueue de-capsulated packet instead of performing direct dispatch. It's
gonzo [Fri, 4 Jul 2008 21:01:30 +0000 (21:01 +0000)]
Enqueue de-capsulated packet instead of performing direct dispatch. It's
possible to exhaust and garble stack with a packet that contains a couple
of hundreds nested encapsulation levels.

Submitted by:   Ming Fu <fming@borderware.com>
Reviewed by:    rwatson
PR:             kern/85320

16 years agoMake sbni(4) MPSAFE:
jhb [Fri, 4 Jul 2008 20:53:41 +0000 (20:53 +0000)]
Make sbni(4) MPSAFE:
- Add a mutex to the softc and use it to protect the softc and device
  hardware.
- Setup interrupt handler after attaching device to network stack.
- Use device_set_desc() rather than device_quiet() plus a manual printf
  that simulates the normal probe printf.
- Axe next_sbni_unit and instead just leave room for two sbni devices for
  each bus attachment.
- Don't bzero the already-zero'd softc.
- Add a detach method to the PCI driver.
- Add a lock to protect the list of available devices used to chain
  interrupt handlers for dual port ISA cards.
- Remove unused watchdog routine.
- If if_alloc() fails, make sbni_attach() return an error rather than
  panic'ing.
- Consolidate code to free bus resources into sbni_release_resources().
- Clear IFF_DRV_RUNNING|OACTIVE in stop() routine instead of in callers.
- Let ether_ioctl() handle SIOCSIFMTU.

16 years agoCorrect an error in the comments for init_param3().
alc [Fri, 4 Jul 2008 19:36:58 +0000 (19:36 +0000)]
Correct an error in the comments for init_param3().

Discussed with: silby

16 years agoRemove the cnw(4) driver. No one responded to calls to test it on current@
jhb [Fri, 4 Jul 2008 19:13:15 +0000 (19:13 +0000)]
Remove the cnw(4) driver.  No one responded to calls to test it on current@
and stable@.  It also is a driver for an older non-802.11 wireless PC card
that is quite slow in comparison to say, wi(4).  I know Warner wants this
driver axed as well.

16 years agoMake cnw(4) MPSAFE:
jhb [Fri, 4 Jul 2008 19:04:07 +0000 (19:04 +0000)]
Make cnw(4) MPSAFE:
- Add a mutex to the softc and use it to lock the softc and device hardware.
- Use a private timer to replace if_watchdog/if_timer.
- Use if_printf() rather than if_xname.
- Setup interrupt handler after ether_ifattach().

16 years agoRemove the oltr(4) driver. No one responded to calls for testing on
jhb [Fri, 4 Jul 2008 18:58:53 +0000 (18:58 +0000)]
Remove the oltr(4) driver.  No one responded to calls for testing on
current@ and stable@ for the locking patches.  The driver can always be
revived if someone tests it.

This driver also sleeps in its if_init routine, so it likely doesn't really
work at all anyway in modern releases.

16 years agoMake oltr(4) MPSAFE:
jhb [Fri, 4 Jul 2008 18:27:14 +0000 (18:27 +0000)]
Make oltr(4) MPSAFE:
- Add a mutex to the softc and use it to protect the softc and device
  hardware.
- Setup interrupt handler after interface attach.
- Retire 'unit' from softc and use if_printf() instead.
- Don't frob IFF_UP in the driver.
- Use callout_() rather than timeout() and untimeout().

16 years agoRemove the arl(4) driver. It is reported to not work on 6.x or later
jhb [Fri, 4 Jul 2008 18:15:36 +0000 (18:15 +0000)]
Remove the arl(4) driver.  It is reported to not work on 6.x or later
even though the driver hasn't changed since 4.x (last known working
release).

16 years agoMake arl(4) MPSAFE:
jhb [Fri, 4 Jul 2008 17:48:34 +0000 (17:48 +0000)]
Make arl(4) MPSAFE:
- Add a mutex to the softc and use it to protect the softc and device
  hardware.
- Setup interrupt handler after ether_ifattach().
- Use a private timer instead of if_timer/if_watchdog.
- Retire arl_unit from the softc and use if_printf() and device_printf()
  instead.

Note that the unpatched driver in 6.x and later does not work with the
hardware, so the one person who had volunteered to test the patch wasn't
able to test it.

16 years agoEliminate an unused declaration. (In fact, the declaration is bogus
alc [Fri, 4 Jul 2008 17:36:12 +0000 (17:36 +0000)]
Eliminate an unused declaration.  (In fact, the declaration is bogus
because the variable is defined static to pmap.c on i386.)

Found by: CScout

16 years agoAdd manpage for Apple BMAC ethernet driver.
nwhitehorn [Fri, 4 Jul 2008 14:51:42 +0000 (14:51 +0000)]
Add manpage for Apple BMAC ethernet driver.

Approved by: marcel (mentor)

16 years agoRemove Japanese document.
nyan [Fri, 4 Jul 2008 12:19:56 +0000 (12:19 +0000)]
Remove Japanese document.

16 years agoThe uniqdosname() function takes char[12] as it third argument.
kib [Fri, 4 Jul 2008 09:40:52 +0000 (09:40 +0000)]
The uniqdosname() function takes char[12] as it third argument.

Found by: -fstack-protector
Reported by: dougb
Tested by: dougb, Rainer Hurling <rhurlin gwdg de>
MFC after: 3 days

16 years agoport % count will never be greater than LAGG_MAX_PORTS so nuke the test.
thompsa [Fri, 4 Jul 2008 05:33:58 +0000 (05:33 +0000)]
port % count will never be greater than LAGG_MAX_PORTS so nuke the test.

16 years agosunlabel(8) is specific to sparc64. Remove from other platforms.
marcel [Fri, 4 Jul 2008 04:39:45 +0000 (04:39 +0000)]
sunlabel(8) is specific to sparc64. Remove from other platforms.
use gpart(8) on all platforms.

16 years agoMake sunlabel specific to sparc64. This is mostly for backward
marcel [Fri, 4 Jul 2008 04:33:33 +0000 (04:33 +0000)]
Make sunlabel specific to sparc64. This is mostly for backward
compatibility reasons. Sun labels, with VTOC8, are handled by
gpart(8).

16 years agoRemove NETISR_MPSAFE, which allows specific netisr handlers to be directly
rwatson [Fri, 4 Jul 2008 00:21:38 +0000 (00:21 +0000)]
Remove NETISR_MPSAFE, which allows specific netisr handlers to be directly
dispatched without Giant, and add NETISR_FORCEQUEUE, which allows specific
netisr handlers to always be dispatched via a queue (deferred).  Mark the
usb and if_ppp netisr handlers as NETISR_FORCEQUEUE, and explicitly
acquire Giant in those handlers.

Previously, any netisr handler not marked NETISR_MPSAFE would necessarily
run deferred and with Giant acquired.  This change removes Giant
scaffolding from the netisr infrastructure, but NETISR_FORCEQUEUE allows
non-MPSAFE handlers to continue to force deferred dispatch so as to avoid
lock order reversals between their acqusition of Giant and any calling
context.

It is likely we will be able to remove NETISR_FORCEQUEUE once
IFF_NEEDSGIANT is removed, as non-MPSAFE usb and if_ppp drivers will no
longer be supported.

Reviewed by: bz
MFC after: 1 month
X-MFC note: We can't remove NETISR_MPSAFE from stable/7 for KPI reasons,
but the rest can go back.

16 years agoUse bcopy instead of strlcpy in uipc_bind and unp_connect, since
emaste [Thu, 3 Jul 2008 23:26:10 +0000 (23:26 +0000)]
Use bcopy instead of strlcpy in uipc_bind and unp_connect, since
soun->sun_path isn't a null-terminated string.  As UNIX(4) states, "the
terminating NUL is not part of the address."  Since strlcpy has to return
"the total length of the string [it] tried to create," it walks off the end
of soun->sun_path looking for a \0.

This reverts r105332.

Reported by:    Ryan Stone

16 years agoAdd regression tests for fmin{,f,l} and fmax{,f,l}.
das [Thu, 3 Jul 2008 23:06:06 +0000 (23:06 +0000)]
Add regression tests for fmin{,f,l} and fmax{,f,l}.
I wrote these to test amd64 asm functions that used
maxss, maxsd, minss, and minsd, but it turns out that
those instructions don't handle NaNs and signed zero
in the same way as fmin() and fmax() are required to,
so we're stuck with the C versions for now.

16 years agoOn 64 bit architectures, you can run 32 bit executables and the rtld can trace them...
edwin [Thu, 3 Jul 2008 22:37:51 +0000 (22:37 +0000)]
On 64 bit architectures, you can run 32 bit executables and the rtld can trace them, but ldd(1) doesn't know yet how to detect them:

    [/] root@ed-exigent>ldd `which httpd`
    ldd: /usr/local/sbin/httpd: can't read program header
    ldd: /usr/local/sbin/httpd: not a dynamic executable

    But...

    [/] root@ed-exigent>LD_32_TRACE_LOADED_OBJECTS==1 `which httpd`
    libm.so.4 => /lib32//libm.so.4 (0x280c8000)
    libaprutil-1.so.2 => /usr/local/lib/libaprutil-1.so.2 (0x280de000)
    libexpat.so.6 => /usr/local/lib/libexpat.so.6 (0x280f2000)
    libiconv.so.3 => /usr/local/lib/libiconv.so.3 (0x28110000)
    libapr-1.so.2 => /usr/local/lib/libapr-1.so.2 (0x281fd000)
    libcrypt.so.3 => /lib32//libcrypt.so.3 (0x2821d000)
    libpthread.so.2 => not found (0x0)
    libc.so.6 => /lib32//libc.so.6 (0x28235000)
    libpthread.so.2 => /usr/lib32/libpthread.so.2 (0x2830d000)

Added support in ldd(1) for the LD_32_xxx environment variables if
the architecture of the machine is >32 bits. If we ever go to 128
bit architectures this excercise will have to be repeated but thanks
to earlier commits today it will be relative simple.

PR: bin/124906
Submitted by: edwin
Approved by: bde (mentor)
MFC after: 1 week

16 years agoExtract the determination of the kind of (dynamic) executable from
edwin [Thu, 3 Jul 2008 22:30:18 +0000 (22:30 +0000)]
Extract the determination of the kind of (dynamic) executable from
the main-loop into a seperate function.
Instead of using hardcoded environment variables, define them in a
lookup table.
For the rest, no functionality changes.

Approved by: bde (mentor)
MFC after: 1 week

16 years agostylify ldd.c, no functional changes.
edwin [Thu, 3 Jul 2008 22:26:43 +0000 (22:26 +0000)]
stylify ldd.c, no functional changes.

Approved by: bde (mentor)
MFC after: 1 week

16 years agoFix some locking and logic bugs pointed out by jhb. These fix driver detach and speed...
nwhitehorn [Thu, 3 Jul 2008 21:51:30 +0000 (21:51 +0000)]
Fix some locking and logic bugs pointed out by jhb. These fix driver detach and speed up data transfer by nearly a factor of 2.

Approved by: marcel (mentor)

16 years agoBelatedly add myself to the committers graph
cokane [Thu, 3 Jul 2008 21:45:25 +0000 (21:45 +0000)]
Belatedly add myself to the committers graph

16 years agobsdlabel and fdisk are obsoleted on ia64.
marcel [Thu, 3 Jul 2008 21:00:16 +0000 (21:00 +0000)]
bsdlabel and fdisk are obsoleted on ia64.
While here, make sure to remove any remnants of the disklabel
manpage.

16 years agoStop building bsdlabel(8) and fdisk(8) on ia64. Both tools are
marcel [Thu, 3 Jul 2008 20:53:15 +0000 (20:53 +0000)]
Stop building bsdlabel(8) and fdisk(8) on ia64. Both tools are
obsoleted by gpart(8). This avoids the following bugs in fdisk:
-  initializing a disk without MBR bogusly emits the error:
fdisk: invalid fdisk partition table found
-  initializing a disk with or without MBR bogusly emits either:
fdisk: Class not found
   or
fdisk: Geom not found: "XXX"
-  the default geometry for non-ATA and non-SCSI disks is either
   invalid or sub-optimizal.

16 years agoAdd NO_MAN for the static variant of geom(8). Both the RESCUE and the
marcel [Thu, 3 Jul 2008 19:40:59 +0000 (19:40 +0000)]
Add NO_MAN for the static variant of geom(8). Both the RESCUE and the
RELEASE_CRUNCH builds use NO_MAN anyway, so this change is primarily
to avoid that developers have to set NO_MAN manually when they build
the static variant.

16 years agoAdd myself to src committers graph.
nwhitehorn [Thu, 3 Jul 2008 18:57:00 +0000 (18:57 +0000)]
Add myself to src committers graph.

Approved by: marcel (mentor)

16 years agoBelatedly add myself to the active *cough* doc committers.
marcel [Thu, 3 Jul 2008 17:10:18 +0000 (17:10 +0000)]
Belatedly add myself to the active *cough* doc committers.

16 years agoBelatedly add myself to the alumni section.
marcel [Thu, 3 Jul 2008 17:02:43 +0000 (17:02 +0000)]
Belatedly add myself to the alumni section.

16 years agoSoren was my mentor.
marcel [Thu, 3 Jul 2008 16:53:19 +0000 (16:53 +0000)]
Soren was my mentor.
I have mentored arun and marius.

16 years agoBelatedly add myself to the active committer section.
marcel [Thu, 3 Jul 2008 16:49:33 +0000 (16:49 +0000)]
Belatedly add myself to the active committer section.