freebsd/src.git
14 years agoPrepare for tagging RELENG_7_0_0_RELEASE and the 7.0-RELEASE builds.release/7.0.0
Ken Smith [Sun, 24 Feb 2008 05:45:16 +0000 (24 05:45 +0000)]
Prepare for tagging RELENG_7_0_0_RELEASE and the 7.0-RELEASE builds.

Approved by: re (implicit)

14 years agoSpeculate on the release date for FreeBSD 7.0.
Ken Smith [Sun, 24 Feb 2008 05:17:54 +0000 (24 05:17 +0000)]
Speculate on the release date for FreeBSD 7.0.

Approved by: re (implicit)

14 years agoMFC: rev. 1.4
Christian Brueffer [Thu, 21 Feb 2008 23:29:26 +0000 (21 23:29 +0000)]
MFC: rev. 1.4

Add some missing Xrefs to drivers.

Approved by: re (kensmith)

14 years agoPrepare for a "mini-RC3". Only amd64/i386 builds will be done. Targetted
Ken Smith [Wed, 20 Feb 2008 04:37:25 +0000 (20 04:37 +0000)]
Prepare for a "mini-RC3".  Only amd64/i386 builds will be done.  Targetted
at getting people to test the backout of the hptrr(4) driver.

Approved by: re (implicit)

14 years agoMFR7 the backout of hptrr v1.2 due to problems encountered during testing
Ken Smith [Wed, 20 Feb 2008 04:35:24 +0000 (20 04:35 +0000)]
MFR7 the backout of hptrr v1.2 due to problems encountered during testing
of 7.0-RC2.  Versions being MFR7-ed:

        1.1.2.3   amd64-elf.hptrr_lib.o.uu
        1.1.2.3   array.h
        1.1.2.3   him.h
        1.1.2.3   hptintf.h
        1.1.2.3   hptrr_config.c
        1.1.2.3   hptrr_config.h
        1.1.2.4   hptrr_os_bsd.c
        1.1.2.3   hptrr_osm_bsd.c
        1.1.2.3   i386-elf.hptrr_lib.o.uu
        1.1.2.3   ldm.h
        1.1.2.3   os_bsd.h
        1.1.2.4   osm.h

Approved by:    re (rwatson)

14 years agoMFC: Properly advertise U320 transport capabilities to CAM.
Justin T. Gibbs [Tue, 19 Feb 2008 17:08:34 +0000 (19 17:08 +0000)]
MFC: Properly advertise U320 transport capabilities to CAM.
MFC: Quiet sense data logging behind AHD_DEBUG/AHD_SHOW_SENSE.

Approved by: re (kensmith)

14 years agoCatch up with 1.1068.2.20.2.3.
Xin LI [Sun, 17 Feb 2008 01:16:40 +0000 (17 01:16 +0000)]
Catch up with 1.1068.2.20.2.3.

Approved by: re (bmah)

14 years agoMFC: rev. 1.3
Christian Brueffer [Sat, 16 Feb 2008 20:29:06 +0000 (16 20:29 +0000)]
MFC: rev. 1.3

The hptrr driver first appeared in 6.3, not 5.3.

Approved by: re (bmah)

14 years agoNew release notes: SA-08:03.sendfile, 700MB CDROM media for ISOs,
Bruce A. Mah [Sat, 16 Feb 2008 16:03:48 +0000 (16 16:03 +0000)]
New release notes:  SA-08:03.sendfile, 700MB CDROM media for ISOs,
rr232x(4) gone.

Modified release notes:  Added missing word to SA-08:02.libc note,
mention SATA RAID in hptiop(4) note, FILE 4.23.

Approved by: re (implicitly)

14 years agoMFC rev.1.13: Use case-insensitive comparisons for HTTP header keywords.
Colin Percival [Fri, 15 Feb 2008 16:17:28 +0000 (15 16:17 +0000)]
MFC rev.1.13: Use case-insensitive comparisons for HTTP header keywords.

Approved by: re (kensmith)

14 years agoMFC: rev. 1.325
Christian Brueffer [Fri, 15 Feb 2008 15:19:26 +0000 (15 15:19 +0000)]
MFC: rev. 1.325

Remove dublicate MLINK.

Approved by: re (bmah)

14 years agoMFC: share/man/man4/ciss.4:1.15, sys/dev/ciss/ciss.c:1.87
Mitsuru IWASAKI [Fri, 15 Feb 2008 13:55:23 +0000 (15 13:55 +0000)]
MFC: share/man/man4/ciss.4:1.15, sys/dev/ciss/ciss.c:1.87

Add `hw.ciss.nop_message_heartbeat' tunable (default disabled) for
NOP-message polling in ciss_periodic().
Note that setting the tunable to non-zero can be workaround only for
`ADAPTER HEARTBEAT FAILED' problem, and may freeze the system w/o
the problem.

Approved by: re (kensmith)

14 years agoMFC: machdep.c:1.230, pmap.c:1.197
Marcel Moolenaar [Thu, 14 Feb 2008 22:51:52 +0000 (14 22:51 +0000)]
MFC: machdep.c:1.230, pmap.c:1.197

On Montecito processors, the instruction cache is in fact not
coherent with the data caches. Implement a quick fix to allow
us to boot on Montecito, while I'm working on a better fix in
the mean time.

Approved by: re (kensmith - big thanks!)

14 years agoMFC rev 1.22 hosts.equiv.5
Remko Lodder [Thu, 14 Feb 2008 21:48:53 +0000 (14 21:48 +0000)]
MFC rev 1.22 hosts.equiv.5

  v1.22
  Improve readability for the hosts.equiv file regarding the notation
  of hostnames.

  PR: docs/35953
  Submitted by: "Gary W. Swearingen" <swear at blarg dot net>
With minor modifications by me.

Approved by: re (bmah)

14 years agoMFC revs 1.17 to 1.18 timed.8
Remko Lodder [Thu, 14 Feb 2008 21:48:24 +0000 (14 21:48 +0000)]
MFC revs 1.17 to 1.18 timed.8

  v1.18
  Typo fix.

  Spotted by: brueffer

  v1.17
  Enhance descriptions in the timed manual.

  PR: docs/115445
  Submitted by: "Julian Stacey" <jhs at berklix dot org>
  MFC After: 3 days

Approved by: re (bmah)

14 years agoMFC rev 1.9 to 1.11 nve.4
Remko Lodder [Thu, 14 Feb 2008 21:47:49 +0000 (14 21:47 +0000)]
MFC rev 1.9 to 1.11 nve.4

  v1.11
  Language nit.

  v1.10
  There is no list to stop, so dont use .El.

  Noticed by: brueffer

  v1.9
  Add 1000baseTX support for the nve driver, which is known here and there.

  Also mention that the driver sometimes returns '10baseTX' as output instead
  of 100baseTX (which is the case at that moment).

  PR: docs/115284
  Submitted by: Julian Stacey Jhs <jhs at berklix dot org>
  MFC After: 3 days

Approved by: re (bmah)

14 years agoMFC rev 1.69 to 1.70 bsdlabel.8
Remko Lodder [Thu, 14 Feb 2008 21:46:19 +0000 (14 21:46 +0000)]
MFC rev 1.69 to 1.70 bsdlabel.8

  v1.70
  Remove redundant whitespace.

  Noticed by: brueffer

  v1.69
  Attempt to describe the ''auto'' type a bit better in the default
  section (if nothing had been specified, or if the auto type had
  been specified, a default layout is used).

  PR: docs/116047
  Submitted by: Ian Smith <smithi at nimnet dot asn dot au>
Minor modifications by me.

Approved by: re (bmah)

14 years agoMFC rev 1.20 to 1.23 access.2
Remko Lodder [Thu, 14 Feb 2008 21:45:41 +0000 (14 21:45 +0000)]
MFC rev 1.20 to 1.23 access.2

  v1.23
  After issueing a ntpdate [1] I noticed it's already 2008, reflect that
  in the last modified date.

  Noticed by: brueffer [1]

  v1.22
  Fix typo (s/existance/existence/)

  Noticed by: ceri

  v1.21
  Fix some style nits.

  Prodded by: brueffer
  MFC After: 3 days

  v1.20
  Make the warning a bit less 'broad' then it used to be.  The access
  is seems to be a problem for SUID applications, which we like to
  prevent as much as possible.

  PR: docs/39530
  Submitted by: Soren Spies <sspies at apple dot com>
  MFC After: 3 days

Approved by: re (bmah)

14 years agoMFC: rev. 1.26
Christian Brueffer [Thu, 14 Feb 2008 20:52:03 +0000 (14 20:52 +0000)]
MFC: rev. 1.26

Add missing \n.

Approved by: re (bmah), rwatson (mentor), aradford@amcc.com

14 years agoMFC rev 1.153 nfs_srvsubs.c
Remko Lodder [Thu, 14 Feb 2008 14:12:13 +0000 (14 14:12 +0000)]
MFC rev 1.153 nfs_srvsubs.c

Use nfsrv_destroycache() only once, else it crashes the server.

  PR: kern/118152
  Submitted by: Bjoern Groenvall <bg at sics dot se>
  Approved by: imp (mentor, a while ago already), jhb
  MFC After: 3 days

Approved by: re (kensmith), imp (mentor, implicit)

14 years agoFix sendfile(2) write-only file permission bypass.
Simon L. B. Nielsen [Thu, 14 Feb 2008 11:45:41 +0000 (14 11:45 +0000)]
Fix sendfile(2) write-only file permission bypass.

Security: FreeBSD-SA-08:03.sendfile
Approved by: re (kensmith)

14 years agoMFC version 1.14, from the 4 February 2008 update:
Doug Barton [Thu, 7 Feb 2008 20:55:42 +0000 (7 20:55 +0000)]
MFC version 1.14, from the 4 February 2008 update:
IPv6 addresses for 6 of the root name servers!

Approved by: re (kensmith)

14 years agoGet ready for the 7.0-RC2 builds.
Ken Smith [Thu, 7 Feb 2008 12:50:27 +0000 (7 12:50 +0000)]
Get ready for the 7.0-RC2 builds.

Approved by: re (implicit)

14 years agoMFC rev 1.4: fix a bug in hexadecimal formatting of the CHAP digest:
Pierre Beyssac [Thu, 7 Feb 2008 00:08:57 +0000 (7 00:08 +0000)]
MFC rev 1.4: fix a bug in hexadecimal formatting of the CHAP digest:
bytes >= 0x80 were formatted as 0xff, causing the authentication
to fail.

Note: fast MFC to RELENG_7 and RELENG_7_0 to get the changes in
time for 7.0-RC2.

Approved by: re (kensmith)

14 years agoRemove rr232x(4) from release documentations. It is actually
Xin LI [Wed, 6 Feb 2008 19:47:29 +0000 (6 19:47 +0000)]
Remove rr232x(4) from release documentations.  It is actually
a hard link from hptrr(4).

Approved by: re (bmah)

14 years agoMFC: file version 4.23.
David E. O'Brien [Wed, 6 Feb 2008 18:26:38 +0000 (6 18:26 +0000)]
MFC: file version 4.23.
Approved by: re(kensmith)

14 years agoFix a symbol conflict between hptrr and hptmv
Scott Long [Wed, 6 Feb 2008 13:59:17 +0000 (6 13:59 +0000)]
Fix a  symbol conflict between hptrr and hptmv

Approved by: re

14 years agoUpdate the hptrr driver to version 1.2. This adds port multiplier support
Scott Long [Wed, 6 Feb 2008 04:37:58 +0000 (6 04:37 +0000)]
Update the hptrr driver to version 1.2.  This adds port multiplier support
for several cards.  See the Highpoint website for more information.  Again,
many thanks to Highpoint for their continued support of FreeBSD.

Approved by: re

14 years agoUpdate the hptiop driver to version 1.3. This adds support for the 4xxx
Scott Long [Wed, 6 Feb 2008 03:44:11 +0000 (6 03:44 +0000)]
Update the hptiop driver to version 1.3.  This adds support for the 4xxx
series of adapters.  Thanks again to Highpoint for their continued support
of FreeBSD.

Submitted by: Highpoint Technologies
Approved by: re

14 years agoMFC revision: 1.83, 1.85, 1.86
Mitsuru IWASAKI [Wed, 6 Feb 2008 03:39:02 +0000 (6 03:39 +0000)]
MFC revision:   1.83, 1.85, 1.86

Add NOP-message polling to ciss_periodic().
Disable adapter by detecting adapter is dead.

Reviewed by:    scottl
Approved by:    re (kensmith)

14 years agoRemove the rr232x.4 manual page and add links and references to the hptrr
Scott Long [Wed, 6 Feb 2008 03:38:47 +0000 (6 03:38 +0000)]
Remove the rr232x.4 manual page and add links and references to the hptrr
page.

Approved by: re

14 years agoMFC revision: subr_bus.c:1.204, bus.h:1.79, acpi.c:1.244
Mitsuru IWASAKI [Wed, 6 Feb 2008 03:35:40 +0000 (6 03:35 +0000)]
MFC revision: subr_bus.c:1.204,  bus.h:1.79, acpi.c:1.244

o Add devctl_process_running() so that power management system driver
  can check whether devd(8) is running.
o Enter the sleep state immediately without waiting for timeout if
  devd(8) is not running such as the system in single user mode.

Approved by: re (kensmith)

14 years agoRemove the rr232x driver. It has been superseced by the hptrr driver.
Scott Long [Wed, 6 Feb 2008 03:24:29 +0000 (6 03:24 +0000)]
Remove the rr232x driver.  It has been superseced by the hptrr driver.

Approved by: re

14 years agoMFC 1.2:
Simon L. B. Nielsen [Tue, 5 Feb 2008 21:02:04 +0000 (5 21:02 +0000)]
MFC 1.2:
  Unbreak detection of cryptodev support for FreeBSD which was broken
  with OpenSSL 0.9.8 import.

  Note that this does not enable cryptodev by default, as it was the
  case with OpenSSL 0.9.7 in FreeBSD base, but this change makes it
  possible to enable cryptodev at all.

Approved by: re (kensmith)

14 years agoMFC 1.115: fix use w/ altq
Sam Leffler [Tue, 5 Feb 2008 18:29:03 +0000 (5 18:29 +0000)]
MFC 1.115: fix use w/ altq

Submitted by: sephe
Approved by: re (kensmith)

14 years agoMFC 1.8: correct typo that broke check when handling addba response
Sam Leffler [Tue, 5 Feb 2008 18:19:12 +0000 (5 18:19 +0000)]
MFC 1.8: correct typo that broke check when handling addba response

Approved by: re (kensmith)

14 years agoMFC 1.50: correct tx rate displayed by list sta
Sam Leffler [Tue, 5 Feb 2008 18:17:29 +0000 (5 18:17 +0000)]
MFC 1.50: correct tx rate displayed by list sta

Approved by: re (kensmith)

14 years agoMFC 1.49: fix list mac
Sam Leffler [Tue, 5 Feb 2008 18:16:35 +0000 (5 18:16 +0000)]
MFC 1.49: fix list mac

Approved by: re (kensmith)

14 years agoMFC revision 1.23
Christian S.J. Peron [Tue, 5 Feb 2008 14:36:41 +0000 (5 14:36 +0000)]
MFC revision 1.23
Make sure we handle listen() and eliminate console messages for unknown
event types.

Approved by: re@ (kensmith)

14 years agoMFC changes from 1.14 for sys/lock.c and 1.127+1.128 for thread/thr_kern.c
Julian Elischer [Mon, 4 Feb 2008 20:03:36 +0000 (4 20:03 +0000)]
MFC changes from 1.14 for sys/lock.c and 1.127+1.128 for thread/thr_kern.c
this copes with the fact that during a fork the child may get
really screwy state in the threading system due to the
sudden vaporisation of it's sibling threads.

Approved by: re(kensmith)

14 years agoMFC: Fix some bugs in dealing with DCMD's without data. MegaCli was sending
Doug Ambrisko [Mon, 4 Feb 2008 14:54:21 +0000 (4 14:54 +0000)]
MFC: Fix some bugs in dealing with DCMD's without data.  MegaCli was sending
down some DCMD's without any data.  Thanks to Dell and LSI for helping
to provide clues to figure out this problem.  Now MegaCli can upgrade
the firmware and should work identical when run on Linux.

Approved by: re (kensmith)

14 years agoMerge uipc_sockbuf.c:1.175, uipc_socket.c:1.304, uipc_syscalls.c:1.264,
Robert Watson [Sat, 2 Feb 2008 12:44:14 +0000 (2 12:44 +0000)]
Merge uipc_sockbuf.c:1.175, uipc_socket.c:1.304, uipc_syscalls.c:1.264,
sctp_input.c:1.67, sctp_peeloff.c:1.17, sctputil.c:1.73,
socketvar.h:1.161 from HEAD to RELENG_7_0:

  Correct two problems relating to sorflush(), which is called to flush
  read socket buffers in shutdown() and close():

  - Call socantrcvmore() before sblock() to dislodge any threads that
    might be sleeping (potentially indefinitely) while holding sblock(),
    such as a thread blocked in recv().

  - Flag the sblock() call as non-interruptible so that a signal
    delivered to the thread calling sorflush() doesn't cause sblock() to
    fail.  The sblock() is required to ensure that all other socket
    consumer threads have, in fact, left, and do not enter, the socket
    buffer until we're done flushin it.

  To implement the latter, change the 'flags' argument to sblock() to
  accept two flags, SBL_WAIT and SBL_NOINTR, rather than one M_WAITOK
  flag.  When SBL_NOINTR is set, it forces a non-interruptible sx
  acquisition, regardless of the setting of the disposition of SB_NOINTR
  on the socket buffer; without this change it would be possible for
  another thread to clear SB_NOINTR between when the socket buffer mutex
  is released and sblock() is invoked.

  Reviewed by:    bz, kmacy, rrs
  Reported by:    Jos Backus <jos at catnook dot com>

Approved by: re (kensmith)

14 years agoMFC 1.7: use m_gethdr to populate the rx ring
Sam Leffler [Sat, 2 Feb 2008 07:30:02 +0000 (2 07:30 +0000)]
MFC 1.7: use m_gethdr to populate the rx ring

Approved by: re (kensmith)

14 years agoMFC: 1.159, 1.160
Jung-uk Kim [Fri, 1 Feb 2008 20:33:40 +0000 (1 20:33 +0000)]
MFC: 1.159, 1.160

Do not sanitize disk geometry if it is set by scripts in non-interactive mode.

Approved by: re (kensmith)

14 years ago - Fixes is a bug in sctp_auth that will cause a panic if
Randall Stewart [Thu, 31 Jan 2008 17:21:50 +0000 (31 17:21 +0000)]
  - Fixes is a bug in sctp_auth that will cause a panic if
    a socket is closed as it gets auth'd data in. (sctp_auth.c)
  - Reverts the priority back to 0, do not change prioritys (sctp_bsd_addr.c)
  - Fixes a wrap error in calculation of gap ack segments that
    wrap the TSN number. (sctp_indata.c)
  - Fixes a comment, and also moves a lock up to cover the pulling
    of the VRF from the inp structure. (sctp_pcb.c)
Approved by: re@freebsd.org (Ken Smith)

14 years agoMFC: rev. 1.194
Christian Brueffer [Thu, 31 Jan 2008 14:19:06 +0000 (31 14:19 +0000)]
MFC: rev. 1.194

Correct the kernel config hint in a printf statement.

Approved by: re (kensmith), rwatson (mentor)

14 years agoMFC rev. 1.27
Alexander Motin [Wed, 30 Jan 2008 21:29:10 +0000 (30 21:29 +0000)]
MFC rev. 1.27
Fix memory leak when export hook is not connected.

Approved by: re (kensmith)

14 years agoMFC: Add a wrapper function that bound checks writes to the dump device.
Ruslan Ermilov [Wed, 30 Jan 2008 21:21:51 +0000 (30 21:21 +0000)]
MFC: Add a wrapper function that bound checks writes to the dump device.

Approved by: re (kensmith)

14 years agoMFC:
Christian Brueffer [Wed, 30 Jan 2008 18:13:53 +0000 (30 18:13 +0000)]
MFC:

Remove references to the obsolete card(4) manpage.

Approved by: re (bmah)

14 years agoMFC:
Christian Brueffer [Wed, 30 Jan 2008 18:12:35 +0000 (30 18:12 +0000)]
MFC:

OLDCARD is long gone, so finally remove the oldcard.4 manpage.

Approved by: re (bmah)

14 years agoMFC: rev. 1.1.1.7 (Check for a failure return from cplus_demangle_type)
David E. O'Brien [Tue, 29 Jan 2008 18:13:53 +0000 (29 18:13 +0000)]
MFC: rev. 1.1.1.7 (Check for a failure return from cplus_demangle_type)

Approved by: re(kensmith)

14 years agoMFC 1.42,1.43: Fix races and other bugs with sleepq timeout handling.
John Baldwin [Tue, 29 Jan 2008 16:37:04 +0000 (29 16:37 +0000)]
MFC 1.42,1.43: Fix races and other bugs with sleepq timeout handling.

Approved by: re (kensmith)

14 years agoMFC: ver. 1.7
Mike Makonnen [Tue, 29 Jan 2008 07:15:46 +0000 (29 07:15 +0000)]
MFC: ver. 1.7
Partial backout of rev. 1.6, but instead of putting
kerberos5_server_flags back in command_args, put it
where rc.subr(8) expects it: kerberos5_flags.

Approved by: re (kensmith)

14 years agoMFC v1.7 (by request from remko because he is injured)
Ken Smith [Tue, 29 Jan 2008 01:39:16 +0000 (29 01:39 +0000)]
MFC v1.7 (by request from remko because he is injured)
> revision 1.7
> date: 2008/01/16 13:54:40;  author: remko;  state: Exp;  lines: +9 -6
> Dont accidentally remove a filesocket which is still in use. This gives
> problems when the DRM driver is loaded and the AIXGL extension is loaded
> , the AIXGL driver requests a drm_close and this will cause the radeon
> driver to fail while starting X windows.
>
> PR:             kern/114688
> Submitted by:   vehemens <vehemens at verizon dot net>
> Prodded by:     Robert Noland
> Approved by:    imp (mentor, a while ago already), anholt

Approved by: re (kensmith)
Me doing MFC requested by: remko

14 years agoMFC functional changes to etc:
Doug Barton [Tue, 29 Jan 2008 00:22:33 +0000 (29 00:22 +0000)]
MFC functional changes to etc:
1. yar's "dry run" patch to Makefile
2. Add zfs to the list of filesystems to check in
periodic/security/100.chksetuid
3. GC the nfslocking script, which has been superseded by lockd and statd
4. Add security warning to rc.d/jail
5. Add stop_cmd=':' to those rc.d scripts that do not start services,
but did not already have a stop_cmd.

And update comments in rc.firewall* and defaults/rc.conf.

Approved by: re (kensmith)

14 years agoMFC:
Mike Makonnen [Mon, 28 Jan 2008 20:59:48 +0000 (28 20:59 +0000)]
MFC:
Rev. 1.6 made it impossible to use rc.d/kerberos with the krb5 port.
Re-implement the change so that the script once again works with
the krb5 port.

Submitted by: kensmith (slightly modified)

Approved by: re (kensmith)

14 years agoMerge ipfw2.c:1.113, ip_fw.h:1.111, ip_fw2.c:1.180 from HEAD to
Robert Watson [Mon, 28 Jan 2008 17:44:30 +0000 (28 17:44 +0000)]
Merge ipfw2.c:1.113, ip_fw.h:1.111, ip_fw2.c:1.180 from HEAD to
RELENG_7_0:

  Hide ipfw internal data structures behind IPFW_INTERNAL rather than
  exposing them to all consumers of ip_fw.h.  These structures are
  used in both ipfw(8) and ipfw(4), but not part of the user<->kernel
  interface for other applications to use, rather, shared
  implementation.

  Reported by:    Paul Vixie <paul at vix dot com>

Approved by: re (kensmith)

14 years agoMFC: Only reset driver state when a hardware error is detected.
Andrew Gallatin [Mon, 28 Jan 2008 15:58:03 +0000 (28 15:58 +0000)]
MFC: Only reset driver state when a hardware error is detected.

Approved by: re (kensmith)

14 years agoMFC rev. 1.52:
Konstantin Belousov [Mon, 28 Jan 2008 12:51:31 +0000 (28 12:51 +0000)]
MFC rev. 1.52:
udf_vget() shall vgone() the vnode when the file_entry cannot be allocated
or read from the volume. Otherwise, half-constructed vnode could be found
later and cause panic when accessed.

Approved by: re (kensmith)

14 years agoMFC rev. 1.457:
Konstantin Belousov [Mon, 28 Jan 2008 12:49:33 +0000 (28 12:49 +0000)]
MFC rev. 1.457:
Do not dereference NULL scp in the case the screen is not opened.
Instead, return ENXIO to the ioctl caller.

Approved by: re (kensmith)

14 years agoMFC rev. 1.157:
Konstantin Belousov [Mon, 28 Jan 2008 12:47:56 +0000 (28 12:47 +0000)]
MFC rev. 1.157:
In rev. 1.156, the convertion of the minor number to the unit number
resulted in the argument to the make_dev() to be a unit number.

Correct this by supplying a minor number to make_dev(), and using
the unit number for the calculation of the slave tty name.

Approved by: re (kensmith)

14 years agoMFC:
Jean-Sébastien Pédron [Mon, 28 Jan 2008 10:43:11 +0000 (28 10:43 +0000)]
MFC:
  sys/kern/vfs_aio.c; revision 1.237
  sys/sys/event.h; revision 1.38

  When asked to use kqueue, AIO stores its internal state in the
  `kn_sdata' member of the newly registered knote. The problem is that
  this member is overwritten by a call to kevent(2) with the EV_ADD flag,
  targetted at the same kevent/knote. For instance, a userland application
  may set the pointer to NULL, leading to a panic.

  A testcase was provided by the submitter.

  PR: kern/118911
  Submitted by: MOROHOSHI Akihiko <moro@remus.dti.ne.jp>

Approved by: re (kensmith)

14 years agoRegenerated page with WITHOUT_GSSAPI
Doug Barton [Mon, 28 Jan 2008 09:00:43 +0000 (28 09:00 +0000)]
Regenerated page with WITHOUT_GSSAPI

Approved by: re (kensmith)

14 years agoMFC the WITHOUT_GSSAPI knob.
Doug Barton [Mon, 28 Jan 2008 08:57:11 +0000 (28 08:57 +0000)]
MFC the WITHOUT_GSSAPI knob.

Approved by: re (kensmith)

14 years agoMFC the purely cosmetic changes, including removal of $NetBSD$ Ids,
Doug Barton [Mon, 28 Jan 2008 07:58:32 +0000 (28 07:58 +0000)]
MFC the purely cosmetic changes, including removal of $NetBSD$ Ids,
a few spurious #'s, an empty REQUIRE, and a never-used KEYWORD.

Approved by: re (kensmith)

14 years agoGC this file, which was brought over from NetBSD but never used by us.
Doug Barton [Mon, 28 Jan 2008 07:32:25 +0000 (28 07:32 +0000)]
GC this file, which was brought over from NetBSD but never used by us.

Approved by: re (kensmith)

14 years agoMFC: 1.36
Marius Strobl [Sun, 27 Jan 2008 15:44:37 +0000 (27 15:44 +0000)]
MFC: 1.36

Add missing locking for SBus controllers.

Approved by: re (kensmith)

14 years agoMFC revision 1.7
Xin LI [Sat, 26 Jan 2008 22:13:30 +0000 (26 22:13 +0000)]
MFC revision 1.7
date: 2008/01/12 00:11:26;  author: delphij;  state: Exp;  lines: +4 -4
 - Handle the case where interface from "middle" is missing by
   more carefully inspecting the return value from sysctl(3). [1]
 - Use calloc instead of malloc+memset of zero.

Submitted by: Alexander Chernikov <admin su29 net> [1]
PR: bin/119581
Approved by: re (kensmith)

14 years agoMFC rev 1.71
Alexander Motin [Sat, 26 Jan 2008 14:14:10 +0000 (26 14:14 +0000)]
MFC rev 1.71
Fix bundle xmit octets stats for packet-split operation mode.

Approved by: re (kensmith)

14 years agoMerge tcp_usrreq.c:1.167 from HEAD to RELENG_7_0:
Robert Watson [Sat, 26 Jan 2008 13:57:33 +0000 (26 13:57 +0000)]
Merge tcp_usrreq.c:1.167 from HEAD to RELENG_7_0:

  tcp_usrreq.c:1.130 removed tcbinfo locking from tcp_usr_accept(), which
  while in principle a good idea, opened us up to a race inherrent to
  the syncache's direct insertion of incoming TCP connections into the
  "completed connection" listen queue, as it transpires that the socket
  is inserted before the inpcb is fully filled in by syncache_expand().
  The bug manifested with the occasional returning of 0.0.0.0:0 in the
  address returned by the accept() system call, which occurred if accept
  managed to execute tcp_usr_accept() before syncache_expand() had copied
  the endpoint addresses into inpcb connection state.

  Re-add tcbinfo locking around the address copyout, which has the effect
  of delaying the copy until syncache_expand() has finished running, as
  it is run while the tcbinfo lock is held.  This is undesirable in that
  it increases contention on tcbinfo further, but a more significant
  change will be required to how the syncache inserts new sockets in
  order to fix this and keep more granular locking here.  In particular,
  either more state needs to be passed into sonewconn() so that
  pru_attach() can fill in the fields *before* the socket is inserted, or
  the socket needs to be inserted in the incomplete connection queue
  until it is actually ready to be used.

  Reported by:    glebius (and kris)
  Tested by:      glebius

Approved by: re (kensmith)

14 years agoMFC: 1.430
Marcus Alves Grando [Fri, 25 Jan 2008 10:54:40 +0000 (25 10:54 +0000)]
MFC: 1.430

  - Add new NTP servers provided by NIC.br (http://www.ntp.br)
  - Remove nonfunctional servers

  PR:             119884
  Approved by:    simon

Approved by: re (bmah)

14 years ago- Add geom_virstor to the module build.
Ulf Lilleengen [Thu, 24 Jan 2008 20:28:27 +0000 (24 20:28 +0000)]
- Add geom_virstor to the module build.

PR: kern/119902
Submitted by: Yoshihiro Ota <ota -at- j.email.ne.jp>
Approved by: re (kensmith), pjd (mentor)

14 years agoMFC: Don't cache the new-bus name of a PCI device in the PCI conf
John Baldwin [Thu, 24 Jan 2008 18:53:29 +0000 (24 18:53 +0000)]
MFC: Don't cache the new-bus name of a PCI device in the PCI conf
structure.

Approved by: re (kensmith)

14 years agoMFC: Fix some minor issues such as using read/modify/write for updating
John Baldwin [Thu, 24 Jan 2008 18:52:26 +0000 (24 18:52 +0000)]
MFC: Fix some minor issues such as using read/modify/write for updating
the configuration register and add a header file to hold HPET register
constants.

Approved by: re (kensmith)

14 years agoMFC: rev. 1.65
Christian Brueffer [Thu, 24 Jan 2008 07:11:29 +0000 (24 07:11 +0000)]
MFC: rev. 1.65

Document the 'maintainer' target.

Approved by: re (kensmith)

14 years agoMFen 1.1068.2.20.2.2
Xin LI [Wed, 23 Jan 2008 20:37:44 +0000 (23 20:37 +0000)]
MFen 1.1068.2.20.2.2

Approved by: re (kensmith)

14 years agoMFC:
Ken Smith [Wed, 23 Jan 2008 20:22:48 +0000 (23 20:22 +0000)]
MFC:
Add fsck_4.2bsd and fsck_ufs as hard links to fsck_ffs in /stand on
the MFS image so that (for example) "fsck /dev/ad0s1a" will work.
Without this you needed (for example) "fsck -t ffs /dev/ad0s1a" (or
needed to run fsck_ffs instead of fsck).

Versions being MFCed:

        1.62    src/release/amd64/boot_crunch.conf
        1.62    src/release/i386/boot_crunch.conf
        1.12    src/release/ia64/boot_crunch.conf
        1.63    src/release/pc98/boot_crunch.conf
        1.5     src/release/powerpc/boot_crunch.conf
        1.9     src/release/sparc64/boot_crunch.conf
        1.2     src/release/sun4v/boot_crunch.conf

Approved by: re (bmah)

14 years agoMFC v1.12:
Ken Smith [Wed, 23 Jan 2008 20:06:27 +0000 (23 20:06 +0000)]
MFC v1.12:
Update EDITOR and PAGER environment variables so they are correct for
the CDROM fixit environment.

Noticed by:     gallatin
Approved by: re (bmah)

14 years agoMerge revisions 1.1 and 1.2 of the coda.4 man page from HEAD to RELENG_7_0:
Robert Watson [Wed, 23 Jan 2008 12:22:11 +0000 (23 12:22 +0000)]
Merge revisions 1.1 and 1.2 of the coda.4 man page from HEAD to RELENG_7_0:

  Add a rather basic man page for the coda kernel module.

  Small fixes.

Approved by: re (kensmith)

14 years agoMerge a variety of Coda fixes from HEAD to RELENG_7_0:
Robert Watson [Wed, 23 Jan 2008 12:09:43 +0000 (23 12:09 +0000)]
Merge a variety of Coda fixes from HEAD to RELENG_7_0:

coda_vnops.c:1.79:

  Borrow the VM object associated with an underlying cache vnode with the
  Coda vnode derived from it, in the style of nullfs.  This allows files
  in the Coda file system to be memory-mapped, such as with execve(2) or
  mmap(2).

  Reported by:    Rune <u+openafsdev-sr55 at chalmers dot se>

coda_vnops.c:1.80:

  Lock the new directory vnode returned by coda_mkdir(), as this is required
  by FreeBSD's vnode locking protocol.

coda_vnops.c:1.81:

  Use VOP_NULL rather than VOP_PANIC for Coda's vop_print routine, so as
  to avoid panicking in DDB show lockedvnods.

cnode.h:1.22, coda_namecache.h:1.12, coda_psdev.c:1.40, coda_vfsops.c:1.70:

  Don't declare functions as extern.

  Move all extern variable definitions to associated .h files, move some
  extern variable definitions between include files to place them more
  appropriately.

coda_vnops.c:1.82:

  Don't acquire an additional vnode reference to a vnode when it is opened
  and then release it when it is closed: we rely on the caller to keep the
  vnode around with a valid reference.  This avoids vrele() destroying the
  vnode vop_close() is being called from during a call to vop_close(), and
  a crash due to lockmgr recursing the vnode lock when a Coda unmount
  occurs.

coda_vfsops.c:1.71:

  Zero mi_rotovp and coda_ctlvp immediately after calling vrele() on the
  vnodes during coda_unmount() in order to detect errant use of them
  after the vnode references may no longer be valid.

  No need to clear the VV_ROOT flag on mi_rootvp flag (especially after
  the vnode reference is no longer valid) as this isn't done on other
  file systems.

coda_vfsops.c:

  Rework coda_statfs(): no longer need to zero the statfs structure or
  fill out all fields, just fill out the ones the file system knows
  about.  Among other things, this causes the outpuf of "mount" and
  "df" to make quite a bit more sense as /dev/cfs0 is specified as the
  mountfrom name.

coda_vnops.c:1.83:

  Improve default vnode operation handling for Coda:

  - Don't specify vnode operations for mknod, lease, and advlock--let them
    fall through to vop_default.

  - Implement vop_default with &default_vnodeops, rather than with
    VOP_PANIC, so that unimplemented vnode operations are handled in more
    sensible ways than panicking, such as EOPNOTSUPP on ACL queries
    generated by bsdtar, or mknod.

coda_namecache.h:1.13:

  Remove unused oldhash definition from Coda namecache.

coda_vnops.c:1.84:

  Replace references to VOP_LOCK() w/o LK_RETRY to vn_lock() with LK_RETRY,
  avoiding extra error handling, or in some cases, missing error handling.

  Discussed with: kib

coda_vnops.c:1.85:

  Put "coda_rdwr: Internally Opening" printf generated by in-kernel writes
  to files, such as ktrace output, under CODA_VERBOSE.  Otherwise, each
  such call to VOP_WRITE() results in a kernel printf.

  Obtained from:  NetBSD

Approved by: re (kensmith)

14 years agoMerge uipc_usrreq.c:1.214 from HEAD to RELENG_7_0:
Robert Watson [Wed, 23 Jan 2008 12:08:12 +0000 (23 12:08 +0000)]
Merge uipc_usrreq.c:1.214 from HEAD to RELENG_7_0:

  Move unlock of global UNIX domain socket lock slightly lower in
  unp_connect(): it is expected to return with the lock held, and two
  possible error paths otherwise returned with it unlocked.

  The fix committed here is slightly different from the patch in the
  PR, but along an alternative line suggested in the PR.

  PR:             119778
  Submitted by:   James Juran <james dot juran at baesystems dot com>

Approved by: re (gnn)

14 years agoMFC: 1.26
Jung-uk Kim [Wed, 23 Jan 2008 00:15:22 +0000 (23 00:15 +0000)]
MFC: 1.26

Check battery presence first before trying to get battery information.

Approved by: re (kensmith)

14 years agoNew release notes: SA-08:01, SA-08:02. Bump copyright date.
Bruce A. Mah [Tue, 22 Jan 2008 23:05:26 +0000 (22 23:05 +0000)]
New release notes:  SA-08:01, SA-08:02.  Bump copyright date.

Approved by: re (implicitly)

14 years agoMFC: 1.201
Jung-uk Kim [Tue, 22 Jan 2008 17:30:13 +0000 (22 17:30 +0000)]
MFC: 1.201

Fix mbuf pool watermark configuration.

Approved by: re (kensmith)

14 years agoThis commit was manufactured by cvs2svn to create branch 'RELENG_7_0'.
cvs2svn [Tue, 22 Jan 2008 07:40:23 +0000 (22 07:40 +0000)]
This commit was manufactured by cvs2svn to create branch 'RELENG_7_0'.

14 years agoMFC: rev. 1.12
Christian Brueffer [Mon, 21 Jan 2008 22:02:21 +0000 (21 22:02 +0000)]
MFC: rev. 1.12

Remove files conditional on the obsolete MK_FORTRAN knob.  They are already
listed in ObsoleteFiles.inc anyway.

Approved by: re (kensmith), rwatson (mentor)

14 years agoMFC: rev. 1.72
Christian Brueffer [Mon, 21 Jan 2008 22:00:25 +0000 (21 22:00 +0000)]
MFC: rev. 1.72

Remove remnants of old *_FORTRAN build flags.

Approved by: re (kensmith), rwatson (mentor)

14 years agoMFC: rev. 1.592
Christian Brueffer [Mon, 21 Jan 2008 21:58:55 +0000 (21 21:58 +0000)]
MFC: rev. 1.592

Remove WITHOUT_FORTRAN from the XMAKE target, it doesn't exist anymore.

Approved by: re (kensmith), rwatson (mentor)

14 years agoMFC:
Christian Brueffer [Mon, 21 Jan 2008 21:56:02 +0000 (21 21:56 +0000)]
MFC:

WITHOUT_FORTRAN was removed some time ago.  Regen src.conf.5.

Approved by: re (kensmith), rwatson (mentor)

14 years agoMFC rev. 1.156:
Konstantin Belousov [Mon, 21 Jan 2008 12:57:18 +0000 (21 12:57 +0000)]
MFC rev. 1.156:
In the rev. 1.153, the one place for converting minor number to unit
was missed. As result, pty_create_slave() may index out of the names[]
bounds, creating wrong slave tty names.

Approved by: re (kensmith)

14 years agoMFC: 1.270
Craig Rodrigues [Sun, 20 Jan 2008 02:38:42 +0000 (20 02:38 +0000)]
MFC: 1.270
 - In vfs_scanopt(), make sure that the mount option value is not NULL
   before calling vsscanf().

PR:             118531

MFC: 1.268
  - Internally convert "rdonly" mount option to "ro".

Approved by:    re (kensmith)

14 years agoMFC 1.28,1.29: reject cpufreq changes before sched_bind() is usable and
Nate Lawson [Sat, 19 Jan 2008 20:31:00 +0000 (19 20:31 +0000)]
MFC 1.28,1.29: reject cpufreq changes before sched_bind() is usable and
remove duplicated levels.

Approved by: re

14 years agoMFC fix for the panic("vm_thread_new: kstack allocation failed") and
Konstantin Belousov [Sat, 19 Jan 2008 18:15:07 +0000 (19 18:15 +0000)]
MFC fix for the panic("vm_thread_new: kstack allocation failed") and
silent NULL pointer dereference in the i386 and sparc64 pmap_pinit()
when the kmem_alloc_nofault() failed to allocate address space. Both
functions now return error instead of panicing or dereferencing NULL.

The reason for MFCing this so late in release cycle is, according to
marius@, because
> it fixes the crashing (though no panic) of the test suite
> of the graphic/OpenEXR port on sparc64. This test suite is run
> (and required to succeed) during the package build and that's
> why portmgr@ bitch about at it as OpenEXR is a dependency of KDE
> which in turn is supposed to end up on the release CD images.

Revisions MFCed:
  1.677     of      src/sys/amd64/amd64/machdep.c
  1.592     of      src/sys/amd64/amd64/pmap.c
  1.88      of      src/sys/arm/arm/pmap.c
  1.27      of      src/sys/arm/at91/kb920x_machdep.c
  1.22      of      src/sys/arm/sa11x0/assabet_machdep.c
  1.8       of      src/sys/arm/xscale/i80321/ep80219_machdep.c
  1.29      of      src/sys/arm/xscale/i80321/iq31244_machdep.c
  1.3       of      src/sys/arm/xscale/i8134x/crb_machdep.c
  1.6       of      src/sys/arm/xscale/ixp425/avila_machdep.c
  1.41      of      src/sys/compat/pecoff/imgact_pecoff.c
  1.26      of      src/sys/compat/svr4/imgact_svr4.c
  1.660     of      src/sys/i386/i386/machdep.c
  1.596     of      src/sys/i386/i386/pmap.c
  1.68      of      src/sys/i386/ibcs2/imgact_coff.c
  1.56      of      src/sys/i386/linux/imgact_linux.c
  1.226     of      src/sys/ia64/ia64/machdep.c
  1.192     of      src/sys/ia64/ia64/pmap.c
  1.102     of      src/sys/kern/imgact_aout.c
  1.179     of      src/sys/kern/imgact_elf.c
  1.56      of      src/sys/kern/imgact_gzip.c
  1.310     of      src/sys/kern/kern_exec.c
  1.287     of      src/sys/kern/kern_fork.c
  1.236     of      src/sys/kern/kern_kse.c
  1.253     of      src/sys/kern/kern_proc.c
  1.352     of      src/sys/kern/kern_sig.c
  1.63      of      src/sys/kern/kern_thr.c
  1.257     of      src/sys/kern/kern_thread.c
  1.397     of      src/sys/pc98/pc98/machdep.c
  1.104     of      src/sys/powerpc/powerpc/machdep.c
  1.10      of      src/sys/powerpc/powerpc/pmap_dispatch.c
  1.139     of      src/sys/sparc64/sparc64/machdep.c
  1.167     of      src/sys/sparc64/sparc64/pmap.c
  1.16      of      src/sys/sun4v/sun4v/machdep.c
  1.40      of      src/sys/sun4v/sun4v/pmap.c
  1.493     of      src/sys/sys/proc.h
  1.78      of      src/sys/sys/signalvar.h
  1.80      of      src/sys/vm/pmap.h
  1.79      of      src/sys/vm/vm_extern.h
  1.226     of      src/sys/vm/vm_glue.c
  1.390     of       src/sys/vm/vm_map.c

Requested by: marius
Tested by: Peter Holm, marius (make universe and sparc64 runs)
Approved by: re (kensmith)

14 years agoMFC rev. 1.52:
Konstantin Belousov [Sat, 19 Jan 2008 18:12:25 +0000 (19 18:12 +0000)]
MFC rev. 1.52:
The ffs_balloc() routines, whan allocating the indirect blocks for
the inode, do the rollback in case the allocation failed (due to
insufficient free space or quota limits). But, the code does leaves the
buffers corresponding to the inoirect blocks on the vnode bufobj list.
This causes several assertion failures (for instance, "ffs_truncate3"
in ffs_truncate()) to fail, and could result in the indirect block
aliasing problem, like writing the context of such blocks to random
disk location.

Remove the buffers from the bufobj properly.

MFC rev. 1.53:
ffs_balloc_ufsX() routines, in the case of recovering from the failed
allocation, free the indirect blocks before clearing the disk pointers,
that could lead to the softupdate inconsistencies in the case of the
machine or disk crash at the wrong time.

Rearrange the recover code to do the ffs_blkfree() after the second
ffs_syncvnode(), that clears the pointers chain.

Approved by: re (kensmith)

14 years agoThis commit was manufactured by cvs2svn to create branch 'RELENG_7_0'.
cvs2svn [Fri, 18 Jan 2008 05:06:00 +0000 (18 05:06 +0000)]
This commit was manufactured by cvs2svn to create branch 'RELENG_7_0'.

14 years agoMerge uipc_sem.c:1.30 from RELENG_7 to RELENG_7_0:
Robert Watson [Thu, 17 Jan 2008 19:52:01 +0000 (17 19:52 +0000)]
Merge uipc_sem.c:1.30 from RELENG_7 to RELENG_7_0:

  Free MAC label on a POSIX semaphore when the semaphore is freed.

  Submitted by:   jhb

Approved by: re (kensmith)

14 years agoMFC: sys/contrib/opensolaris/uts/common/fs/zfs/zvol.c 1.4
Pawel Jakub Dawidek [Thu, 17 Jan 2008 14:59:26 +0000 (17 14:59 +0000)]
MFC: sys/contrib/opensolaris/uts/common/fs/zfs/zvol.c 1.4

Call zil_commit() (if ZIL is not disabled) after every non-read request
(BIO_WRITE and BIO_FLUSH) as it is done is Solaris. The difference is
that Solaris calls it only for sync requests, but we can't say in GEOM
if the request is sync or async, so we do it for every request.

Approved by: re (gnn)

14 years agoMFC: sys/contrib/opensolaris/uts/common/fs/zfs/vdev.c 1.4
Pawel Jakub Dawidek [Thu, 17 Jan 2008 14:58:49 +0000 (17 14:58 +0000)]
MFC: sys/contrib/opensolaris/uts/common/fs/zfs/vdev.c 1.4

Close access to vdev when setting state to anything but open state.
This fixes replacing drive in place, eg. zpool replace tank da1 da1.
Before the fix, it complained that device is already open.

Obtained from: OpenSolaris
Approved by: re (gnn)

14 years agoMFC: sys/vm/vm_kern.c 1.131
Pawel Jakub Dawidek [Thu, 17 Jan 2008 14:57:50 +0000 (17 14:57 +0000)]
MFC: sys/vm/vm_kern.c 1.131

When one tries to allocate memory with the M_WAITOK flag and we are short in
address space in kmem map call vm_lowmem event in a loop and wait a bit for
subsystems to reclaim some memory which in turn will reclaim address space as
well.

Note, this is a work-around.

Reviewed by: alc
Approved by: alc
Approved by: re (gnn)

14 years agoMFC rev 1.14:
Olivier Houchard [Wed, 16 Jan 2008 22:45:03 +0000 (16 22:45 +0000)]
MFC rev 1.14:
Back when I committed the arm port, I've been asked to move
memcpy/memset/memcmp and friends from libkern/arm to arm/arm/support.S, and so
I did, but in the process, I didn't add the appropriate copyrights.
This is a major oversight from me, and I apology to the NetBSD people for it.

Approved by: re (mux)