Commits on Mar 20, 2012
  1. mpt(4): Fix an issue that caused the driver to attach to mfi(4) cards.

    FreeBSD's commit message (r232411) explains it:
    Fix a problem that was causing the mpt(4) driver to attach to MegaRAID
    cards that should be handled by the mfi(4) driver.
    The root of the problem is that the mpt(4) driver was masking off the
    bottom bit of the PCI device ID when deciding which cards to attach to.
    It appears that a number of the mpt(4) Fibre Channel cards had a LAN
    variant whose PCI device ID was just one bit off from the FC card's device
    ID.  The FC cards were even and the LAN cards were odd.
    The problem was that this pattern wasn't carried over on the SAS and
    parallel SCSI mpt(4) cards.  Luckily the SAS and parallel SCSI PCI device
    IDs were either even numbers, or they would get masked to a supported
    adjacent PCI device ID, and everything worked well.
    Now LSI is using some of the odd-numbered PCI device IDs between the 3Gb
    SAS device IDs for their new MegaRAID cards.  This is causing the mpt(4)
    driver to attach to the RAID cards instead of the mfi(4) driver.
    The solution is to stop masking off the bottom bit of the device ID, and
    explicitly list the PCI device IDs of all supported cards.
    This change should be a no-op for mpt(4) hardware.  The only intended
    functional change is that for the 929X, the is_fc variable gets set.  It
    wasn't being set previously, but needs to be because the 929X is a Fibre
    Channel card.
    Sascha Wildner committed Mar 20, 2012
Commits on Mar 16, 2012
  1. boot - Fix overflow in CD I/O code

    * Fix an overflow in cdb2devb():
    	from ((bno) * ISO_DEFAULT_BLOCK_SIZE / DEV_BSIZE)
    	to   ((bno) * (ISO_DEFAULT_BLOCK_SIZE / DEV_BSIZE))
    * Adjust several fields from signed -> unsigned
    Matthew Dillon committed Mar 16, 2012
Commits on Mar 14, 2012
  1. ioapic: By default, disable I/O APIC if we are booting on a virtual m…

    I/O APIC causes too much trouble on virtual machines; simply disable
    I/O APIC for virtual machines by default.
    You could always explicitly enable I/O APIC on virtual machines by
    setting tunable hw.ioapic_enable to 1
    Thank swildner@ for hint on virtual machine detection method.
    Reported-by: many
    Sepherosa Ziehau committed Mar 14, 2012
Commits on Mar 13, 2012
Commits on Mar 11, 2012
  1. rc.conf.5: Fix the wlan setup example.

    Submitted-by:  Johannes Hofmann <>
    Dragonfly-bug: <>
    Sascha Wildner committed Mar 11, 2012
  2. <sys/cdefs.h>: For C++, unhide our interfaces via __{BEGIN,END}_DECLS.

    This follows up on a previous (pthread specific) commit by alexh
    (e7322b0) that used a per-proto
    macro. Revert this commit, too. In principle, we do it like NetBSD
    See in the GCC wiki for details
    on the issue.
    This solution was suggested by Martin Husemann in a thread about
    xulrunner building issues:
    Reported-and-tested-by: marino and others
    Sascha Wildner committed Mar 11, 2012
Commits on Mar 10, 2012
  1. svc_vc_create(3): Initialize xprt with NULL.

    In the (corner-)case of being out of memory, this prevents free() to be
    called on an uninitialized xprt below the cleanup_svc_vc_create: label.
    Sascha Wildner committed Mar 10, 2012
Commits on Mar 9, 2012
  1. kernel: fixup accidental whitespace shift in vm_fault_copy_entry commit

    was resulting in cherry-pick conflicts in MFC branch
    Chris Turner committed Mar 9, 2012
  2. kernel: reorganize new holds in vm_fault_copy_entry

    Move holds outside of the pagecopy loop to reduce locking overhead.
    Suggested-by: dillon
    Chris Turner committed Mar 9, 2012
  3. kernel: add missing holds/drops to vm_fault_copy_entry

    Add missing holds/drops to vm_fault_copy_entry that were triggering
    assertions in vm_page_alloc/vm_page_lookup when when a process
    holding locked memory is forked.
    Reviewed-by: vsrinavas
    X-Nahmean-Status: word
    Chris Turner committed Mar 9, 2012
  4. setnetpath(3): Fix a double free().

    np_sessionp is free()'d after the failed: label.
    Sascha Wildner committed Mar 9, 2012
  5. HAMMER VFS: Conditionalize debug message

    * Conditionalize an annoying debug kprintf on hammer_debug_inode.
    Matthew Dillon committed Mar 9, 2012
Commits on Mar 7, 2012
  1. Installer: one more place where inform() called without a format string

    Noticed-by: swildner@
    YONETANI Tomokazu committed with Sascha Wildner Mar 7, 2012
  2. Installer: fix a (possible) crash in show_ifconfig()

    inform() expects a printf-like format string as the second argument,
    so you should always supply one instead of a random string by itself.
    DragonFly-bug: <>
    YONETANI Tomokazu committed with Sascha Wildner Mar 7, 2012
Commits on Mar 5, 2012
  1. ncurses: Fix an almost 7 year old typo in the profiling libtinfo's name.

    It was introduced in c4c23d9.
    Sascha Wildner committed Mar 5, 2012
  2. gcc44: Remove a wrong define for the profiled math library's name.

    This caused compiling with -pg to fail for C++:
    zoot# c++ -pg -o t t.c
    /usr/libexec/binutils222/elf/ld.bfd: cannot find -lm_p
    Our libraries for profiling don't have different names than the normal
    ones. They just are in a different directory (/usr/lib/profile), which
    is cared for.
    Reported-by:   Pierre Abbat <>
    Dragonfly-bug: <>
    Sascha Wildner committed Mar 5, 2012
Commits on Mar 2, 2012
  1. Sync zoneinfo database with tzdata2012b from

    northamerica:   8.52 -> 8.53
    * northamerica: Summer time in Cuba has been delayed 3 weeks (now
        starts April 1 rather than March 11). Since Mar 11 (the old
        start date, as listed in 2012a) is just a little over a week
        away, this change is urgent.
    Also bump's version for a fix that was not in 2012a but
    which I already added.
    Sascha Wildner committed Mar 2, 2012
Commits on Mar 1, 2012
  1. Sync zoneinfo database with tzdata2012a from

    antarctica:     8.9  -> 8.10
    asia:           8.69 -> 8.70
    australasia:    8.29 -> 8.30
    europe:         8.40 -> 8.41
    leapseconds:    8.11 -> 8.13
    northamerica:   8.51 -> 8.52
    README:         8.3  -> 8.4
    southamerica:   8.52 -> 8.53       8.52 -> 8.54
    * antarctica: Current best known timezone info for various Antarctic
        bases for the winter of 2012.
    * asia: Armenia has abolished summer time.
    * australasia: Tokelau copied Samoa and swapped sides of the
        International Date Line last December (affects current timestams).
    * europe: Updated URL for UK timezone history.
    * leapseconds: Bulletin C43 incorporated (a leap Second will occur
        2012-06-30 at 23:59:60 UTC). Bulletin C42 was also incorporated
        (but never released) - it said nothing very interesting (no leap
        second 2011-12-31).
    * northamerica: New zone America/Creston created for an area in
        British Columbia that was previously (and apparently incorrectly)
        considered identical to Dawson Creek. Also, some corrections to
        1918 summer time end dates in several Canadian zones.
    * README: Updated to reflect the current home of the mailing list and
    * southamerica: Chile has extended Summer time in the 2011/2 summer.
        Future years (2013->) are assumed revert to "normal" for now. The
        Falkland Islands now have it permanently (continuing the 2011
        experiment). This "permanently" is a guess, it apparently is
        certain for 2012 (as certain as these things ever are) and
        considered likely into the future.
    * New America/Creston zone added, and a typo in the entry
        for Europe/Samara corrected.
    Sascha Wildner committed Mar 1, 2012
Commits on Feb 28, 2012
  1. libthread_xu/libc_r: Improve the check for EINVAL in sem_* functions.

    Before referencing *sem->... in the check, do not just test if sem is
    NULL but also if *sem is NULL.
    Reported-by: Max Herrgard <>
    Sascha Wildner committed Feb 28, 2012
Commits on Feb 27, 2012
  1. uguru(4): Fix a panic when detaching (e.g., on kldunload).

    Reported-by: Max Herrgard <>
    Sascha Wildner committed Feb 27, 2012
Commits on Feb 19, 2012
  1. x86_64 getmemsize: Recover 0x100000 bytes

    When binutils 2.20 was brought in, the x86_64 kernel built with it loaded
    at 0x200000 instead of 0x100000 as it was previously.  The getmemsize()
    function was never updated with the new address so the physical memory
    between 0x100000 and 0x200000 has been lost since then.
    The hardcoded value has been updated.  In the future, it may be a good
    idea to replace with a variable as FreeBSD has done.
    jrmarino committed Feb 19, 2012
Commits on Feb 18, 2012
  1. Merge remote branch 'crater/DragonFly_RELEASE_3_0' into rel3_0

    Thomas Nikolajsen committed Feb 18, 2012
  2. VFS accounting: optimize vop_write() performance

    * Avoid a mount list scan if accounting is globally disabled
    François Tigeot committed Feb 18, 2012
  3. tmpfs: Support NFS export of tmpfs filesystems.

    * Implement vop_mountctl and MOUNTCTL_SET_EXPORT interfaces to allow mountd
      to export a tmpfs filesystem.
    * Implement vfs_checkexp to allow NFS to function.
    Closes: Bug 2277
    vsrinivas committed with Thomas Nikolajsen Jan 31, 2012
  4. VFS accounting: check if nullfs mp* really exist

    * Nullfs are a clever hack, they forget their mp after mount and let the
      non-nullfs underlying mount point do all the work
    * Nevertheless, we need to get the real struct mount associated to a mount
      point to count the space used by PFSes. We cache it in the vnode.
    * But since the vnode we use really belongs to the lowest underlying
      mount point, the upper-level mp may already have been freed.
    * We need to first check if it still valid; a new function,
      mountlist_exists() now exists for that purpose.
    * Should fix issue #2266
    Francois Tigeot committed with François Tigeot Feb 17, 2012
Commits on Feb 17, 2012
Commits on Feb 16, 2012
  1. kernel: mfs -- Fix unmount panic for MFS filesystems.

    mfs_start() is active for the life of an MFS mount, handling copyin/out
    requests. It is directed to exit when an MFS filesystem is unmounted.
    The VFS accounting code and VFS MPLOCK code assumed that the mountpoint
    structure was stable on return of mfs_start, which was not the case.
    To work around that, don't call acinit if the vfs_start vfsop returns
    EMOUNTEXIT, a kernel-specific pseudo-errno. Also allow marking vfs_start
    MPSAFE and mark mfs vfs_start MPSAFE, to avoid accessing a per-mount
    token field. A future commit will rework MFS's locking so that critical
    sections are not used to protect the MFS bioq.
    This is a hack for MFS; future work should either rework the filesystem
    or replace it outright with tmpfs.
    Closes: Bug 2276
    vsrinivas committed Feb 16, 2012
  2. isp(4): Fix wrong sizeof().

    Sascha Wildner committed Feb 16, 2012
  3. kernel/pci: Implement the PCIOCATTACHED ioctl.

    This fixes pciconf -a
    Taken-from: FreeBSD
    Sascha Wildner committed Feb 14, 2012
Commits on Feb 12, 2012
  1. objformat - Duplicate NELEM() macro

    * Fix buildworld on DragonFly hosts built before Dec 18, 2010 (2.9).
    * NELEM() macro was added to sys/param.h on Dec 18, 2010 and objformat was
      made to use it on May 20, 2011. This broke upgrades for machines running a
      DragonFly version built prior to Dec 18, 2010 since objformat is built with
      the hosts headers as part of the cross tools stage.
    thesjg committed Feb 12, 2012
Commits on Feb 10, 2012
  1. mps(4): Add module version.

    Sascha Wildner committed Feb 8, 2012