9 years agoAdjust the ${ISODIR}/.didbootstrap logic a little, add needed licenses.
Matthew Dillon [Sun, 8 Feb 2009 20:15:52 +0000 (12:15 -0800)]
Adjust the ${ISODIR}/.didbootstrap logic a little, add needed licenses.

Adjust the bootstrap logic a bit and add the following licenses to
the release build's mk.conf so the gui packages all build:  The
openmotif-license and the vim-license.

9 years agoAdd new option to pkg_search
Matthias Schmidt [Sun, 8 Feb 2009 13:01:44 +0000 (14:01 +0100)]
Add new option to pkg_search

-d will download the pkg_summary(5) file for you.  If it is already installed,
it get's overwritten.  This is useful for users using only binary packages.
After a release -d will give you the new list of packages available for that

9 years agoShift link for 2.2
Matthias Schmidt [Sun, 8 Feb 2009 12:04:04 +0000 (13:04 +0100)]
Shift link for 2.2

We already have packages for 2.2 on pkgbox and the mirrors.

9 years agonrelease: Restrict swap size to 8GB for now.
Sascha Wildner [Sun, 8 Feb 2009 15:27:46 +0000 (16:27 +0100)]
nrelease: Restrict swap size to 8GB for now.

9 years agoMerge commit 'chlamydia/master'
Thomas Nikolajsen [Sun, 8 Feb 2009 15:17:47 +0000 (16:17 +0100)]
Merge commit 'chlamydia/master'

9 years agovnconfig: Fix printing of inode
Thomas Nikolajsen [Sun, 8 Feb 2009 14:54:26 +0000 (15:54 +0100)]
vnconfig: Fix printing of inode

9 years agouuids.5: Fix error and improve wording
Thomas Nikolajsen [Sun, 8 Feb 2009 14:41:59 +0000 (15:41 +0100)]
uuids.5: Fix error and improve wording

 * UUID is 128 bit; not 64 bit

9 years agojscan: Fix SYNOPSIS and sync usage()
Thomas Nikolajsen [Sun, 8 Feb 2009 14:36:07 +0000 (15:36 +0100)]
jscan: Fix SYNOPSIS and sync usage()

9 years agodiskinfo: Add description of flags, fix SYNOPSIS and sync usage()
Thomas Nikolajsen [Sun, 8 Feb 2009 14:09:18 +0000 (15:09 +0100)]
diskinfo: Add description of flags, fix SYNOPSIS and sync usage()

9 years agoccdconfig: Improve markup & sync usage()
Thomas Nikolajsen [Sun, 8 Feb 2009 14:04:37 +0000 (15:04 +0100)]
ccdconfig: Improve markup & sync usage()

 * Fix SYNOPSIS: problems in `...' use
 * Sync usage() to SYNOPSIS
 * Add reference to disklabel64(8)
 * Add markup
 * Break long command lines in examples
 * Start sentence on new line

9 years agostrfile.8: Add missing `C' flag to SYNOPSIS.
Thomas Nikolajsen [Sun, 8 Feb 2009 14:03:35 +0000 (15:03 +0100)]
strfile.8: Add missing `C' flag to SYNOPSIS.

9 years agonrelease: Add /tmp to the list of nohistory directories.
Sascha Wildner [Sun, 8 Feb 2009 14:43:33 +0000 (15:43 +0100)]
nrelease: Add /tmp to the list of nohistory directories.

9 years agosh.1: Fix markup.
Thomas Nikolajsen [Sun, 8 Feb 2009 14:01:40 +0000 (15:01 +0100)]
sh.1: Fix markup.

A few ``...'' wasn't marked as arguments.

9 years agoRevert 4dcaa51ba4d4238e035a802067366a28527cd570
Matthias Schmidt [Sun, 8 Feb 2009 10:42:34 +0000 (11:42 +0100)]
Revert 4dcaa51ba4d4238e035a802067366a28527cd570

This reverts the .forward commit.  I committed the code to early, there are some
bugs inside (queue handling broken and some security issues).  I back this out
until we have more time to fix all the issues or rewrite some parts from scratch.

This brings dma back in a fully working state, only the .forward stuff is gone.

Tested-by: Daniel Roethlisberger <daniel@roe.ch> and me
Ok-to-back-out: corecode@

9 years agoMerge branch 'master' of git://chlamydia.fs.ei.tum.de/dragonfly
Matthias Schmidt [Sat, 7 Feb 2009 19:08:05 +0000 (20:08 +0100)]
Merge branch 'master' of git://chlamydia.fs.ei.tum.de/dragonfly

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Sun, 8 Feb 2009 10:12:25 +0000 (02:12 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agonrelease Makefile adjustments: Packages, newaliases, check target, etc
Matthew Dillon [Sun, 8 Feb 2009 10:08:22 +0000 (02:08 -0800)]
nrelease Makefile adjustments: Packages, newaliases, check target, etc

* Add a newaliases step which fixes the aliases.db warning when the CD boots.

* Adjust the DVD package set a bit.  There are still some license issues
  which need to be resolved.

* Fix the check target to detect certain required packages for building
  the ISO.

* Adjust pkgsrc_bootstrap and pkgsrc_cdrecord helper targets

* Remove some stale targets which are no longer used.

9 years agoFix typo.
Thomas Nikolajsen [Sun, 8 Feb 2009 08:04:36 +0000 (09:04 +0100)]
Fix typo.

9 years agoImprove the customizeiso step to allow restarts
Matthew Dillon [Sun, 8 Feb 2009 02:43:39 +0000 (18:43 -0800)]
Improve the customizeiso step to allow restarts

* Use a touch-file to determine if the bootstrap has been built, clean out
  the entire pkg installation if it has not before continuing.  Leave
  things intact if the bootstrap has already been installed.

* Use defensive umounts and rm's as needed to allow the null mounts and
  package building environment to be recreated without destroying packages
  already installed.

* Allow /usr/pkgsrc to be read-only.  If it is read-only then a null-mount
  will be used for /usr/pkgsrc/distfiles pointing to /usr/release/distfiles.

* Add a bmake check step when building each package and only build packages
  which have not already been installed.

9 years agoPolish cdev example
Stathis Kamperis [Fri, 6 Feb 2009 16:33:38 +0000 (16:33 +0000)]
Polish cdev example

- dev_t is cdev_t now
- include stdlib.h needed by exit(3)
- respect the ``80 columns per line'' limit
- comply with KNF

No functional change intended

9 years agopci intr config: 'j' is the pin index we want to skip.
Sepherosa Ziehau [Thu, 5 Feb 2009 10:39:05 +0000 (18:39 +0800)]
pci intr config: 'j' is the pin index we want to skip.

9 years agopci intr config: Fix an off by one bug
Sepherosa Ziehau [Wed, 4 Feb 2009 10:39:27 +0000 (18:39 +0800)]
pci intr config: Fix an off by one bug

FreeBSD pci_pir.c rev1.105
  We represent PCI intpin's two different ways.  One is the way that the
  intpin register is expressed in hardware where 0 means none, 1 means INTA,
  2 INTB, etc.  The other way is commonly used in loops where 0 means INTA,
  1 means INTB, etc.  The matchpin argument to pci_cfgintr_search() is
  supposed to be the first form, but we passsed in a loop index of the
  second.  This fix adds one to the loop index to convert to the first form.

  Reported by: Pavlin Radoslavov <pavlin@icir.org>

9 years agoMerge branch 'master' of git://chlamydia.fs.ei.tum.de/dragonfly
Aggelos Economopoulos [Thu, 5 Feb 2009 22:33:00 +0000 (00:33 +0200)]
Merge branch 'master' of git://chlamydia.fs.ei.tum.de/dragonfly

9 years agokill db_print_backtrace()
Aggelos Economopoulos [Thu, 5 Feb 2009 22:27:34 +0000 (00:27 +0200)]
kill db_print_backtrace()

Use print_backtrace() which is always available. Remove
a bunch of #ifdef DDB and #include <ddb/ddb.h> lines.

9 years agoinstaller: Use unsigned long for holding hw.physmem's value.
Sascha Wildner [Thu, 5 Feb 2009 22:21:18 +0000 (23:21 +0100)]
installer: Use unsigned long for holding hw.physmem's value.

The previous signed long led to the wrong calculation of default swap size
on machines with >2GB main memory.

Reported-by: corecode
Dragonfly-bug: <http://bugs.dragonflybsd.org/issue1257>

9 years agonrelease: Whitespace.
Sascha Wildner [Thu, 5 Feb 2009 11:38:45 +0000 (12:38 +0100)]
nrelease: Whitespace.

9 years agonrelease: Re-add cvsup package URL which I accidentally removed.
Sascha Wildner [Thu, 5 Feb 2009 11:37:47 +0000 (12:37 +0100)]
nrelease: Re-add cvsup package URL which I accidentally removed.

9 years agotcsh: export PATH if using the default setting
Simon Schubert [Thu, 5 Feb 2009 09:55:24 +0000 (10:55 +0100)]
tcsh: export PATH if using the default setting

9 years agodefine _PATH_DEFPATH to be reasonable, including sbins and /usr/pkg
Simon Schubert [Thu, 5 Feb 2009 09:37:45 +0000 (10:37 +0100)]
define _PATH_DEFPATH to be reasonable, including sbins and /usr/pkg

sh already had this path set as default, but only sh.  Now everybody
using _PATH_DEFPATH will get the right thing.

9 years agosh: export the default PATH instead of keeping it private
Simon Schubert [Thu, 5 Feb 2009 09:34:50 +0000 (10:34 +0100)]
sh: export the default PATH instead of keeping it private

sh specifies a default setting for PATH if none is set in the
environment, but up to now it didn't export this setting.  This leads to
strange effects, like sh being able to execute binaries in /usr/sbin,
but which(1) not being able to find them.  Export PATH to create more
symmetry and harmony.

9 years agosh: use _PATH_DEFPATH instead of hand-rolling the default path
Simon Schubert [Thu, 5 Feb 2009 09:33:55 +0000 (10:33 +0100)]
sh: use _PATH_DEFPATH instead of hand-rolling the default path

9 years agoMFC FreeBSD/1.49 - fix misuse of system() and failure if /usr is not mounted.
Matthew Dillon [Thu, 5 Feb 2009 06:19:42 +0000 (22:19 -0800)]
MFC FreeBSD/1.49 - fix misuse of system() and failure if /usr is not mounted.

Suggested-by: Jeremy Chadwick <jdc@parodius.com>
9 years agoRelease Engineering: Add ds macros for 2.2 and 2.3.
Matthew Dillon [Thu, 5 Feb 2009 05:20:49 +0000 (21:20 -0800)]
Release Engineering: Add ds macros for 2.2 and 2.3.

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Thu, 5 Feb 2009 05:04:04 +0000 (21:04 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoRelease Engineering: Update master to 2.3.0-DEVELOPMENT v2.3.0
Matthew Dillon [Thu, 5 Feb 2009 05:03:11 +0000 (21:03 -0800)]
Release Engineering: Update master to 2.3.0-DEVELOPMENT

9 years agonrelease: prevent leaking of env vars into pkgsrc build
Simon Schubert [Wed, 4 Feb 2009 22:17:54 +0000 (23:17 +0100)]
nrelease: prevent leaking of env vars into pkgsrc build

At least TARGET_ARCH, which is used by the release build, is causing
havoc for packages built by gmake, as gmake appends ${TARGET_ARCH} to
the ${COMPILE.c} compiler command line.
To be on the safe side, clear the environment completely when calling
into the pkgsrc build.

9 years agonrelease: Limit the volid to 32 chars, when building from a dirty state.
Sascha Wildner [Wed, 4 Feb 2009 22:10:47 +0000 (23:10 +0100)]
nrelease: Limit the volid to 32 chars, when building from a dirty state.

9 years agomount(8): Start sentence on new line.
Sascha Wildner [Tue, 3 Feb 2009 22:06:00 +0000 (23:06 +0100)]
mount(8): Start sentence on new line.

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Tue, 3 Feb 2009 21:58:12 +0000 (13:58 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoSuppress warnings if /etc/fstab is missing when generating output for
Matthew Dillon [Tue, 3 Feb 2009 21:53:54 +0000 (13:53 -0800)]
Suppress warnings if /etc/fstab is missing when generating output for
mount -p.  Generate reasonable defaults to fill in missing pieces.

Submitted-by: Stathis Kamperis <ekamperi@gmail.com> added the comment:
9 years agoGENERIC: replace tab with space to line up even when commenting out
Simon Schubert [Fri, 30 Jan 2009 15:15:44 +0000 (15:15 +0000)]
GENERIC: replace tab with space to line up even when commenting out

9 years agoAdd a vcount(9) manual page.
Sascha Wildner [Tue, 3 Feb 2009 17:24:48 +0000 (18:24 +0100)]
Add a vcount(9) manual page.

Submitted-by: Stathis Kamperis <ekamperi@gmail.com>
Dragonfly-bug: <http://bugs.dragonflybsd.org/issue1266>

9 years agoSilence 3 warnings in libc.
Sascha Wildner [Tue, 3 Feb 2009 08:26:17 +0000 (09:26 +0100)]
Silence 3 warnings in libc.

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Sun, 1 Feb 2009 08:38:23 +0000 (00:38 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoComment out the session line for PAM's xdm config. This works around
Matthew Dillon [Sun, 1 Feb 2009 08:28:30 +0000 (00:28 -0800)]
Comment out the session line for PAM's xdm config.  This works around
a widely known bug in xdm where a PAM callback can cause xdm to access
a bogus widget pointer after the widget has been destroyed.

With-help-from: Sephe

9 years agoMake XPT_SCSI_IO path quiet again.
Hasso Tepper [Sun, 1 Feb 2009 07:33:12 +0000 (09:33 +0200)]
Make XPT_SCSI_IO path quiet again.

Now when problems with SATA ATAPI devices are resolved, it's not
helpful any more.

9 years agoHAMMER VFS - Fix I/O invalidation collision assertion
Matthew Dillon [Sun, 1 Feb 2009 06:53:38 +0000 (22:53 -0800)]
HAMMER VFS - Fix I/O invalidation collision assertion

Fix more issues with the hammer_reserve subsystem.

* Fix a broken base_offset calculation which had reversed the zone
  and offset fields in a HAMMER_ZONE_ENCODE() call.  The broken
  base_offset caused hammer_del_buffers() to scan the wrong offset
  range, leaving conflicting buffer cache buffers intact.

  The resulting conflict caused a KKASSERT(LIST_FIRST(&bp->b_dep) == NULL)
  to fail later on.

* Hold a reference through a potentially blocking operation in

* Record the proper zone in a hammer_reserve() structure created via
  hammer_blockmap_free().  Without this the I/O invalidation code
  cannot locate conflicting hammer_buffer structures.

* hammer_reserve_setdelay_offset() was not actually placing the
  hammer_reserve() structure in the delay queue, allowing it to
  be disposed of too early.

9 years agomake(1) tests: Remove remaining CVS IDs from the tests to make them run again.
Sascha Wildner [Sat, 31 Jan 2009 23:35:38 +0000 (00:35 +0100)]
make(1) tests: Remove remaining CVS IDs from the tests to make them run again.

9 years agoRemove some unexpanded $DragonFly$ IDs in our tree.
Sascha Wildner [Sat, 31 Jan 2009 22:57:25 +0000 (23:57 +0100)]
Remove some unexpanded $DragonFly$ IDs in our tree.

9 years agomake(1) tests: Messing with the CVS ID is no longer needed.
Sascha Wildner [Sat, 31 Jan 2009 22:51:37 +0000 (23:51 +0100)]
make(1) tests: Messing with the CVS ID is no longer needed.

9 years agorpc_svc_calls(3): Remove __svc_getcallercreds() documentation.
Sascha Wildner [Sat, 31 Jan 2009 22:13:20 +0000 (23:13 +0100)]
rpc_svc_calls(3): Remove __svc_getcallercreds() documentation.

FreeBSD removed the macro but forgot to adjust the manpage.

9 years agomake.conf: Bring back WARNS_WERROR to build with -Werror if WARNS is set.
Sascha Wildner [Sat, 31 Jan 2009 21:06:42 +0000 (22:06 +0100)]
make.conf: Bring back WARNS_WERROR to build with -Werror if WARNS is set.

In-discussion-with: pavalos

9 years agoTypo fixing round.
Sascha Wildner [Sat, 31 Jan 2009 18:41:02 +0000 (19:41 +0100)]
Typo fixing round.

9 years agoinstaller: Fix reading disk descriptions when booting verbose.
Sascha Wildner [Sat, 31 Jan 2009 13:05:39 +0000 (14:05 +0100)]
installer: Fix reading disk descriptions when booting verbose.

This fixes issue1256.

Reported-by: corecode
9 years agoinstaller: Remove .gitignore files.
Sascha Wildner [Sat, 31 Jan 2009 07:21:16 +0000 (08:21 +0100)]
installer: Remove .gitignore files.

9 years agomanpages: Split DIAGNOSTICS into EXIT STATUS and DIAGNOSTICS.
Sascha Wildner [Sat, 31 Jan 2009 09:17:02 +0000 (10:17 +0100)]

DIAGNOSTICS shall have information about diagnostic messages while
exit code information (.Ex macro) goes to EXIT STATUS.

Inspired-by: FreeBSD
9 years agopriv(9): We don't have prison_priv_check() yet so comment out some things.
Sascha Wildner [Sat, 31 Jan 2009 08:17:04 +0000 (09:17 +0100)]
priv(9): We don't have prison_priv_check() yet so comment out some things.

9 years agosyncache_socket(): fix abort path by calling pru_abort directly
Sepherosa Ziehau [Thu, 22 Jan 2009 09:13:20 +0000 (17:13 +0800)]
syncache_socket(): fix abort path by calling pru_abort directly

On syncache_socket() abort path, the inp's {fport,lport,faddr,laddr}
is either incomplete or half destroyed, which causes tcp_soport()
mapping the socket to a wrong CPU.  However, in syncache code, inp
is only accessed or created by its owner CPU, i.e. we are already on
the inp's owner CPU during the socket aborting.

Add soabort_oncpu(), which calls pru_abort directly.  Use it on
syncache_socket() abort path.

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Fri, 30 Jan 2009 17:05:17 +0000 (09:05 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoFix a string parsing bug when trying to run hammer pfs-master on a
Matthew Dillon [Fri, 30 Jan 2009 16:46:38 +0000 (08:46 -0800)]
Fix a string parsing bug when trying to run hammer pfs-master on a
subdirectory of the root directory, e.g. "hammer pfs-master /fubar".

Reported-by: "Simon 'corecode' Schubert" <corecode@fs.ei.tum.de>
9 years agoPut the repo version in the ISO's volid.
Sascha Wildner [Fri, 30 Jan 2009 09:51:12 +0000 (10:51 +0100)]
Put the repo version in the ISO's volid.

9 years agonrelease: Use a separate workdir to keep PKGSRC_PATH clean.
Sascha Wildner [Fri, 30 Jan 2009 08:44:30 +0000 (09:44 +0100)]
nrelease: Use a separate workdir to keep PKGSRC_PATH clean.

9 years agoFix capital letter in the middle of a sentence.
Peter Avalos [Fri, 30 Jan 2009 03:06:11 +0000 (19:06 -0800)]
Fix capital letter in the middle of a sentence.

Submitted-by: Stathis Kamperis <ekamperi@gmail.com>
9 years agojail(8): Fix path in the example.
Sascha Wildner [Thu, 29 Jan 2009 21:58:11 +0000 (22:58 +0100)]
jail(8): Fix path in the example.

9 years agousbhid(3): Re-commit some fixes that were undone in the FreeBSD sync.
Sascha Wildner [Thu, 29 Jan 2009 18:57:06 +0000 (19:57 +0100)]
usbhid(3): Re-commit some fixes that were undone in the FreeBSD sync.

9 years agocvs: obey read only fs setting also for the val-tags file
Simon 'corecode' Schubert [Thu, 29 Jan 2009 18:21:03 +0000 (18:21 +0000)]
cvs: obey read only fs setting also for the val-tags file

9 years agonata: process interrupt even if busmaster active bit is set
Simon Schubert [Thu, 29 Jan 2009 09:34:03 +0000 (10:34 +0100)]
nata: process interrupt even if busmaster active bit is set

The nata driver previously assumed that an interrupt which has the
interrupt and active bits set in the busmaster status register is not a
valid/completed interrupt.  In these situations if would return without
acknowledging the irq, leading to an interrupt livelock situation.

This condition of INTERRUPT|ACTIVE occured on two different machines
both equipped with different versions of an ICH SATA controller, when
accessing an attached SATA ATAPI (DVD) drive by TSScorp (Samsung
OEM/bulk).  Specifically, natapicam seems to trigger this condition on
attach.  It seems that the drive is unhappy with the INQUIRY command
sent by natapicam.  Related artifacts appear when trying to access a
video DVD (possibly due to missing region/css key).

Under the hood it seems that the drive reports an error condition
(visible in the ALT/STATUS register), but does not clear the ACTIVE bit
of the busmaster status.  As a result the nata driver could be waiting
for the completion of the transfer, while the SATA busmaster would keep
the interrupt line asserted.

We work around this issue by following the precedent of other operating
systems and ignoring the ACTIVE bit if the INTERRUPT bit is set.
Specifically, we wait a little bit to accomodate for possibly faulty
hardware which might assert the irq before the transfer is completely
finished.  Nevertheless, we do not reject interrupt proecessing if the
INTERRUPT bit is set in the busmaster status register.

9 years agonrelease: Switch to building pkgsrc packages from source.
Sascha Wildner [Thu, 29 Jan 2009 06:22:24 +0000 (07:22 +0100)]
nrelease: Switch to building pkgsrc packages from source.

The pkgsrc tree that shall be used must be specified via PKGSRC_PATH.

So far the LiveCD build has been successfully tested. The LiveDVD might
still need some love, but I'm committing this now so work on the release
can begin.

Still on the TODO is using binary packages optionally.

Requested-by: dillon
9 years agoFix format order.
Sascha Wildner [Wed, 28 Jan 2009 19:47:34 +0000 (20:47 +0100)]
Fix format order.

Reported-by: corecode
9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Tue, 27 Jan 2009 01:36:19 +0000 (17:36 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoHAMMER VFS - Add missing bqrelse() in last patch.
Matthew Dillon [Tue, 27 Jan 2009 01:35:34 +0000 (17:35 -0800)]
HAMMER VFS - Add missing bqrelse() in last patch.

This fixes a deadlock introduced by the last patch due to a missing
bqrelse() call.

9 years agoRevert "Update the atime when mmap'ing a file"
Simon Schubert [Fri, 23 Jan 2009 00:23:27 +0000 (01:23 +0100)]
Revert "Update the atime when mmap'ing a file"

This reverts commit 8e7ceff7f24f4bd5eae767c8c091e696d490dd58.

Better code committed in a6e41612e54fa7b0a616c8f8d14446bab206d030

9 years agohda: disable verbose output - too chatty even for bootverbose
Simon Schubert [Fri, 23 Jan 2009 00:22:25 +0000 (01:22 +0100)]
hda: disable verbose output - too chatty even for bootverbose

9 years agonata: revert 6e40a325 = don't use tsleep in ata_udelay
Simon Schubert [Thu, 22 Jan 2009 20:40:53 +0000 (21:40 +0100)]
nata: revert 6e40a325 = don't use tsleep in ata_udelay

ata_udelay might be called from softclock context due to a request
timeout.  However we must not tsleep in softclock.  This restores the
pre-6e40a325 behavior.

9 years agoHAMMER VFS - Reorganize the use of hammer_del_buffers(), fix rare deadlocks
Matthew Dillon [Mon, 26 Jan 2009 06:34:42 +0000 (22:34 -0800)]
HAMMER VFS - Reorganize the use of hammer_del_buffers(), fix rare deadlocks

The previous attempt at fixing a deadlock due to a hammer_buffer being
held cached across long-blocking procedures failed to catch all cases.
Implement a more complete and less invasive fix.  These buffers are
typically held in the hammer_cursor structure.

Instead of trying to release such cached data buffers proactively,
we instead allow hammer_del_buffers() to return a temporary failure when
called from the reservation code.  If hammer_del_buffers() is unable to
completely eradicate underlying buffers due to them being referenced via
the above cache entities the related hammer_reserve structure is simply
re-added to the delayed-release queue.

The related big-block are thus not reused until all such cached entites
have been dereferenced.  The relaxed requirements on the cached entities
removes the possibility of a deadlock in the invalidation code and also
simplifies hammer_io_inval()'s handling of the hammer_buffer<->buffer_cache
coupling case.

9 years agoHAMMER VFS - clean out cached data_buffer on unlock cursor to avoid deadlock
Matthew Dillon [Sun, 25 Jan 2009 21:11:14 +0000 (13:11 -0800)]
HAMMER VFS - clean out cached data_buffer on unlock cursor to avoid deadlock

Clean out any cached cursor->data_buffer when unlocking a cursor.  The
underlying buffer cache buffer could become stale and if we do not release
our hammer_buffer reference on it other threads may deadlock trying to
getblk() the buffer cache buffer in order to invalidate it.

9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Sun, 25 Jan 2009 07:19:42 +0000 (23:19 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoFix another process stuck-during-exit bug - stuck due to signal.
Matthew Dillon [Sun, 25 Jan 2009 07:13:46 +0000 (23:13 -0800)]
Fix another process stuck-during-exit bug - stuck due to signal.

Fix a bug where an exiting process becomes a zombie, entering the SZOMB
state, but then receives a stop signal before it can be reaped.  If this
occurs the process was incorrectly placed in SSTOP and then later made
SACTIVE again, preventing it from being reaped.

Symptoms were: process shows up in ps in a DEL state but does not show
up in kgdb's 'info thread' list.  Process is the zombie list and is still
a child of init, but it's state is SACTIVE instead of SZOMB and p_xstat
(last signal taken) is SIGSTOP or SIGTSTP.

9 years agoHAMMER VFS - Fix deadlock in rmdir
Matthew Dillon [Sun, 25 Jan 2009 07:08:46 +0000 (23:08 -0800)]
HAMMER VFS - Fix deadlock in rmdir

hammer_vop_rmdir() maintains a cursor at the directory entry being deleted,
and then calls hammer_ip_check_directory_empty() to check if the directory
is empty.  The check code creates a second, nested cursor.

Any locks on the first cursor must be released in order to allow the
function to block while scanning the second cursor to avoid possible

9 years agoAutomatically install required missing pam configurations in upgrade.
Peter Avalos [Sat, 24 Jan 2009 21:21:20 +0000 (16:21 -0500)]
Automatically install required missing pam configurations in upgrade.

Additionally, warn users that the config files may be out-of-date.  99%
of the time, it's probably best for the user to just do the make install
in etc/pam.d to install the default configuration files.

Reviewed-by: dillon
9 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Sat, 24 Jan 2009 20:22:01 +0000 (12:22 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

9 years agoHAMMER VFS - Remove the unused also_ip argument from the cursor API
Matthew Dillon [Sat, 24 Jan 2009 19:49:34 +0000 (11:49 -0800)]
HAMMER VFS - Remove the unused also_ip argument from the cursor API

9 years agoMerge branch 'vendor/GDTOA'
Peter Avalos [Sat, 24 Jan 2009 17:06:28 +0000 (12:06 -0500)]
Merge branch 'vendor/GDTOA'

9 years agoImport gdtoa-20081205.
Peter Avalos [Mon, 19 Jan 2009 17:28:24 +0000 (12:28 -0500)]
Import gdtoa-20081205.

Note: This will not be connected to the build until after the 2.2

9 years agoloader(8): hw.usb.hack_defer_exploration's default value is 1.
Sascha Wildner [Sat, 24 Jan 2009 12:30:21 +0000 (13:30 +0100)]
loader(8): hw.usb.hack_defer_exploration's default value is 1.

10 years agoRemove Asia/Katmandu upon 'make upgrade'.
Sascha Wildner [Fri, 23 Jan 2009 14:37:03 +0000 (15:37 +0100)]
Remove Asia/Katmandu upon 'make upgrade'.

10 years agoUse .Fx.
Sascha Wildner [Thu, 22 Jan 2009 12:56:37 +0000 (13:56 +0100)]
Use .Fx.

10 years agoComment out function which we don't have.
Sascha Wildner [Thu, 22 Jan 2009 12:55:42 +0000 (13:55 +0100)]
Comment out function which we don't have.

10 years agolpr: don't rely on dirs having st_size > 0
Simon Schubert [Thu, 22 Jan 2009 10:19:21 +0000 (11:19 +0100)]
lpr: don't rely on dirs having st_size > 0

getq determines the initial size of its queue array based on the st_size
of the queue directory.  If the queue directory is on a HAMMER file
system, this size will be reported as 0.  However the following array
growing logic just doubles the array size, thus always staying at 0.

Use a sensible minimum array size of 20 items (~ 512/24).

Reported-and-fix-by: Patrick Georgi <patrick@georgi-clan.de>
10 years agoudf: Remove NULL dereference.
Sascha Wildner [Wed, 21 Jan 2009 21:25:12 +0000 (22:25 +0100)]
udf: Remove NULL dereference.

Even if the conditional wasn't wrong, it would be pointless, because
udfmp->hashtbl is already initialized by phashinit() in udf_mountfs().

Found-by: LLVM/Clang Static Analyzer
10 years agoBring in some fixes from tzdata2009a from elsie.
Sascha Wildner [Wed, 21 Jan 2009 19:15:34 +0000 (20:15 +0100)]
Bring in some fixes from tzdata2009a from elsie.

* strftime.c - c format warning fix

* zdump.c    - fix infinite loop caused by overflow/optimization interaction

10 years agoSync zoneinfo database with tzdata2009a from elsie.
Sascha Wildner [Wed, 21 Jan 2009 19:12:52 +0000 (20:12 +0100)]
Sync zoneinfo database with tzdata2009a from elsie.

asia:           8.24 -> 8.25
backward:       8.6  -> 8.7
europe:         8.18 -> 8.20
northamerica:   8.24 -> 8.26
zone.tab:       8.21 -> 8.26

From Arthur David Olson's comments:

* asia         - change Katmandu to Kathmandu

* backward     - provide Katmandu link

* europe       - correct Swiss rules

* northamerica - clearer definition of Cuban transitions (no binary change)
               - Resolute changes abbreviation (but not time) twice a year

* zone.tab     - Change Katmandu to Kathmandu
               - Change Resolute from Eastern Time to Eastern Standard Time

10 years agoIssue 1013 - Update atime on exec, fix bug in last commit.
Matthew Dillon [Wed, 21 Jan 2009 16:52:04 +0000 (08:52 -0800)]
Issue 1013 - Update atime on exec, fix bug in last commit.

The call from the mmap code assumed that 'handle' was a vnode.  It is not
necessarily a vnode.  Use 'vp' instead.

Reported-by: Sepherosa Ziehau <sepherosa@gmail.com>
10 years agoIssue 1013 - update atime on exec and mmap, add helper vop_markatime
Matthew Dillon [Wed, 21 Jan 2009 01:39:51 +0000 (17:39 -0800)]
Issue 1013 - update atime on exec and mmap, add helper vop_markatime

Add a new helper VOP which passively updates a vnode's atime.  Implement
the new VOP in HAMMER and UFS and create a default op which does nothing.
Call the new function from mmap() and exec().

Submitted-by: Dion Blazakis
Reported-by: Simon Schubert
10 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Matthew Dillon [Tue, 20 Jan 2009 17:59:18 +0000 (09:59 -0800)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

10 years agoHAMMER utility - Use a full path to /sbin/mount instead of relying on PATH
Matthew Dillon [Tue, 20 Jan 2009 17:58:48 +0000 (09:58 -0800)]
HAMMER utility - Use a full path to /sbin/mount instead of relying on PATH

10 years agoRemove GEMDOS support.
Hasso Tepper [Sat, 3 Jan 2009 00:58:57 +0000 (02:58 +0200)]
Remove GEMDOS support.

10 years agoRemove checks for BOOTSIG[23] from FAT32 bootblocks.
Hasso Tepper [Sat, 3 Jan 2009 00:51:38 +0000 (02:51 +0200)]
Remove checks for BOOTSIG[23] from FAT32 bootblocks.

There seems to be very little documentary evidence outside this
implementation to suggest a these checks are neccessary, and more
than one camera-formatted flash disk fails the check, but mounts
successfully on most other systems.

Obtained-from: FreeBSD

10 years agoDon't check pm_Heads nor pm_SecPerTrack.
Hasso Tepper [Fri, 2 Jan 2009 22:05:03 +0000 (00:05 +0200)]
Don't check pm_Heads nor pm_SecPerTrack.

These might be 0 and aren't used anyway. Makes some "god knows where
formatted" usb sticks work here.

Obtained-from: FreeBSD

10 years agoMake "route add <gw>" where X > 0 work again.
Hasso Tepper [Sun, 18 Jan 2009 13:21:45 +0000 (15:21 +0200)]
Make "route add <gw>" where X > 0 work again.