122300 Commits

Author SHA1 Message Date
des
677443f91f MFC: (1.6) childerr needs to be volatile.
PR:		bin/85830
2007-09-28 07:04:35 +00:00
des
e05a1478d5 MFC: Synch with HEAD. 2007-09-28 06:35:14 +00:00
des
8697e3fed7 MFC: (1.5) use sprintf() rather than (unportable) strlcpy().
Also bobbit some unused variables.
2007-09-28 06:34:22 +00:00
jinmei
a5dfa0a1a7 MFC:
ensure the head entry of addrinfo chain has non-NULL ai_canonname to be
compliant with RFC3493.

PR: standards/114910
Approved by:   ume (mentor)
lib/libc/net/getaddrinfo.c:	1.86
2007-09-28 06:23:03 +00:00
bmah
1d2954da88 MFC: camcontrol(8) readcap. 2007-09-28 05:08:34 +00:00
edwin
c4790b8a43 MFCs
Dutch calendar
    More dates: Sint Maarten, Dierendag, Trinitatis
    Fix spelling: Carnaval
    Add more of the Royal Family.

Croation calendars:
    Update to calendar/calendars/hr_HR.ISO_8859-2/calendar.praznici
    with fixes and new dates.

PR:             conf/26658
Submitted by:   Josip Rodin <joy@gkvk.hr>
2007-09-28 02:51:26 +00:00
edwin
aa461f0b09 MFC: Fix man(1) to allow .so to reference a compressed file
Original PR description:

        man(1) can't handle compressed included files.

        Some ports will install with compressed manpages. man handles
        this by looking for the .gz version of a man source file.
        It is also common to include other files with the .so
        directive where commands or functions share a man page.
        Traditionally ports have had to handle this by either not
        compressing the manpages, or using the _MLINKS macro in the
        port makefile to create symlinks to the actual source file,
        rather than using .so versions. Notably, the current version
        of Xorg port breaks. See ports/113096 and ports/115845.

PR:             bin/115850
Submitted by:   Callum Gibson <callumgibson@optusnet.com.au>
2007-09-28 02:31:57 +00:00
jhb
3c7672b104 Remove the *_queue() variants of various sleepq and turnstile functions
and always require the queue to be specified to reduce diffs with HEAD.
These APIs are internal APIs only used to implement higher level primitives
such as locks and condition variables.

Approved by:	alfred
2007-09-27 20:24:56 +00:00
jhb
1248dc42fa MFC some comment updates to account for multi-queue support missed earlier
as well as a few other changes (whitespace, style, etc.) to reduce diffs
with HEAD.
2007-09-27 18:44:16 +00:00
jhb
bf60b344e1 - Remove some debugging nits in the MFC of rwlocks that looked for cases
where a reader blocked on a lock with no owner and just assert that it
  never happens like HEAD.
- Actually set td->td_tsqueue to the sub-queue of a turnstile that a
  thread is actually enqueued to.  Otherwise, the kernel would always
  think that threads were on the queue for exclusive (write) waiters
  (queue 0).  Thus, if the priority of a thread waiting on a read lock
  was adjusted while it was waiting it could result in corrupting the
  queue of waiting threads.
2007-09-27 18:39:18 +00:00
jhb
f8d0499c66 MFC 1.167: Use a UMA zone to handle the turnstile objects rather than
malloc(9).
2007-09-27 18:23:44 +00:00
jhb
a4cadc0209 Make td_sqqueue a char and move it into a pre-existing "hole" from
alignment padding to restore the ABI of 'struct thread' in 6.x.
2007-09-27 18:12:25 +00:00
jhb
bcef6cfce9 - Restore the 'show sleepq' DDB command.
- Trim some extra includes.
2007-09-27 18:10:40 +00:00
jhb
5c87605e74 Use lock_init() and lock_destroy(). 2007-09-27 18:08:09 +00:00
jhb
532b026a40 A few tweaks to reduce diffs with HEAD including using lock_init() and
lock_destroy() and adding a missing #include so that NO_ADAPTIVE_RWLOCKS
is honored.
2007-09-27 18:06:49 +00:00
ru
d824151b34 MFC: rev. 1.23: Fix the CPU usage display. 2007-09-27 06:35:27 +00:00
kientzle
828873a7fe MFC spelling correction. 2007-09-27 03:47:26 +00:00
kientzle
77ebdb43f5 MFC 1.17: Make return values from archive_write_data()
consistent whether you're writing to an archive or to disk.
2007-09-27 03:45:24 +00:00
kientzle
b2f9cd5319 MFC 1.77: Support --posix as a synonym for --format=pax, for
GNU tar compatibility.
2007-09-27 03:42:59 +00:00
mav
4ae2b7a8da MFC rev. 1.82-1.84
Fix thread unsafe usage of global pkt_hdr variable.
Optimize ether and debug hooks determination.
Remove some dead code.
2007-09-26 19:15:14 +00:00
jhb
d21c68d5f5 MFC: Properly look for neighbor USB 1.x controllers and fix a memory leak. 2007-09-26 17:33:18 +00:00
mtm
85a486d312 MFC:
Revision  Path
	  1.82      src/etc/rc.d/Makefile
	  1.16      src/etc/rc.d/lockd
	  1.17      src/etc/rc.d/lockd
	  1.18      src/etc/rc.d/lockd
	  1.15      src/etc/rc.d/nfslocking
	  1.16      src/etc/rc.d/statd
	  1.17      src/etc/rc.d/statd

	Split rc.d/nfslocking into two separate scripts: rc.d/lockd
	and rc.d/statd. Keep rc.d/nfslocking for POLA reasons but do
	not run it during system startup.

	PR: conf/107316

	  Revision  Path
	  1.14      src/etc/rc.d/nfslocking

	The precmd routine does not need to check whether the comman
	should be "forced". If some pre-condition is not met, it should
	fail as it normally does and rc.subr(8) will make the appropriate
	decision. Incidentally, the previous behaviour had a bug where
	the "force" flag was respected only when checking rc.conf(5) knobs.
	The flag was ignored when verifying the rpcbind(8) dependency.
2007-09-26 11:02:28 +00:00
bz
4b73c7f73d MFC rev. 1.147
Fix a DIV0 in case a large value for fs_avgfilesize or fs_avgfpdir
  is given (with newfs or tunefs) and dirsize overflows.

  In case dirsize is <= 0 because of an overflow set maxcontigdirs
  to 0 so it will be 1 later. This is what would happen for large
  fs_avgfilesize. [1]

  Submitted by:                   pjd [1]
2007-09-24 13:39:06 +00:00
scf
37617c42be MFC:
Sync usage() with reality.

    src/usr.bin/locate/locate/locate.c: rev 1.16 -> 1.17

Approved by:	wes
2007-09-22 02:46:13 +00:00
obrien
30cde5d032 MFC: flopen(3), expand_number(3), kld_isloaded(3) 2007-09-21 21:23:04 +00:00
obrien
1684759154 MFC: rev. 1.4: consume flopen(3). 2007-09-21 17:27:48 +00:00
obrien
a0569a49ba MFC: consume kld_isloaded(3). 2007-09-21 17:25:03 +00:00
ambrisko
a6e3052cba MFC: 1.51
Fix an incorrect PCI device id.  The current value conflicts with
  the mfi(4) LSI MegaSAS RAID card.  Looking at the Linux driver for the
  mpt(4) it should be 0x0062 and not 0x0060.  Tested with an mfi card
  of this device id.

Reviewed by:	scottl
2007-09-21 16:43:31 +00:00
obrien
ed8bda3771 Bump for libutil(3) MFC's (and any others around this time). 2007-09-21 15:33:38 +00:00
obrien
a8179dace9 MFC: kld(3) 2007-09-21 14:52:31 +00:00
obrien
770cbe4aab style.Makefile(9) 2007-09-21 14:49:38 +00:00
obrien
30091bf34c MFC: flopen(3) 2007-09-21 14:41:55 +00:00
obrien
11a30b20fa Logically, this now first appeared in FreeBSD 6.3. 2007-09-21 14:39:46 +00:00
obrien
2ce446b128 MFC: refer to expand_number(3) and markup fixes 2007-09-21 14:35:34 +00:00
obrien
bd617ef43a MFC: expand_number(3) 2007-09-21 14:35:02 +00:00
netchild
14e0307002 Disable the module building of the linux bits on alpha and remove them
from the corresponding NOTES. [1]

There's no corresponding linux_base in the Ports Collection since years,
and no linux distribution which is up-to-date and suitable (security,
widespread, ...) for us. The only complain regarding linux & alpha
we got so far is that the linuxulator doesn't build anymore. This
complaint came from wilko -- the alhpa-part of re@ -- only. As the
alpha platform is dead (no support from the manufacturer / linux
distributions) and deprecated (removed in -current) it was decided to
disable the linux bits from the build instead of trying to fix the
problems on alpha.

The alpha parts in the source are not removed so far, in case there are
1-2 people which actually still make use of this and are interested to
use the linuxulator (and fix the problems). Additionally this prevents
regressions on i386/amd64 when removing the alpha bits in shared code
(the people which care about those code parts don't have enough time ATM
to do extensive testing). This decission may be revisited at a later
point in time.

Discussed with:	wilko [1]
2007-09-20 06:33:26 +00:00
krion
3a222ba443 MFC: extract.c:1.45
date: 2007/08/23 13:05:10;  author: krion;  state: Exp;  lines: +1 -1
  Fix pkg_add behaviour to preserve pathnames.

  PR:             bin/93915 bin/109134
  Submitted by:   Jason Heiss <heissj@yahoo-inc.com>, Constantin Stefanov<cstef@mail.ru>
  Approved by:    re@ (kensmith)
  MFC after:      7 days
2007-09-19 08:41:27 +00:00
ken
b19aa20b61 MFC:
camcontrol/Makefile:	rev 1.17
camcontrol.8:		rev 1.44
camcontrol.c:		rev 1.58

Add SCSI READ CAPACITY support to camcontrol.  The new 'readcap' subcommand
will automatically issue the 16 byte verison of read capacity if the device
in question is larger than 2TB.

There are also a number of output options here (last block, number of
blocks, human readable) that should meet most needs, and also aid in
scripting.
2007-09-18 01:26:28 +00:00
julian
42892c3888 MFC in revs 192-194 of the man page.
The actual code has been in for a while. (Allow tablearg to be used with 'fwd'
and allow it to take an IP address as a value).
2007-09-17 23:59:54 +00:00
julian
fcea08ef61 MFC:
remove test that fails POLA.
2007-09-17 17:50:49 +00:00
obrien
68d94c3658 Make life with "makeoptions INSTALL_DEBUG" easier. 2007-09-17 16:19:02 +00:00
mav
e036ae33c5 MFC rev. 1.70
Fix typo which brokes VJ decompression
when VJC negotiated in only one direction.
2007-09-16 13:33:32 +00:00
danger
ad7686616e MFC Revision 1.61:
- Sweep the boot(8) man page after addition of boot.config(5).
2007-09-16 10:53:04 +00:00
danger
6c3bf561ff MFC the boot.config.5 manual page. 2007-09-16 10:47:52 +00:00
obrien
9d7f2220a4 Enable 'LD_LIBRARY_PATH=/foo:/bar ld -lfooz'
PR:	96481
2007-09-16 03:41:47 +00:00
marius
22bfee0171 MFC: am7990.c 1.4; am79900.c 1.4; if_le_ledma.c 1.3; if_le_pci.c 1.5, 1.6;
lance.c 1.3, 1.4; lancevar.h 1.3

- Use our own callout instead of if_slowtimo() for driving lance_watchdog()
  in order to avoid races accessing if_timer.
- Use bus_get_dma_tag() to obtain the parent DMA tag so le(4) works on
  platforms requiring this.
- Remove BUS_DMA_WAITOK from bus_dma_tag_create() invocations as it's
  no valid flag there.
- For setting the port PCnet chips must be powered down or stopped and
  unlike documented may not take effect without an initialization. So
  don't invoke (*sc_mediachange) directly in lance_mediachange() but
  go through lance_init_locked(). It's suboptimal to impose this for
  all chips but given that besides the affected PCI bus front-end the
  only other front-end which supports media selection is and likely
  ever will be the 'ledma' front-end I see not enough reason to break
  the in-driver API for this (though one could argue both ways here).
2007-09-15 10:56:00 +00:00
marius
12bc0e99f3 MFC: if_gem.c 1.37, 1.39, 1.40, 1.43; if_gemvar.h 1.12
- Fix -Wundef warnings found when compiling i386 LINT, GENERIC and
  custom kernels.
- Use bus_get_dma_tag() so gem(4) works on platforms requiring it.
- Use the gem_tick() callout instead of if_slowtimo() for driving
  gem_watchdog() in order to avoid races accessing if_timer.
  While at it relax the watchdog a bit by reloading it in gem_tint()
  if there are still packets enqueued.
- Don't bother to set if_mtu to ETHERMTU, ether_ifattach() does that.
- Fix inconsistencies in prototypes.
2007-09-15 10:49:57 +00:00
marius
ee49306c35 MFC: if_hme.c 1.50, 1.51, 1.52, 1.53; if_hmevar.h 1.10
o Revised MII support:
  - In hme_stop() mask all interrupts.
  - In hme_eint() print MIF register contents on MIF interrupts.
  - In hme_mifinit() don't bother to preserve the previous MIF config.
    This was mainly done in order to preserve the PHY select bit (external
    or internal PHY) but which only needs to be set as appropriate when
    reading from or writing to the desired PHY in hme_mii_{read,write}reg().
    Similarly don't bother to set the PHY select bit in hme_mii_statchg().
  - In hme_mii_{read,write}reg() ignore requests to PHYs other than the
    external and internal PHY one.
  - Move enabling/disabling the MII drivers of the external transceiver from
    hme_init_locked() and based on the sheer presence of an external one
    to hme_mifinit() and based on the currently selected media, defaulting
    to the internal transceiver when the media hasn't been set, yet.
    Invoke hme_mifinit() from the newly added hme_mediachange_locked() so
    the setting of the MII drivers is updated when changing media.
    These changes keep the MII bus from wedging (which manifests in the HME
    and the PHYs no longer being able to communicate with each other) when
    the PHY device drivers isolate the unused PHY in two-PHY configurations
    as present in f.e. Netra t1 100 while changing media, either from
    hme_init_locked() (see also below) or via ifconfig(8) (not with the
    RELENG_6 ifconfig(8) and miibus(4) though). They also allow for using
    both transceivers/PHYs.
  - In the newly added hme_mediachange_locked() also reset the PHYs in two-
    PHY configurations before invoking mii_mediachg(). This is required
    for successfully unisolating the previously unused PHY when switching
    between PHYs.
  - Now that changing media should no longer cause problems back out rev.
    1.27 and re-enable setting the current media in hme_init_locked() (see
    the commit message of rev. 1.23 for more info).
  These changes are roughly a merge of NetBSD hme.c rev. 1.32 - 1.35 (1.30
  was already fixed differently in our 1.36; 1.31 and 1.32 were wrong) with
  some parts reworked and things that don't make sense like setting the MII
  drivers and restoring the previous MIF and XIF settings in hme_mii_{read,
  write}reg() omitted.
o Use the hme_tick() callout instead of if_slowtimo() for driving
  hme_watchdog() in order to avoid races accessing if_timer.
o Use bus_get_dma_tag() so hme(4) works on platforms requiring it.
o Don't bother to set if_mtu to ETHERMTU, ether_ifattach() does that.
o Remove invalid BUS_DMA_ALLOCNOW when creating a tag which is used for
  a "static" memory allocation only.
2007-09-15 10:45:34 +00:00
marius
247db35911 MFC: 1.20
- Don't set MIIF_NOISOLATE so ukphy(4) can be used in configurations with
  multiple PHYs. In case some PHYs currently driven by ukphy(4) exhibit
  problems when isolating due to incomplete implementations or silicon bugs
  we'll need to add specific drivers for these. Looking at NetBSD and
  OpenBSD I don't expect problems here though (quite the contrary; we still
  seem to set MIIF_NOISOLATE without good reason in a bunch of PHY drivers).
- Fix a style(9) whitespace nit.
2007-09-15 10:41:33 +00:00
marius
39a9fbb107 MFC: if_dc.c 1.166 1.171, 1.189 (partial), 1.190, 1.192; if_dcreg.h 1.54
- In detach method, move if_free() after bus_teardown_intr().
- Use our own callout (the dc_tick() callout uses varying periods
  depending on the NIC and isn't used at all with HomePNA links)
  instead of if_slowtimo() for driving dc_watchdog() in order to
  avoid races accessing if_timer.
- Use bus_get_dma_tag() so dc(4) works on platforms requiring it.
- Don't bother to set if_mtu to ETHERMTU, ether_ifattach() does that.
- Fix a bug originally introduced in rev. 1.74; don't reloaded the
  watchdog timer in dc_txeof() in case there are still unhandled
  descriptors as dc_poll() invokes dc_poll() unconditionally.
  Otherwise this would result in the watchdog timer constantly being
  being reloaded and thus circumvent that the watchdog ever fires in
  the DEVICE_POLLING case.
2007-09-15 10:00:51 +00:00