dragonfly.git
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 agolast(1)/sort(1): Remove __RCSID().
Sascha Wildner [Fri, 27 Jan 2012 09:55:09 +0000 (10:55 +0100)]
last(1)/sort(1): Remove __RCSID().

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 agoRevert "Remove mergemaster(8)."
Sascha Wildner [Wed, 25 Jan 2012 18:35:25 +0000 (19:35 +0100)]
Revert "Remove mergemaster(8)."

This reverts commit 650094e10aa76969d99d60b3e506b55e4e2bf5fc.

It is still being used by people.

I thought mergemaster was only useful in conjunction with maintained
CVS IDs. Should have known about its -s option.

Requested-by: pavalos
12 years agoRemove mergemaster(8).
Sascha Wildner [Wed, 25 Jan 2012 18:05:05 +0000 (19:05 +0100)]
Remove mergemaster(8).

12 years agokget.8: Rewrite it a bit and fix some mdoc stuff.
Sascha Wildner [Wed, 25 Jan 2012 09:24:08 +0000 (10:24 +0100)]
kget.8: Rewrite it a bit and fix some mdoc stuff.

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: Use bioq_takefirst() in a few more places.
Sascha Wildner [Mon, 23 Jan 2012 13:20:14 +0000 (14:20 +0100)]
kernel: Use bioq_takefirst() in a few more places.

12 years agoldscript.*: sync with FreeBSD
John Marino [Sun, 22 Jan 2012 19:09:11 +0000 (20:09 +0100)]
ldscript.*: sync with FreeBSD

12 years agocsu: Add .note.ABI-tag and .note.GNU-stack
John Marino [Mon, 23 Jan 2012 00:21:15 +0000 (01:21 +0100)]
csu: Add .note.ABI-tag and .note.GNU-stack

For all arches except sparc, gcc emits the section directive for the
following struct with a PROGBITS type.  However, newer versions of binutils
(after 2.16.90) require the section to be of NOTE type, to guarantee that
the .note.ABI-tag section correctly ends up in the first page of the final
executable.

Unfortunately, there is no clean way to tell gcc to use another section
type, so this C file (or the C file that includes it) must be compiled in
multiple steps:

- Compile the .c file to a .s file.
- Edit the .s file to change the 'progbits' type to 'note', for the section
  directive that defines the .note.ABI-tag section.
- Compile the .s file to an object file.

These steps are done in the invididual Makefiles for each applicable arch.

Taken-from: FreeBSD SVN 217375 (13 JAN 2011)

On i386 crtn.S:
Keep the stack aligned to a 16 byte boundary when calling init functions
so that we don't cause a bus error if they start storing SSE math stuff
on the stack.

Taken-from: FreeBSD SVN 146369 (19 MAY 2005)

12 years agoelf: Add translation function between vm_prot_t and p_flags
John Marino [Sat, 21 Jan 2012 19:48:38 +0000 (20:48 +0100)]
elf: Add translation function between vm_prot_t and p_flags

No functionality added, just refactors code.  This will be useful if
stack protection is implemented in the future.

12 years agoman rtld: add -fPIC flag to _rtld_functrace example
John Marino [Sat, 21 Jan 2012 22:28:57 +0000 (23:28 +0100)]
man rtld: add -fPIC flag to _rtld_functrace example

12 years agortld: Add STT_GNU_IFUNC and R_MACHINE_IRELATIVE_GNU support
John Marino [Sat, 21 Jan 2012 23:00:15 +0000 (00:00 +0100)]
rtld: Add STT_GNU_IFUNC and R_MACHINE_IRELATIVE_GNU support

Add support for STT_GNU_IFUNC and R_MACHINE_IRELATIVE GNU extensions to
rtld. This adds runtime bits neccessary for the use of the dispatch
functions from the dynamically-linked executables and shared libraries.

To allow use of external references from the dispatch function, resolution
of the R_MACHINE_IRESOLVE relocations in PLT is postponed until GOT entries
for PLT are prepared, and normal resolution of the GOT entries is finished.
Similar to how it is done by GNU, IRELATIVE relocations are resolved in
advance, instead of normal lazy handling for PLT.

Taken-from:
FreeBSD SVN 228435 (12 DEC 2011)
FreeBSD SVN 228503 (14 DEC 2011)
FreeBSD SVN 229508 (04 JAN 2012)

12 years agortld: Use DAGS for symbol lookup; adjust weak symbol logic
John Marino [Sat, 21 Jan 2012 21:35:24 +0000 (22:35 +0100)]
rtld: Use DAGS for symbol lookup; adjust weak symbol logic

get_program_var_addr() must prefer the strong symbol to the weak one.
Search global objects, together with main object and dependencies for the
requested symbol.

Move the common code from symlook_default() into new helper
symlook_global(), and use it both in symlook_global() and
get_program_var_addr().  Supply lock state to get_program_var_addr().

Taken-from: FreeBSD SVN 217223 (10 JAN 2011)

Eliminate the use of symlook_needed function in favor of DAGS.  Place
elements on DAG lists in breadth-first order. This allows us to walk
pre-built list in all cases where breadth-first dependency chain
enumeration is required.

Fix dlsym on special handle obtained by dlopen(NULL, ...) to do what
comment claims it does. Take advantage of recently added symlook_global
function to iterate over main objects and global DAGs lists properly in
search of a symbol. Since rtld itself provides part of the global
namespace, search rtld_obj too.

Remove recursion from init_dag and symlook_needed functions. Use
symlook_needed for ELF filtee processing only and change lookup order
used in the function to match the order used by Solaris runtime linker
under same circumstances. While there, fix weak symbol handling in the
loop so that we return the first weak symbol definition if no strong one
was found, instead of the last one.

Taken-from: FreeBSD SVN 218051 (28 JAN 2011)

12 years agortld: Add stubs to support PT_GNU_STACK
John Marino [Sat, 21 Jan 2012 20:53:12 +0000 (21:53 +0100)]
rtld: Add stubs to support PT_GNU_STACK

This functionality requires kernel support to determine the initial stack
access mode.  This is how it's supposed to work:

If the loaded DSO requires an executable stack as specified by the PF_X
bit or p_flags on PT_GNU_STACK phdr, yet the current stack protection does
not permit execution: The map_stacks_exec function should change the
stack protection mode of all thread stacks.

The PT_GNU_STACK phdr parser has been implemented as well as a private
interface to _rtld_get_stack_prot() in order to export the stack access
mode calculated by rtld.

Left to do:
1) Implement stack protection in the kernel
2) Add PT_GNU_STACK functionality in the kernel
3) Add a method to change stack protection mode in libc or libthread
4) Implement map_stacks_exec function in rtld.

12 years agortld: Implement ELF filters (DT_FILTER and DT_AUXILIARY)
John Marino [Sat, 21 Jan 2012 17:31:30 +0000 (18:31 +0100)]
rtld: Implement ELF filters (DT_FILTER and DT_AUXILIARY)

Filtrees are loaded on demand unless LD_LOADFLTR environment variable is
set or -z loadfltr was specified during the linking.  This forces rtld
to upgrade read-locked rtld_bind_lock to write lock when it encounters an
object with filter during symbol lookup.

Consolidate common arguments of the symbol lookup functions in the SymLook
structure.

Taken-from: FreeBSD SVN 216728 (27 DEC 2010)

12 years agortld: Remove useless arch Makefiles
John Marino [Sat, 21 Jan 2012 21:02:15 +0000 (22:02 +0100)]
rtld: Remove useless arch Makefiles

The ability to build an executable dynamic linker was previously removed
from the main makefile, so uncommenting LDSCRIPT in the arch Makefile
would no longer work even if the elf_rtld.x files were put in the arch
directory.  To avoid confusion, these optional Makefiles have been
completely removed.

12 years agortld: Make thread-safe by replacing libc printf functions
John Marino [Sat, 21 Jan 2012 15:07:30 +0000 (16:07 +0100)]
rtld: Make thread-safe by replacing libc printf functions

The dynamic linker is linked with the specially built static pic libc to
get some C runtime services such as printf().  Unfortunately, the
multithread-safeness measures in libc do now work in the rtld environment.

The dynlinker now uses FreeBSD's kernel printf() implementation instead of
libc's version.  This printf does not require any shared global data and
thus is mt-safe.  This commit replaces printf() and related functions with
rtld_ versions, and also removes calls to err(3).

Currently stdio is still pulled from libc within the libmap implementation
that uses fopen().  This is safe, yet not optimal, and is a candidate for
future change.

The makefile was cleaned up to remove the unused bits to building an
executable dynlinker and also require gnu99.

Taken-from: FreeBSD SVN 225152

12 years agortld: Set foundation to use aux vectors to get osreldate
John Marino [Sat, 21 Jan 2012 13:13:17 +0000 (14:13 +0100)]
rtld: Set foundation to use aux vectors to get osreldate

__getosreldate isn't used by rtld currently.  The FreeBSD dynamic linker
does use it indirectly in libc's mmap wrapper.  The capability is included
here both to ease the task to synchronizing with FreeBSD, and to quickly
obtain the capability in the future if necessary.  It's currently disabled
with the undefined ENABLE_OSRELDATE macro.

The splitting of digest_dynamic required to use aux vectors also has the
benefit of avoiding the use of malloc at startup.

12 years agortld: Compress FreeBSD CVSIDs
John Marino [Sat, 21 Jan 2012 11:08:45 +0000 (12:08 +0100)]
rtld: Compress FreeBSD CVSIDs

The FreeBSD repository is still handled by CVS, but its converted to
Subversion and from that, git.  Neither the svn nor git version feature
expanded $FreeBSD$ tags.  The only way to get this is to pull directly
from CVS which isn't convenient.

In the case of a few files, the only difference between the DragonFly
version and the FreeBSD version is the CVS tag.  As the main development
of rtld is happening on FreeBSD and since I've started collaborating
with FreeBSD developers on new dynamic linker features, we want to
actively keep our linkers synchronized.  Compressing the FreeBSD CVSID
tags makes that easier for me, the only person currently maintaining
the dynamic linker.  The usually-wrong expanded CVS tag wasn't providing
any useful information to me either.

12 years agortld: Remove unused xrealloc function
John Marino [Sat, 21 Jan 2012 10:52:42 +0000 (11:52 +0100)]
rtld: Remove unused xrealloc function

xrealloc was added back in the prebind support days, but wasn't removed
when the resident executable support that replaced it arrived back in
2004.

12 years agoUnbreak buildworld due to the libpcap import.
Peter Avalos [Mon, 23 Jan 2012 08:30:48 +0000 (00:30 -0800)]
Unbreak buildworld due to the libpcap import.

12 years agocarp: Use ifq_set_maxlen() to set send queue's max length
Sepherosa Ziehau [Mon, 23 Jan 2012 03:45:01 +0000 (11:45 +0800)]
carp: Use ifq_set_maxlen() to set send queue's max length

While im here, clean up white space and indentation

12 years agoMerge branch 'master' of /home/www-data/gitweb/dragonfly
Peter Avalos [Mon, 23 Jan 2012 03:07:23 +0000 (19:07 -0800)]
Merge branch 'master' of /home/www-data/gitweb/dragonfly

12 years agoUpdate files for tcpdump-4.2.1 import.
Peter Avalos [Mon, 23 Jan 2012 03:05:13 +0000 (19:05 -0800)]
Update files for tcpdump-4.2.1 import.

12 years agoMerge branch 'vendor/TCPDUMP'
Peter Avalos [Mon, 23 Jan 2012 01:25:22 +0000 (17:25 -0800)]
Merge branch 'vendor/TCPDUMP'

12 years agoImport tcpdump-4.2.1.
Peter Avalos [Mon, 23 Jan 2012 01:08:25 +0000 (17:08 -0800)]
Import tcpdump-4.2.1.

See the CHANGES files for the details.

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 agokernel/netgraph: Put parentheses around a SLIST_EMPTY().
Sascha Wildner [Mon, 23 Jan 2012 00:23:46 +0000 (01:23 +0100)]
kernel/netgraph: Put parentheses around a SLIST_EMPTY().

12 years agoUpdate files for libpcap-1.2.1 import.
Peter Avalos [Mon, 23 Jan 2012 00:23:29 +0000 (16:23 -0800)]
Update files for libpcap-1.2.1 import.

Reduce diffs from the vendor source.
Reorganize Makefile to make it ordered like the vendor's.

12 years agobktr(4): Fix some mistakes in #ifdef'd code.
Sascha Wildner [Mon, 23 Jan 2012 00:16:15 +0000 (01:16 +0100)]
bktr(4): Fix some mistakes in #ifdef'd code.

12 years agoMerge branch 'vendor/LIBPCAP'
Peter Avalos [Mon, 23 Jan 2012 00:08:22 +0000 (16:08 -0800)]
Merge branch 'vendor/LIBPCAP'

12 years agoImport libpcap-1.2.1.
Peter Avalos [Sun, 22 Jan 2012 19:00:07 +0000 (11:00 -0800)]
Import libpcap-1.2.1.

Look at CHANGES for the details.

12 years agokernel: Remove a variable that was just used for a sizeof.
Sascha Wildner [Sun, 22 Jan 2012 23:14:47 +0000 (00:14 +0100)]
kernel: Remove a variable that was just used for a sizeof.

12 years agolibc: Clean up fmemopen.
Venkatesh Srinivas [Sun, 22 Jan 2012 23:04:49 +0000 (18:04 -0500)]
libc: Clean up fmemopen.

* Remove private definition of min().

* Switch to use bcopy() for fmemopen_write.

12 years agoRaise default .Os value for the manual pages to 3.1 on master.
Sascha Wildner [Sun, 22 Jan 2012 22:42:25 +0000 (23:42 +0100)]
Raise default .Os value for the manual pages to 3.1 on 

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

12 years agokernel: Nuke the old (and deprecated) ata(4) driver and atacontrol(8). v3.1.0
Sascha Wildner [Sun, 22 Jan 2012 21:16:14 +0000 (22:16 +0100)]
kernel: Nuke the old (and deprecated) ata(4) driver and atacontrol(8).

It's been replaced by nata(4)/natacontrol(8) since more than 4 years.

12 years agoMerge branch 'master' of file:///repository/git/dragonfly
Justin C. Sherrill [Sun, 22 Jan 2012 21:06:31 +0000 (13:06 -0800)]
Merge branch 'master' of file:///repository/git/dragonfly

12 years agoShifting master to 3.1.
Justin C. Sherrill [Sun, 22 Jan 2012 21:05:45 +0000 (13:05 -0800)]
Shifting master to 3.1.

12 years agodloader: Remove some unused variables.
Sascha Wildner [Sun, 22 Jan 2012 21:01:40 +0000 (22:01 +0100)]
dloader: Remove some unused variables.

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