dragonfly.git
12 years agosh: Fix execution of multiple statements in a trap when evalskip is set
Peter Avalos [Sun, 5 Feb 2012 20:07:56 +0000 (12:07 -0800)]
sh: Fix execution of multiple statements in a trap when evalskip is set

Before this fix, only the first statement of the trap was executed if
evalskip was set. This is for example the case when:
    o  "-e" is set for this shell
    o  a trap is set on EXIT
    o  a function returns 1 and causes the script to abort

Obtained-from:  FreeBSD 230212
(cherry picked from commit a1cf61ab1fd76b3e90e17fc4bc03767015deb2e1)

12 years agosh: Fix some bugs with exit status from case containing ;&.
Peter Avalos [Sun, 5 Feb 2012 20:04:53 +0000 (12:04 -0800)]
sh: Fix some bugs with exit status from case containing ;&.

Also, rework evalcase() to not evaluate any tree. Instead, return the
NCLISTFALLTHRU node and handle it in evaltree().

Fixed bugs:

* If a ;& list with non-zero exit status is followed by an empty ;; or final
  list, the exit status of the case command should be equal to the exit
  status of the ;& list, not 0.

* An empty ;& case should not reset $?.

Obtained-from:  FreeBSD 230161
(cherry picked from commit b88d2fafe2e2a6d776e70cb6d6cca1533087b699)

12 years agosh: Fix two bugs with case and exit status:
Peter Avalos [Sun, 5 Feb 2012 20:02:44 +0000 (12:02 -0800)]
sh: Fix two bugs with case and exit status:

* If no pattern is matched, POSIX says the exit status shall be 0 (even if
  there are command substitutions).
* If a pattern is matched and there are no command substitutions, the first
  command should see the $? from before the case command, not always 0.

Obtained-from:  FreeBSD 230154
(cherry picked from commit c79cd3b3a40bbcea12f869fee83c021fc6c8bf90)

12 years agosh: Change input buffer size from 1023 to 1024.
Peter Avalos [Sun, 5 Feb 2012 20:00:29 +0000 (12:00 -0800)]
sh: Change input buffer size from 1023 to 1024.

Apparently this improves performance on slower platforms.

Obtained-from:  FreeBSD 230118
(cherry picked from commit 43cdc26c9fc6fb1e385f2d3238bcb96c3e5ea221)

12 years agosh: Fix out of bounds array access when trap is used with an invalid
Peter Avalos [Sun, 5 Feb 2012 19:52:44 +0000 (11:52 -0800)]
sh: Fix out of bounds array access when trap is used with an invalid
signal.

Obtained-from:  FreeBSD 230117
(cherry picked from commit 5748538799e46b68d37b9a51172a8c47607ebdb4)

12 years agosh: Properly show "Not a directory" error in cd builtin.
Peter Avalos [Sun, 5 Feb 2012 19:44:29 +0000 (11:44 -0800)]
sh: Properly show "Not a directory" error in cd builtin.

The errno message display added in 72cbf4010 did not take attempting to
cd to a non-directory or something that cannot be stat()ed into account.

Obtained-from:  FreeBSD 230095
(cherry picked from commit 2b271b9bd2c4b4c7b94e1d246aebde69a6e37819)

12 years agosh: Make various functions static.
Peter Avalos [Sun, 5 Feb 2012 19:42:22 +0000 (11:42 -0800)]
sh: Make various functions static.

Obtained-from:  FreeBSD 229220
(cherry picked from commit b6bd99f63ba9b8eeb9dcfd0f5b11ea363199cd9a)

12 years agosh: Remove unused function scopyn().
Peter Avalos [Sun, 5 Feb 2012 19:30:56 +0000 (11:30 -0800)]
sh: Remove unused function scopyn().

Obtained-from: FreeBSD 229219
(cherry picked from commit 632067f1fe927fb0869e88c9a9711d90f0e7dd60)

12 years agosh: Make patmatch() non-recursive.
Peter Avalos [Sun, 5 Feb 2012 19:28:08 +0000 (11:28 -0800)]
sh: Make patmatch() non-recursive.

Obtained-from:  FreeBSD 229201
(cherry picked from commit ea8fa3ef2fcd3c09935f42b16a7afaae189eec5d)

12 years agosh: Allow quoting ^ and ] in bracket expressions.
Peter Avalos [Sun, 5 Feb 2012 19:23:10 +0000 (11:23 -0800)]
sh: Allow quoting ^ and ] in bracket expressions.

Obtained-from:  FreeBSD 228943
(cherry picked from commit 4353aa4e29e275869dd6e6c5af76ad724bc2e213)

12 years agosh: Use dirent.d_type in pathname generation.
Peter Avalos [Sun, 5 Feb 2012 19:20:09 +0000 (11:20 -0800)]
sh: Use dirent.d_type in pathname generation.

This improves performance for globs where a slash or another component
follows a component with metacharacters by eliminating unnecessary
attempts to open directories that are not.

Obtained-from:  FreeBSD 228942
(cherry picked from commit c601174268e0ea6cad93a733cecb3a07b2c503a6)

12 years agosh: Cache de->d_namlen in a local variable.
Peter Avalos [Sun, 5 Feb 2012 19:16:08 +0000 (11:16 -0800)]
sh: Cache de->d_namlen in a local variable.

Obtained-from:  FreeBSD 228941
(cherry picked from commit 867f2c406941a0de5691b6e550dbaea0262a3429)

12 years agosh: Don't force special builtins non-special in optimized command subst.
Peter Avalos [Sun, 5 Feb 2012 19:11:06 +0000 (11:11 -0800)]
sh: Don't force special builtins non-special in optimized command subst.

This is not necessary: errors are already caught in evalbackcmd() and
forcelocal handles changes to variables.

Obtained-from:  FreeBSD 228937
(cherry picked from commit d303b442299ef4e2fd081023559b4a89656d1ebf)

12 years agoSupport exception handling on statically-linked binaries
John Marino [Sun, 5 Feb 2012 16:21:27 +0000 (17:21 +0100)]
Support exception handling on statically-linked binaries

The real-time dynamic linker handles exceptions on dynamically-linked
binaries through the dl_iterate_phdr function.  The RTLD isn't invoked
on statically-built executables so thrown exceptions weren't getting
handled.  There was a dummy dl_iterate_phdr function in libc with a
weak symbol that gets looked at when the rtld version isn't present.
This function was populated and gets called when the statically-linked
executable throws an exception.

It requires the GNU_EH_FRAME program header to be present.  The base
gcc 4.4 spec file was modified to emit this header for statically-built
binaries in addition to the dynamically lined ones.

12 years agocdefs: Rework and augment visibility attributes
John Marino [Sun, 5 Feb 2012 16:14:25 +0000 (17:14 +0100)]
cdefs: Rework and augment visibility attributes

One macro based on GCC visibility functions was already defined,
__exported.  However, it was marked as available for all GCC versions
when it fact it was introduced with gcc 4.0.

There was no macro for hidden visibility attributes, so the macros
__dso_hidden and __dso_public were borrowed from NetBSD.  __dso_public
is an alias for __exported.  The definition for all three macros were
made on the condition that the gcc version used is 4.0 or later.

12 years agovkernel - Fix semi-random SIGILL crashes under heavy network loads
Matthew Dillon [Thu, 2 Feb 2012 23:17:44 +0000 (15:17 -0800)]
vkernel - Fix semi-random SIGILL crashes under heavy network loads

* SIGIO was being installed with SA_NODEFER, resulting in situations
  under heavy network loads where multiple SIGIOs could stack and cause
  a stack overflow.  This often resulted in the sendsig code in the kernel
  generating a SIGILL to the process after being unable to push a new
  signal context.

* Removing SA_NODEFER appears to solve the problem.

Reported-by: tuxillo
12 years agokernel - Fix lockmgr lock mismatch panics when iwn used without wlan
Matthew Dillon [Thu, 2 Feb 2012 03:43:26 +0000 (19:43 -0800)]
kernel - Fix lockmgr lock mismatch panics when iwn used without wlan

* If if_iwn is ifconfig'd without going through wlan the wlan_serializer
  is not held during the firmware load stage, resulting in a panic.
  Acquire the serializer for this case.

* Note: iwn worked fine with wlan, but this fixes an annoying panic when
  people try to mess with it without wlan.

Reported-by: fxr (irc)
12 years agokernel - Add missing DRM_LOCK()
Matthew Dillon [Wed, 1 Feb 2012 21:40:19 +0000 (13:40 -0800)]
kernel - Add missing DRM_LOCK()

* Add missing DRM_LOCK() in the i915 X11 ioctl path

Reported-by: Pierre Abbat
Dump-by: Magliano Andrea
12 years agocrypto.ko: Add a missing file.
Sascha Wildner [Tue, 31 Jan 2012 10:17:27 +0000 (11:17 +0100)]
crypto.ko: Add a missing file.

Submitted-by: CosmicDJ
12 years agolibc: correct copyright notice in makecontext.c
Markus Pfeiffer [Fri, 27 Jan 2012 21:59:06 +0000 (21:59 +0000)]
libc: correct copyright notice in makecontext.c

12 years agoMerge branch 'DragonFly_RELEASE_3_0' of ssh://crater.dragonflybsd.org/repository...
Venkatesh Srinivas [Mon, 30 Jan 2012 12:15:03 +0000 (04:15 -0800)]
Merge branch 'DragonFly_RELEASE_3_0' of ssh://crater.dragonflybsd.org/repository/git/dragonfly into rel3_0

12 years agokernel -- nata: Use ATA_DEFAULT_TIMEOUT (10) rather than 1 for ATA controlcmds.
Venkatesh Srinivas [Fri, 27 Jan 2012 10:55:15 +0000 (02:55 -0800)]
kernel -- nata: Use ATA_DEFAULT_TIMEOUT (10) rather than 1 for ATA controlcmds.

A one-second timeout for control commands was inappropriate for
SET TRANSFER MODE/ENABLE RCACHE/ENABLE WCACHE on spun-down WD Caviar Greens,
among others.

12 years agokernel: Add some missing headers to the Makefiles of cryptodev and tun.
Sascha Wildner [Sun, 29 Jan 2012 21:39:58 +0000 (22:39 +0100)]
kernel: Add some missing headers to the Makefiles of cryptodev and tun.

Reported-by: CosmicDJ on #dragonflybsd
12 years agotexinfo: Add /usr/pkg/info to the list of directories searched by info(1).
Sascha Wildner [Sun, 29 Jan 2012 21:15:31 +0000 (22:15 +0100)]
texinfo: Add /usr/pkg/info to the list of directories searched by info(1).

12 years agokernel - properly initialize vnode->v_pfsmp
Francois Tigeot [Sun, 29 Jan 2012 08:42:38 +0000 (09:42 +0100)]
kernel - properly initialize vnode->v_pfsmp

* add and rewrite comments to document it better

12 years agoRevert "sys/config: Readd COMPAT_43 to i386 kernels: COMPAT_LINUX needs it"
Thomas Nikolajsen [Sat, 28 Jan 2012 01:04:27 +0000 (02:04 +0100)]
Revert "sys/config: Readd COMPAT_43 to i386 kernels: COMPAT_LINUX needs it"

This reverts commit dbcbcaa29ebe161b19b6cec288c1a8559aebc0a0.

12 years agoCOMPAT_LINUX: Remove need for COMPAT_43
Thomas Nikolajsen [Sat, 28 Jan 2012 00:59:37 +0000 (01:59 +0100)]
COMPAT_LINUX: Remove need for COMPAT_43

Implement linux_sethostname and linux_ostat natively to
stop using implementation from COMPAT_43.

Dragonfly-bug: <http://bugs.dragonflybsd.org/issue2289>
Submitted-by: Samuel J. Greear and Matt Dillon
12 years agoMerge commit 'crater/DragonFly_RELEASE_3_0' into rel3_0
Thomas Nikolajsen [Thu, 26 Jan 2012 23:11:49 +0000 (00:11 +0100)]
Merge commit 'crater/DragonFly_RELEASE_3_0' into rel3_0

12 years agosys/config: Readd COMPAT_DF12 to i386 kernels, to run FreeBSD 4 binaries
Thomas Nikolajsen [Thu, 26 Jan 2012 22:58:05 +0000 (23:58 +0100)]
sys/config: Readd COMPAT_DF12 to i386 kernels, to run FreeBSD 4 binaries

Commit ce6b2144 made this change to GENERIC,
do the same for the other i386 kernels.

12 years agosys/config: Readd COMPAT_43 to i386 kernels: COMPAT_LINUX needs it
Thomas Nikolajsen [Thu, 26 Jan 2012 22:52:53 +0000 (23:52 +0100)]
sys/config: Readd COMPAT_43 to i386 kernels: COMPAT_LINUX needs it
Dragonfly-bug: <http://bugs.dragonflybsd.org/issue2289>

12 years agolibc: add getcontext, setcontext, makecontext and swapcontext on x86_64
Markus Pfeiffer [Wed, 25 Jan 2012 13:11:23 +0000 (13:11 +0000)]
libc: add getcontext, setcontext, makecontext and swapcontext on x86_64

The *context functions are not part of the POSIX standard anymore, but
are still used by quite some packages.

12 years agodrm - Add PCI ID for Radeon HD 4250 (AMD 880 onboard video)
Samuel J. Greear [Thu, 26 Jan 2012 04:39:34 +0000 (21:39 -0700)]
drm - Add PCI ID for Radeon HD 4250 (AMD 880 onboard video)

12 years agoSwitch the 3.0-RELEASE branch back to using binutils-2.21.
Sascha Wildner [Wed, 25 Jan 2012 19:39:59 +0000 (20:39 +0100)]
Switch the 3.0-RELEASE branch back to using binutils-2.21.

There are still 2.22 specific issues in pkgsrc and we want to be on
the safe side for the release.

Requested-by: marino
12 years agoRevert "nataraid(4): Add devstat support."
Sascha Wildner [Wed, 25 Jan 2012 08:05:46 +0000 (09:05 +0100)]
Revert "nataraid(4): Add devstat support."

This reverts commit 3e184884618d66845f8b90e6dae483155da6dce6.

Oops, it was a bit too untested and causes nasty messages on the
console. Will investigate and commit a proper fix.

Reported-by: Joerg Anslik <joerg@anslik.de>
12 years agokernel - Fix SILI callout timer race
Matthew Dillon [Mon, 23 Jan 2012 20:55:33 +0000 (12:55 -0800)]
kernel - Fix SILI callout timer race

* Do similar fix for SILI that we did for AHCI.

* callout_stop_sync() can block.  If this occurs a race can cause a
  CCB to be processed for completion twice.

* Add a serial number to detect this situation.

* If the serial number does not match after the timeout is stopped
   we don't want to mess with the xa at all.

Tested-by: lentferj
12 years agokernel/firewire: Move a dereference behind the NULL check.
Sascha Wildner [Mon, 23 Jan 2012 00:55:44 +0000 (01:55 +0100)]
kernel/firewire: Move a dereference behind the NULL check.

12 years agoRaise default .Os value for the manual pages to 3.0 on the release branch.
Sascha Wildner [Sun, 22 Jan 2012 22:45:04 +0000 (23:45 +0100)]
Raise default .Os value for the manual pages to 3.0 on the release branch.

12 years agoSwitch to pkgsrc-2011Q4.
Justin C. Sherrill [Sun, 22 Jan 2012 22:35:37 +0000 (17:35 -0500)]
Switch to pkgsrc-2011Q4.

12 years agoRelease 3.0 branch. v3.0.0
Justin C. Sherrill [Sun, 22 Jan 2012 21:05:08 +0000 (13:05 -0800)]
Release 3.0 branch.

12 years agocrontab(1): Adjust the number of comment lines in front of the tab.
Sascha Wildner [Sun, 22 Jan 2012 20:26:41 +0000 (21:26 +0100)]
crontab(1): Adjust the number of comment lines in front of the tab.

In 229cb57b2cbab37a8a0cc1499cebf7e9c9e1deec I removed the third line
of comment that crontab(1) puts in front of the tab file (which was
the CVS ID of crontab.c), but I forgot to adjust the #define saying
how much lines to skip.

This led to the first line of comment written by the user not being
visible in crontab -e.

Reported-by: lentferj
12 years agofwcontrol(8): Remove an unused variable and raise WARNS to 2.
Sascha Wildner [Sun, 22 Jan 2012 19:35:23 +0000 (20:35 +0100)]
fwcontrol(8): Remove an unused variable and raise WARNS to 2.

12 years agokernel/acpi: Fix a reference to an uninitialized ptr.
Sascha Wildner [Sun, 22 Jan 2012 12:29:29 +0000 (13:29 +0100)]
kernel/acpi: Fix a reference to an uninitialized ptr.

12 years agosendfile: Block or return EAGAIN, iff we are really short of space
Sepherosa Ziehau [Sun, 22 Jan 2012 13:59:30 +0000 (21:59 +0800)]
sendfile: Block or return EAGAIN, iff we are really short of space

Send sockbuf's lowat could be quite "high" (hiwat/2), the originally
code actually only uses 1/2 of the send sockbuf space, thus poor
performance.

12 years agosockbuf: Pre-alloc sockbuf space, so asynchronized pru_send could be used.
Sepherosa Ziehau [Sun, 22 Jan 2012 13:29:29 +0000 (21:29 +0800)]
sockbuf: Pre-alloc sockbuf space, so asynchronized pru_send could be used.

When doing asynchronized pru_send, it is quite possible that we could
break the send sockbuf's upper limit, if we only use ssb_space() to
calculate the remaining sockbuf space.

Now, we add another two counters into sockbuf, when we send a mbuf
chain to the netisr, we update the these two counters to reflect how
much mbufs will be pending on the send sockbuf.  When calculating the
remaining space of the send sockbuf we also take these two counters
into consideration, so we will not break the upper limit of the send
sockbuf.  These two counter will also be updated when the mbufs in
the sockbuf is to be dropped/freed.

Reenable the asynchronized pru_send in sendfile and sosendtcp

12 years agopru_send: Disable asynchornized pru_send usage by default
Sepherosa Ziehau [Sun, 22 Jan 2012 09:36:07 +0000 (17:36 +0800)]
pru_send: Disable asynchornized pru_send usage by default

It may cause problem, e.g. too many mbufs sitting in the TCP send buffer,
when facing with certain attacks, e.g. FIN_WAIT_1 DoS.

Reported-by: pavalos@
12 years agosendfile: Add sysctl to disable the usage of the asynchronized pru_send
Sepherosa Ziehau [Sun, 22 Jan 2012 09:33:08 +0000 (17:33 +0800)]
sendfile: Add sysctl to disable the usage of the asynchronized pru_send

12 years agocarp: BGL -> CARP global token
Sepherosa Ziehau [Sun, 22 Jan 2012 03:54:14 +0000 (11:54 +0800)]
carp: BGL -> CARP global token

12 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Samuel J. Greear [Sat, 21 Jan 2012 21:46:56 +0000 (14:46 -0700)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

12 years agorc - Add a default setting for udevd_early, silences warning at boot
Samuel J. Greear [Sat, 21 Jan 2012 21:46:24 +0000 (14:46 -0700)]
rc - Add a default setting for udevd_early, silences warning at boot

12 years agoMerge commit 'crater/master'
Thomas Nikolajsen [Sat, 21 Jan 2012 20:27:27 +0000 (21:27 +0100)]
Merge commit 'crater/master'

12 years agoetc/auth.conf: Add sha512/sha256/blf
Thomas Nikolajsen [Sat, 21 Jan 2012 18:54:12 +0000 (19:54 +0100)]
etc/auth.conf: Add sha512/sha256/blf

12 years agologin.conf.5: Add sha256/sha512
Thomas Nikolajsen [Sat, 21 Jan 2012 18:51:03 +0000 (19:51 +0100)]
login.conf.5: Add sha256/sha512

12 years agopam_unix.c: Change default hash
Thomas Nikolajsen [Sat, 21 Jan 2012 18:26:10 +0000 (19:26 +0100)]
pam_unix.c: Change default hash

Change to sha512; same as in etc/login.conf.

12 years agologin.conf.5: Fix mdoc problems
Thomas Nikolajsen [Sat, 21 Jan 2012 17:57:10 +0000 (18:57 +0100)]
login.conf.5: Fix mdoc problems

Fix problems identified by mandoc(1).

To get both groff(1) and mandoc(1) to format nice
headlines changed from TAB changed to Ta use.
This seems like a groff(1) bug.

12 years agocrypt.3: Update algorithm numbers ($N$)
Thomas Nikolajsen [Sat, 21 Jan 2012 17:43:40 +0000 (18:43 +0100)]
crypt.3: Update algorithm numbers ($N$)

Fix algorithm number for Blowfish, SHA256 and SHA512,
note that existing SHA256 and SHA512 implementations
are deprecated and add new implementations.

While here add missing line breaks at end of sentence.

12 years agoFix buildkernel -j N
Thomas Nikolajsen [Sat, 21 Jan 2012 17:10:32 +0000 (18:10 +0100)]
Fix buildkernel -j N

Work around build ordering issue which caused
`make -j N buildkernel' to fail on some systems.

DragonFly-bug: <http://bugs.dragonflybsd.org/issue2279>
Submitted-by: YONETANI Tomokazu
12 years agonataraid(4): Add devstat support.
Sascha Wildner [Sat, 21 Jan 2012 16:34:46 +0000 (17:34 +0100)]
nataraid(4): Add devstat support.

12 years agoinstaller: Warn <10GB HAMMER filesystems are unsupported
Francois Tigeot [Sat, 21 Jan 2012 12:04:31 +0000 (13:04 +0100)]
installer: Warn <10GB HAMMER filesystems are unsupported

12 years agoAdd a copyright notice to cpputil.h
Aggelos Economopoulos [Fri, 20 Jan 2012 23:13:24 +0000 (00:13 +0100)]
Add a copyright notice to cpputil.h

Claim copyright inasmuch as there is any to claim for this trivial file.

Reminded-by: swildner@
12 years agokernel: Remove some more old major number related stuff.
Sascha Wildner [Fri, 20 Jan 2012 22:27:01 +0000 (23:27 +0100)]
kernel: Remove some more old major number related stuff.

12 years agocrypt(3) - Forgotten string in last commit
Samuel J. Greear [Fri, 20 Jan 2012 20:12:55 +0000 (13:12 -0700)]
crypt(3) - Forgotten string in last commit

12 years agocrypt(3) - Paper over sizeof()/strlen() bug causing 32/64-bit issues
Samuel J. Greear [Fri, 20 Jan 2012 20:04:56 +0000 (13:04 -0700)]
crypt(3) - Paper over sizeof()/strlen() bug causing 32/64-bit issues

* In one place sizeof() was used instead of strlen(), causing the password
  to be muxed with 4 bytes of random stack data on 64-bit machines. Codify
  this behavior for reverse compatibility.

12 years agokernel - Fix AHCI callout timer race (2)
Matthew Dillon [Fri, 20 Jan 2012 19:23:54 +0000 (11:23 -0800)]
kernel - Fix AHCI callout timer race (2)

* Fix minor bug in last commit.  If the serial number does not match
  after the timeout is stopped we don't want to mess with the xa at
  all.

12 years agokernel - Fix race in callout_stop_sync()
Matthew Dillon [Fri, 20 Jan 2012 18:23:06 +0000 (10:23 -0800)]
kernel - Fix race in callout_stop_sync()

* When callout_stop_sync() races a timeout callback which re-arms the
  callout it can hit an assertion.  The assertion is incorrect.  Instead
  of asserting we have to loop up and try again.

12 years agokernel - Fix AHCI callout timer race
Matthew Dillon [Fri, 20 Jan 2012 18:20:20 +0000 (10:20 -0800)]
kernel - Fix AHCI callout timer race

* callout_stop_sync() can block.  If this occurs a race can cause a
  CCB to be processed for completion twice.

* Add a serial number to detect this situation.

Reported-by: "G. Isenmann via Redmine"
12 years agokernel - Fix pmap_release() bug for i386
Matthew Dillon [Fri, 20 Jan 2012 17:56:51 +0000 (09:56 -0800)]
kernel - Fix pmap_release() bug for i386

* Fix 'pmap_release: page should already be gone' panic

* There is a race condition which can result in the case.  Release the
  page normally instead of panicing.

Reported-by: tuxillo
12 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Samuel J. Greear [Fri, 20 Jan 2012 13:16:44 +0000 (06:16 -0700)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

12 years agocrypt(3) - Switch SHA256/512 to the Linux implementation
Samuel J. Greear [Fri, 20 Jan 2012 12:24:33 +0000 (05:24 -0700)]
crypt(3) - Switch SHA256/512 to the Linux implementation

* The existing SHA backends have been shown to be more susceptible to brute-
  force attacks than we would prefer --
  http://www.openwall.com/lists/oss-security/2012/01/16/2

* Bring in the reference implementation used in Linux, code is in the public
  domain.

* Add required (standard) functions mempcpy and stpcpy.

* Change default for future installs to SHA512, this is the default on at
  least archlinux and fedora.

* Add some minor hacks to libcrypt/crypt.c to ensure that
  a) All existing passwords continue to work
  b) All future passwords will be more secure with no changes required

* To update passwords to the new format use passwd(1) for each user, and to
  change your default password type to SHA512 (default for new installations)
  change the passwd_format setting under default to "sha512".

12 years agoicu_abi/x86_64: {msi,msix}_release returns nothing
Sepherosa Ziehau [Fri, 20 Jan 2012 06:37:59 +0000 (14:37 +0800)]
icu_abi/x86_64: {msi,msix}_release returns nothing

12 years agoi386: Implement MSI-X allocation and release support
Sepherosa Ziehau [Fri, 20 Jan 2012 06:35:34 +0000 (14:35 +0800)]
i386: Implement MSI-X allocation and release support

12 years agoicu/x86_64: Implement MSI-X alloc/release
Sepherosa Ziehau [Fri, 20 Jan 2012 05:09:05 +0000 (13:09 +0800)]
icu/x86_64: Implement MSI-X alloc/release

12 years agokernel: Remove two more major numbers.
Sascha Wildner [Fri, 20 Jan 2012 04:28:10 +0000 (05:28 +0100)]
kernel: Remove two more major numbers.

12 years agokernel: Remove some old major numbers.
Sascha Wildner [Fri, 20 Jan 2012 04:15:50 +0000 (05:15 +0100)]
kernel: Remove some old major numbers.

12 years agoLINT/LINT64: Add snd_gusc.
Sascha Wildner [Fri, 20 Jan 2012 03:58:59 +0000 (04:58 +0100)]
LINT/LINT64: Add snd_gusc.

12 years agoGENERIC: Add back COMPAT_DF12.
Sascha Wildner [Fri, 20 Jan 2012 03:58:35 +0000 (04:58 +0100)]
GENERIC: Add back COMPAT_DF12.

It's a good thing, because it allows for running FreeBSD 4 binaries.

Requested-by: vsrinivas
12 years agokernel: Fix building of snd_gusc.
Sascha Wildner [Fri, 20 Jan 2012 03:56:16 +0000 (04:56 +0100)]
kernel: Fix building of snd_gusc.

12 years agojme: Support multiple MSI-X interrupt model
Sepherosa Ziehau [Fri, 20 Jan 2012 03:00:16 +0000 (11:00 +0800)]
jme: Support multiple MSI-X interrupt model

12 years agoahci(4)/sili(4): Fix some comments.
Sascha Wildner [Fri, 20 Jan 2012 02:13:44 +0000 (03:13 +0100)]
ahci(4)/sili(4): Fix some comments.

Submitted-by: Johannes Hofmann <johannes.hofmann@gmx.de>
Dragonfly-bug: <http://bugs.dragonflybsd.org/issues/1692>

12 years agoRemove empty DragonFly CVS IDs.
Sascha Wildner [Fri, 20 Jan 2012 02:07:02 +0000 (03:07 +0100)]
Remove empty DragonFly CVS IDs.

12 years agoUpdate files for OpenSSL-1.0.0g import.
Peter Avalos [Fri, 20 Jan 2012 00:19:17 +0000 (16:19 -0800)]
Update files for OpenSSL-1.0.0g import.

12 years agoMerge branch 'vendor/OPENSSL'
Peter Avalos [Fri, 20 Jan 2012 00:17:27 +0000 (16:17 -0800)]
Merge branch 'vendor/OPENSSL'

12 years agoImport OpenSSL-1.0.0g.
Peter Avalos [Fri, 20 Jan 2012 00:11:16 +0000 (16:11 -0800)]
Import OpenSSL-1.0.0g.

o Fix for DTLS DoS issue CVE-2012-0050

12 years agovquota(8): Remove unneeded braces
François Tigeot [Thu, 19 Jan 2012 10:57:20 +0000 (11:57 +0100)]
vquota(8): Remove unneeded braces

12 years agovquota(8): Display full user and group names
François Tigeot [Thu, 19 Jan 2012 10:03:41 +0000 (11:03 +0100)]
vquota(8): Display full user and group names

* Full user and group names are now displayed by default

* add a -n flag to show the raw user and group ids

* refactor the code to use common id printing functions

12 years agoi386: Unbreak LINT building
Sepherosa Ziehau [Thu, 19 Jan 2012 08:10:02 +0000 (16:10 +0800)]
i386: Unbreak LINT building

12 years agobus: Pass intsrerupt description to setup_intr bus method
Sepherosa Ziehau [Thu, 19 Jan 2012 07:49:17 +0000 (15:49 +0800)]
bus: Pass intsrerupt description to setup_intr bus method

If no interrupt description is supplied, then the device's name
will be used.

Add bus_setup_intr_descr(), which allow device drivers to pass
interrupt description.  Reimplement bus_setup_intr() using
bus_setup_intr_descr().

12 years agojme: Split ifnet serializer; in preparation for multiple MSI-X support
Sepherosa Ziehau [Thu, 19 Jan 2012 03:37:37 +0000 (11:37 +0800)]
jme: Split ifnet serializer; in preparation for multiple MSI-X support

12 years agoDisable HAMMER live dedup, mark as experimental
François Tigeot [Wed, 18 Jan 2012 09:36:56 +0000 (10:36 +0100)]
Disable HAMMER live dedup, mark as experimental

* Comment out mentions to it in the hammer(8) manpage

* Live-dedup is a relatively new feature that has not undergone
  extensive testing.

* It may have some issues with HAMMER bigblocks, we do not want
  users to run it on production machines yet.

12 years agocarp: Add comment about carp_update_addrs()
Sepherosa Ziehau [Wed, 18 Jan 2012 08:46:10 +0000 (16:46 +0800)]
carp: Add comment about carp_update_addrs()

12 years agonexus/x86_64: Implement {alloc,release}_msix pcib methods
Sepherosa Ziehau [Wed, 18 Jan 2012 01:32:29 +0000 (09:32 +0800)]
nexus/x86_64: Implement {alloc,release}_msix pcib methods

12 years agoioapic_abi/x86_64: Implement MSI-X alloc/release
Sepherosa Ziehau [Tue, 17 Jan 2012 10:05:21 +0000 (18:05 +0800)]
ioapic_abi/x86_64: Implement MSI-X alloc/release

12 years agomsix/pci: Enable MSI-X by default
Sepherosa Ziehau [Tue, 17 Jan 2012 08:52:36 +0000 (16:52 +0800)]
msix/pci: Enable MSI-X by default

12 years agomsix: Use msix_table_res to determine whether MSI-X is used or not
Sepherosa Ziehau [Tue, 17 Jan 2012 08:03:14 +0000 (16:03 +0800)]
msix: Use msix_table_res to determine whether MSI-X is used or not

12 years agomsix: Make sure vectors are not allocated before setup/teardown
Sepherosa Ziehau [Tue, 17 Jan 2012 07:56:06 +0000 (15:56 +0800)]
msix: Make sure vectors are not allocated before setup/teardown

12 years agomsix: Rework MSI-X allocation, step 5/5
Sepherosa Ziehau [Tue, 17 Jan 2012 07:40:11 +0000 (15:40 +0800)]
msix: Rework MSI-X allocation, step 5/5

Add release_msix_vector pci method

12 years agomxge: Unbreak LINT building due to recent MSI-X allocation changes
Sepherosa Ziehau [Tue, 17 Jan 2012 06:09:44 +0000 (14:09 +0800)]
mxge: Unbreak LINT building due to recent MSI-X allocation changes

12 years agomsix: Rework MSI-X allocation, step 4/many
Sepherosa Ziehau [Tue, 17 Jan 2012 03:57:40 +0000 (11:57 +0800)]
msix: Rework MSI-X allocation, step 4/many

Save MSI-X vector information for resuming and verification

12 years agouname - Allow varsym overrides
Matthew Dillon [Tue, 17 Jan 2012 02:42:26 +0000 (18:42 -0800)]
uname - Allow varsym overrides

* A varsym named UNAME_<opt> will override a uname option, similar to
  how environment variables override a uname option.  Environment variables
  take priority.

12 years agovarsym - Add -x option
Matthew Dillon [Tue, 17 Jan 2012 02:41:24 +0000 (18:41 -0800)]
varsym - Add -x option

* Add the -x option which causes varsym to set per-process variables and
  then exec the command line from the first non-varsym-assign.  For example:

  varsym -x UNAME_n=fubar uname
  varsym -x UNAME_n=fubar /bin/csh
  etc

12 years agoFix the ktr(4) formats for pid_t and lwpid_t on x86_64
Aggelos Economopoulos [Mon, 16 Jan 2012 20:58:37 +0000 (12:58 -0800)]
Fix the ktr(4) formats for pid_t and lwpid_t on x86_64