]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
13 years agoIn r219639, SSSE3 instruction set support was backported to our gcc.
dim [Thu, 14 Apr 2011 16:45:16 +0000 (16:45 +0000)]
In r219639, SSSE3 instruction set support was backported to our gcc.

Therefore, we also need to install the new tmmintrin.h header containing
the related intrinsic functions, similar to xmmintrin.h, emmintrin.h,
etc.

Reported by: George Liaskos <geo.liaskos@gmail.com>

13 years agoConsistently use __volatile as the rest of this file.
jkim [Thu, 14 Apr 2011 16:19:41 +0000 (16:19 +0000)]
Consistently use __volatile as the rest of this file.

13 years agoPrefer C99 standard integers to reduce diff from i386 version.
jkim [Thu, 14 Apr 2011 16:14:35 +0000 (16:14 +0000)]
Prefer C99 standard integers to reduce diff from i386 version.

13 years agoConsistently use C99 standard integers as the rest of this file.
jkim [Thu, 14 Apr 2011 16:02:52 +0000 (16:02 +0000)]
Consistently use C99 standard integers as the rest of this file.

13 years agoProvide a (belated) UPDATING note related to the new release-building
nwhitehorn [Thu, 14 Apr 2011 15:44:44 +0000 (15:44 +0000)]
Provide a (belated) UPDATING note related to the new release-building
process so that fewer people will be caught unaware.

Requested by: emaste

13 years agoAdd $FreeBSD$'s.
obrien [Thu, 14 Apr 2011 15:42:15 +0000 (15:42 +0000)]
Add $FreeBSD$'s.

13 years agoRevert r194662, since it breaks ng_ksocket(4) and may break
glebius [Thu, 14 Apr 2011 14:54:22 +0000 (14:54 +0000)]
Revert r194662, since it breaks ng_ksocket(4) and may break
other socket consumers with alternate sb_upcall.

PR: kern/154676
Submitted by: Arnaud Lacombe <lacombar gmail.com>
MFC after: 7 days

13 years agoRemove stale M_ZOMBIE malloc type.
pluknet [Thu, 14 Apr 2011 14:25:47 +0000 (14:25 +0000)]
Remove stale M_ZOMBIE malloc type.
This type is unused since embedding p_ru into struct proc.

MFC after: 1 week

13 years agoRefactor udp_input(), moving calls to u_tun_func() into udp_append().
trasz [Thu, 14 Apr 2011 10:40:57 +0000 (10:40 +0000)]
Refactor udp_input(), moving calls to u_tun_func() into udp_append().

Obtained from: Wheel Systems Sp. z o.o.
Reviewed by: bz@

13 years agoThe mbuf_frag_size always was and is file local and not queried from base
bz [Thu, 14 Apr 2011 09:47:09 +0000 (09:47 +0000)]
The mbuf_frag_size always was and is file local and not queried from base
user space tools via kvm.  Mark it static.

MFC after: 3 days

13 years agoFix typo in write_cache tunable name and move TUNABLE_INT_FETCH() out of
mav [Thu, 14 Apr 2011 09:11:50 +0000 (09:11 +0000)]
Fix typo in write_cache tunable name and move TUNABLE_INT_FETCH() out of
the SIM lock to fix WITNESS warning.

Reported by: jh

13 years agoRemove vestiges of disklabel(5).
pluknet [Thu, 14 Apr 2011 08:53:04 +0000 (08:53 +0000)]
Remove vestiges of disklabel(5).

Reviewed by: uqs
MFC after: 5 days

13 years agoProperly log few more ATA commands used by the kernel.
mav [Thu, 14 Apr 2011 08:17:45 +0000 (08:17 +0000)]
Properly log few more ATA commands used by the kernel.

13 years agoRefactor hard-reset implementation in mvs(4).
mav [Thu, 14 Apr 2011 07:49:45 +0000 (07:49 +0000)]
Refactor hard-reset implementation in mvs(4).

Instead of spinning in a tight loop for up to 15 seconds, polling for device
readiness while it spins up, return reset completion just after PHY reports
"connect well" or 100ms connection timeout. If device was found, use callout
for checking device readiness with 100ms period up to full 31 second timeout.

This fixes system freeze for 5-10 seconds on drives hot plug-in.

13 years agoFixed firmware revision decoding:
ru [Thu, 14 Apr 2011 07:14:22 +0000 (07:14 +0000)]
Fixed firmware revision decoding:
- the major is 7-bit binary encoded
- the minor is BCD encoded

PR: kern/151586
MFC after: 3 days

13 years agoAdd some tunable descriptions about x86 timers.
jkim [Thu, 14 Apr 2011 00:07:08 +0000 (00:07 +0000)]
Add some tunable descriptions about x86 timers.

Requested by: arundel

13 years agoAdd VOP_PATHCONF() support to the experimental NFS client
rmacklem [Wed, 13 Apr 2011 22:37:28 +0000 (22:37 +0000)]
Add VOP_PATHCONF() support to the experimental NFS client
so that it can, along with other things, report whether or
not NFS4 ACLs are supported.

MFC after: 2 weeks

13 years agoFix the experimental NFSv4 client so that it recognizes server
rmacklem [Wed, 13 Apr 2011 22:16:52 +0000 (22:16 +0000)]
Fix the experimental NFSv4 client so that it recognizes server
mount point crossings correctly. It was testing the wrong flag.
Also, try harder to make sure that the fsid is different than
the one assigned to the client mount point, by hashing the
server's fsid (just to create a different value deterministically)
when it is the same.

MFC after: 2 weeks

13 years agoAdd a new DDB command, "show rmans", which will show the address and brief
gavin [Wed, 13 Apr 2011 19:10:56 +0000 (19:10 +0000)]
Add a new DDB command, "show rmans", which will show the address and brief
details of each rman header, but not the contents of all rman structures
in the system.  This is especially useful on platforms where some rmans
have many thousands of entries in rmans, making scrolling through the
output of "show all rman" impractical.  Individual rmans can then be viewed
including their contents with "show rman 0xaddr" as usual.

Reviewed by: jhb

13 years agoRemove mii(4) dependency and unneeded headers.
yongari [Wed, 13 Apr 2011 16:35:43 +0000 (16:35 +0000)]
Remove mii(4) dependency and unneeded headers.

Reviewed by: davidch

13 years agoImprove SATA Asynchronous Notification feature support in CAM:
mav [Wed, 13 Apr 2011 16:20:54 +0000 (16:20 +0000)]
Improve SATA Asynchronous Notification feature support in CAM:
 - make SATA SIMs announce capabilities to handle SDB with Notification bit;
 - make PMP driver honor this SIMs capability;
 - make SATA XPT to negotiate and enable this feature for ATAPI devices.

This feature allows supporting SATA ATAPI devices to inform system about
some events happened, that may require attention. In my case this allows
LG GH22LS50 SATA DVR-RW drive to report tray open/close events. Events
reported to CAM in form of AC_SCSI_AEN async. Further they could be used
as a hints for checking device status and reporting media change to upper
layers, for example, via spoiling mechanism of GEOM.

13 years agoAdd in the AR9285 (Kite) diversity to if_ath, enabling TX/RX antenna
adrian [Wed, 13 Apr 2011 15:17:23 +0000 (15:17 +0000)]
Add in the AR9285 (Kite) diversity to if_ath, enabling TX/RX antenna
diversity.

This is bit dirty and likely should be revised at a later date,
with an eye to unifying/tidying up the whole diversity setup
and allowing developers to do "tricky stuff" as they desire.
For now, this works.

13 years agoAdd in the last bit of the HAL support for Kite diversity.
adrian [Wed, 13 Apr 2011 15:12:48 +0000 (15:12 +0000)]
Add in the last bit of the HAL support for Kite diversity.

* add a new method, specifically for doing per-RX packet
  antenna diversity
* set that HAL method only if it's Kite and a Kite chip that
  does diversity.

13 years agoMore kite diversity related changes.
adrian [Wed, 13 Apr 2011 15:08:51 +0000 (15:08 +0000)]
More kite diversity related changes.

* add a diversity flag to the HAL debugging section
* add a check to make sure the kite diversity code doesn't run
  on boards that don't require it, as not all Kite chips will
  implement it.
* add some debug statements when the diversity code makes
  changes to the antenna diversity/combining setup.

13 years agoChange this to be less noisy.
adrian [Wed, 13 Apr 2011 14:51:07 +0000 (14:51 +0000)]
Change this to be less noisy.

13 years agoMake sure that extra threads in 32-bit processes stay in 32-bit mode. This
nwhitehorn [Wed, 13 Apr 2011 13:24:27 +0000 (13:24 +0000)]
Make sure that extra threads in 32-bit processes stay in 32-bit mode. This
fixes operation of threaded 32-bit binaries on 64-bit kernels.

13 years agoShow client's access cache statistics.
ru [Wed, 13 Apr 2011 13:05:48 +0000 (13:05 +0000)]
Show client's access cache statistics.

13 years ago- Fixed nfs_printf() to use vprintf().
ru [Wed, 13 Apr 2011 12:46:25 +0000 (12:46 +0000)]
- Fixed nfs_printf() to use vprintf().
- Fixed vfs.nfs.acdebug sysctl's description.
- Fixed panic when compiled with NFS_ACDEBUG.

MFC after: 3 days

13 years agoRemove the now defunct kern.ipc.nmbufs tunable.
pluknet [Wed, 13 Apr 2011 12:19:03 +0000 (12:19 +0000)]
Remove the now defunct kern.ipc.nmbufs tunable.

PR: kern/132497 (part)
MFC after: 1 week

13 years agoBring over the antenna diversity logic support for Kite.
adrian [Wed, 13 Apr 2011 11:32:15 +0000 (11:32 +0000)]
Bring over the antenna diversity logic support for Kite.

Again, this is just the code ported from ath9k and included in the build,
it isn't yet enabled.

13 years agoStaticize malloc types.
pluknet [Wed, 13 Apr 2011 11:28:46 +0000 (11:28 +0000)]
Staticize malloc types.

Approved by: lstewart
MFC after: 1 week

13 years agoAs soon as siis_reset() doesn't waits for device readiness, but only for
mav [Wed, 13 Apr 2011 06:36:22 +0000 (06:36 +0000)]
As soon as siis_reset() doesn't waits for device readiness, but only for
controller port readiness (that should set just after PHY ready signal),
reduce wait time from 10s to 1s before trying more aggressive reset method.

This should improve system responsibility in some failure conditions.

13 years agoPort over a TX gain fix from ath9k specific to the AR9285 (Kite) and AR9271.
adrian [Wed, 13 Apr 2011 04:40:59 +0000 (04:40 +0000)]
Port over a TX gain fix from ath9k specific to the AR9285 (Kite) and AR9271.
Note: this HAL currently only supports the AR9285.

From Linux ath9k:

The problem is that when the attenuation is increased,
the rate will start to drop from MCS7 -> MCS6, and finally
will see MCS1 -> CCK_11Mbps. When the rate is changed b/w
CCK and OFDM, it will use register desired_scale to calculate
how much tx gain need to change.

The output power with the same tx gain for CCK and OFDM modulated
signals are different. This difference is constant for AR9280
but not AR9285/AR9271. It has different PA architecture
a constant. So it should be calibrated against this PA
characteristic.

The driver has to read the calibrated values from EEPROM and set
the tx power registers accordingly.

13 years agoAdd new fields to the v4k EEPROM modal header.
adrian [Wed, 13 Apr 2011 03:05:42 +0000 (03:05 +0000)]
Add new fields to the v4k EEPROM modal header.

13 years agoAdd OS_REG_RMW, which mirrors ath9k's REG_RMW.
adrian [Wed, 13 Apr 2011 03:05:15 +0000 (03:05 +0000)]
Add OS_REG_RMW, which mirrors ath9k's REG_RMW.

This macro does a read-modify-write pass with register bits to set and clear.

13 years agoAdd the initial AR9285 PHY glue for supporting antenna diversity.
adrian [Wed, 13 Apr 2011 02:40:45 +0000 (02:40 +0000)]
Add the initial AR9285 PHY glue for supporting antenna diversity.
This code isn't currently used anywhere; it's just linked into the build.

13 years ago- Fix the code that matches userids in match_jobspec(). It needs to check
gad [Wed, 13 Apr 2011 00:36:19 +0000 (00:36 +0000)]
- Fix the code that matches userids in match_jobspec().  It needs to check
  the username-for-accounting field (P), not the username-for-headerpage (L).
  These are usually the same value, except that control files do not have
  the username-for-headerpage field if the user has requested no header page.
- Also rename the cji_username field to cji_headruser, to make it clear that
  the value should only be used for the header page.  (aka banner page)

MFC after: 3 weeks

13 years agoFix a couple of mbuf leaks introduced by r217242. I do
rmacklem [Wed, 13 Apr 2011 00:03:49 +0000 (00:03 +0000)]
Fix a couple of mbuf leaks introduced by r217242. I do
not believe that these leaks had a practical impact,
since the situations in which they would have occurred
would have been extremely rare.

MFC after: 2 weeks

13 years agoReduce errors in effective frequency calculation.
jkim [Tue, 12 Apr 2011 23:49:07 +0000 (23:49 +0000)]
Reduce errors in effective frequency calculation.

13 years agoReinstate cpu_est_clockrate() support for P-state invariant TSC if APERF and
jkim [Tue, 12 Apr 2011 23:04:01 +0000 (23:04 +0000)]
Reinstate cpu_est_clockrate() support for P-state invariant TSC if APERF and
MPERF MSRs are available.  It was disabled in r216443.  Remove the earlier
hack to subtract 0.5% from the calibrated frequency as DELAY(9) is little
bit more reliable now.

13 years agoAdd support for IEE/IEC (and now also SI) power of two notions of
delphij [Tue, 12 Apr 2011 22:48:03 +0000 (22:48 +0000)]
Add support for IEE/IEC (and now also SI) power of two notions of
prefixes (Ki, Mi, Gi...) for humanize_number(3).

Note that applications has to pass HN_IEC_PREFIXES to use this
feature for backward compatibility reasons.

Reviewed by: arundel
MFC after: 2 weeks

13 years agoDo not use TSC for DELAY(9) if it not P-state invariant to avoid possible
jkim [Tue, 12 Apr 2011 22:41:52 +0000 (22:41 +0000)]
Do not use TSC for DELAY(9) if it not P-state invariant to avoid possible
foot-shooting.  DELAY() becomes unreliable when TSC frequency varies wildly,
especially cpufreq(4) and powerd(8) are used at the same time.

13 years agoAdd forgotten declarations for tsc_perf_stat from the previous commit.
jkim [Tue, 12 Apr 2011 22:22:01 +0000 (22:22 +0000)]
Add forgotten declarations for tsc_perf_stat from the previous commit.

13 years agoProbe capability to find effective frequency. When the TSC is P-state
jkim [Tue, 12 Apr 2011 22:15:46 +0000 (22:15 +0000)]
Probe capability to find effective frequency.  When the TSC is P-state
invariant, APERF/MPERF ratio can be used to find effective frequency.

13 years agoAdd definitions for CPUID instruction 6, ECX information.
jkim [Tue, 12 Apr 2011 22:12:23 +0000 (22:12 +0000)]
Add definitions for CPUID instruction 6, ECX information.

13 years agoAdd a new tunable 'machdep.disable_tsc_calibration' to allow skipping TSC
jkim [Tue, 12 Apr 2011 21:08:34 +0000 (21:08 +0000)]
Add a new tunable 'machdep.disable_tsc_calibration' to allow skipping TSC
frequency calibration.  For Intel processors, if brand string from CPUID
contains its nominal frequency, this frequency is used instead.

13 years agoRefactor hard-reset implementation in ahci(4).
mav [Tue, 12 Apr 2011 20:50:57 +0000 (20:50 +0000)]
Refactor hard-reset implementation in ahci(4).

Instead of spinning in a tight loop for up to 15 seconds, polling for device
readiness while it spins up, return reset completion just after PHY reports
"connect well" or 100ms connection timeout. If device was found, use callout
for checking device readiness with 100ms period up to full 31 second timeout.

This fixes system freeze for 5-10 seconds on drives hot plug-in.

13 years agoFix 'zfs list <path>' handling. If the path was found, the 'ret' variable was
pjd [Tue, 12 Apr 2011 20:31:33 +0000 (20:31 +0000)]
Fix 'zfs list <path>' handling. If the path was found, the 'ret' variable was
uninitialized.

PR: kern/155940
Submitted by: KOIE Hidetaka <koie@suri.co.jp>
MFC after: 1 week

13 years agoGet rid of DSIZ; instead just call the sizing function if provided.
trasz [Tue, 12 Apr 2011 20:10:15 +0000 (20:10 +0000)]
Get rid of DSIZ; instead just call the sizing function if provided.

13 years agoThe replication mode that is currently support is fullsync, not memsync.
pjd [Tue, 12 Apr 2011 19:13:10 +0000 (19:13 +0000)]
The replication mode that is currently support is fullsync, not memsync.
Correct this and print a warning if different replication mode is
configured.

MFC after: 1 week

13 years agoImplement automatic SCSI sense fetching for mvs(4).
mav [Tue, 12 Apr 2011 16:01:27 +0000 (16:01 +0000)]
Implement automatic SCSI sense fetching for mvs(4).

Make few improvements/changes to ATAPI PIO support to pass most of scgcheck
(cdrtools) tests.

13 years agoRestore previous behaviour - always match rule when we doing tagging,
ae [Tue, 12 Apr 2011 15:20:34 +0000 (15:20 +0000)]
Restore previous behaviour - always match rule when we doing tagging,
even when tag is already exists.

Reported by: Vadim Goncharov
MFC after: 1 week

13 years agoUpdate some terminology: floppies are no longer built, and FreeBSD is not
nwhitehorn [Tue, 12 Apr 2011 12:57:46 +0000 (12:57 +0000)]
Update some terminology: floppies are no longer built, and FreeBSD is not
necessarily distributed by CVS any longer.

13 years agoImplement automatic SCSI sense fetching for siis(4).
mav [Tue, 12 Apr 2011 11:29:15 +0000 (11:29 +0000)]
Implement automatic SCSI sense fetching for siis(4).

Fix device freeze leak on recovery request (READ LOG, REQUEST SENSE)
failure.

13 years agoImplement automatic SCSI sense fetching for ahci(4).
mav [Tue, 12 Apr 2011 11:24:59 +0000 (11:24 +0000)]
Implement automatic SCSI sense fetching for ahci(4).

13 years agoImplement automatic SCSI sense fetching for ata(4) in ATA_CAM mode.
mav [Tue, 12 Apr 2011 09:55:24 +0000 (09:55 +0000)]
Implement automatic SCSI sense fetching for ata(4) in ATA_CAM mode.
While it could be successfully done by CAM error recovery code, I was
told by several people that it is also a SIM obligation.

13 years agoUse the full and proper company name for Swinburne University of Technology
lstewart [Tue, 12 Apr 2011 08:13:18 +0000 (08:13 +0000)]
Use the full and proper company name for Swinburne University of Technology
throughout the source tree.

Requested by: Grenville Armitage, Director of CAIA at Swinburne University of
Technology
MFC after: 3 days

13 years agoIntroduce geom_map, a GEOM provider designed for use by
adrian [Tue, 12 Apr 2011 08:10:25 +0000 (08:10 +0000)]
Introduce geom_map, a GEOM provider designed for use by
embedded flash stores.

Some devices - notably those with uboot - don't have an
explicit partition table (eg like Redboot's FIS.)
geom_map thus provides an easy way to export the hard-coded
flash layout as geom providers for use by filesystems and
other tools.

It also includes a "search" function which allows for
dynamic creation of partition layouts where the device only
has a single hard-coded partition. For example, if
there is a "kernel+rootfs" partition, a single image can
be created which appends the rootfs after the kernel with
an appropriate search string. geom_map can be told to
search for said search string and create a partition
beginning after it.

Submitted by: Aleksandr Rybalko <ray@dlink.ua>

13 years agoWe don't need to call EOWRITE4(sc, EHCI_USBINTR, 0) directly from each EHCI
hselasky [Tue, 12 Apr 2011 07:49:11 +0000 (07:49 +0000)]
We don't need to call EOWRITE4(sc, EHCI_USBINTR, 0) directly from each EHCI
bus driver at detach, hence ehci_detach() does exactly this since r199718.

Submitted by: Luiz Otavio O Souza
MFC after: 7 days
Approved by: thompsa (mentor)

13 years agoIf building (custom) FreeBSD images people tend to patch param.h. In case
bz [Tue, 12 Apr 2011 02:07:23 +0000 (02:07 +0000)]
If building (custom) FreeBSD images people tend to patch param.h.  In case
this happens just before the build is started (within the same second)
CHECK_TIME actually triggers thinking param.h is in the future (see f_Xtime,
c_Xtime logi in find(1) sources for the details in !F_EXACTTIME case).
Using the -mtime -0s (seconds, rather than no unit) avoids this 1s race.

Submitted by: ed (2009-05-03)
Reviewed by: cperciva (2009-05-03), emaste
Tested by: bz (for almost two years)
MFC after: 4 days

13 years agoEven though this block is not compiled currently, properly assign
bz [Tue, 12 Apr 2011 01:19:23 +0000 (01:19 +0000)]
Even though this block is not compiled currently, properly assign
CSUM_TSO to if_hwassist rather than if_capabilities to avoid future
errors.

Reviewed by: jeff

13 years agoMFV of r220547, tzdata2011f:
edwin [Mon, 11 Apr 2011 21:57:59 +0000 (21:57 +0000)]
MFV of r220547, tzdata2011f:

- During 2011 the Falkland Islands will remain on Summer time.

Obtained from:  ftp://elsie.nci.nih.gov/pub/

13 years agoVrele ni_startdir in the experimental NFS server for the case
rmacklem [Mon, 11 Apr 2011 20:54:30 +0000 (20:54 +0000)]
Vrele ni_startdir in the experimental NFS server for the case
of NFSv2 getting an error return from VOP_MKNOD(). Without this
patch, the server file system remains busy after an NFSv2
VOP_MKNOD() fails.

MFC after: 2 weeks

13 years agoMerge two similar functions to reduce duplication.
jkim [Mon, 11 Apr 2011 19:27:44 +0000 (19:27 +0000)]
Merge two similar functions to reduce duplication.

13 years agoDon't do make release and make install in one step. Setting DESTDIR for
nwhitehorn [Mon, 11 Apr 2011 15:03:01 +0000 (15:03 +0000)]
Don't do make release and make install in one step. Setting DESTDIR for
make release has deleterious consequences.

13 years agoMake the keymap script continue to work now that stderr is being
nwhitehorn [Mon, 11 Apr 2011 14:46:40 +0000 (14:46 +0000)]
Make the keymap script continue to work now that stderr is being
redirected to the log file.

13 years agoAdd an install target to release/Makefile instead of grubbing around
nwhitehorn [Mon, 11 Apr 2011 14:30:45 +0000 (14:30 +0000)]
Add an install target to release/Makefile instead of grubbing around
(and requesting that users grub around) in /usr/obj. Also make sure that
make clean removes the bootonly media and clean up that target a little.

13 years agoDe-dup the ar5416 rates array definition.
adrian [Mon, 11 Apr 2011 11:15:34 +0000 (11:15 +0000)]
De-dup the ar5416 rates array definition.

13 years agoRework change made at r203146. Instead of reporting all wire errors as
mav [Mon, 11 Apr 2011 08:23:27 +0000 (08:23 +0000)]
Rework change made at r203146. Instead of reporting all wire errors as
SCSI status errors to CAM (that was wrong, as it too often turned retriable
wire errors into non-retriable REQUEST SENSE errors), do it only for STALL
errors on control pipe of the CBI devices. STALL on control pipe is just
a one of the ways to report error for CBI devices.

PR: usb/150401, usb/154593.
Reviewed by: hselasky
MFC after: 1 week

13 years agoGenerate opt_ah.h now for all ath tools, a recent HAL change of mine
adrian [Mon, 11 Apr 2011 06:53:45 +0000 (06:53 +0000)]
Generate opt_ah.h now for all ath tools, a recent HAL change of mine
now requires it.

13 years ago - Refactor softdep_setup_freeblocks() into a set of functions to prepare
jeff [Mon, 11 Apr 2011 01:43:59 +0000 (01:43 +0000)]
 - Refactor softdep_setup_freeblocks() into a set of functions to prepare
   for a new journal specific partial truncate routine.
 - Use dep_current[] in place of specific dependency counts.  This is
   automatically maintained when workitems are allocated and has
   less risk of becoming incorrect.

13 years agoAdd some cleanup code to the module unload operation for
rmacklem [Sun, 10 Apr 2011 20:43:07 +0000 (20:43 +0000)]
Add some cleanup code to the module unload operation for
the experimental NFS server, so that it doesn't leak memory
when unloaded. However, unloading the NFSv4 server is not
recommended, since all NFSv4 state will be lost by the unload
and clients will have to recover the state after a server
reload/restart as if the server crashed/rebooted.

MFC after: 2 weeks

13 years agoRename a misnamed structure field (hr_loginclass), and reorder priv(9)
trasz [Sun, 10 Apr 2011 18:35:43 +0000 (18:35 +0000)]
Rename a misnamed structure field (hr_loginclass), and reorder priv(9)
constants to match the order and naming of syscalls.  No functional changes.

13 years agoSome callers of proc_reparent() already have the parent process locked.
kib [Sun, 10 Apr 2011 17:07:02 +0000 (17:07 +0000)]
Some callers of proc_reparent() already have the parent process locked.
Detect the situation and avoid process lock recursion.

Reported by: Fabian Keil <freebsd-listen fabiankeil de>

13 years agoIn hast_proto_recv() remove unnecessary check. The size is checked
trociny [Sun, 10 Apr 2011 15:28:37 +0000 (15:28 +0000)]
In hast_proto_recv() remove unnecessary check. The size is checked
later in hast_proto_recv_data().

Approved by: pjd (mentor)
MFC after: 1 week

13 years agoIn hast_proto_recv_data() check that the size of the data to be
trociny [Sun, 10 Apr 2011 15:21:46 +0000 (15:21 +0000)]
In hast_proto_recv_data() check that the size of the data to be
received does not exceed the buffer size.

Approved by: pjd (mentor)
MFC after: 1 week

13 years agoFix a typo in comments.
trociny [Sun, 10 Apr 2011 15:11:19 +0000 (15:11 +0000)]
Fix a typo in comments.

Approved by: pjd (mentor)
MFC after: 3 days

13 years agohastd(8) maintains a map of dirty extents, not hastctl(8). Fix this.
trociny [Sun, 10 Apr 2011 15:07:54 +0000 (15:07 +0000)]
hastd(8) maintains a map of dirty extents, not hastctl(8). Fix this.

Approved by: pjd (mentor)
MFC after: 3 days

13 years agoFix a bug in the userland rpc library, where it would use a
rmacklem [Sun, 10 Apr 2011 14:11:07 +0000 (14:11 +0000)]
Fix a bug in the userland rpc library, where it would use a
negative return value from write to update its position in
a buffer. The patch, courtesy of Andrey Simonenko, also simplifies
a conditional by removing the "i != cnt" clause, since it is
always true at this point in the code. The bug caused problems
for mountd, when it generated a large reply to an exports RPC
request.

Submitted by: simon at comsys.ntu-kpi.kiev.ua
MFC after: 2 weeks

13 years agoModify the man pages to reflect the addition of a backup
rmacklem [Sun, 10 Apr 2011 13:45:46 +0000 (13:45 +0000)]
Modify the man pages to reflect the addition of a backup
stable restart file, as done by r220510.
This is a content change.

MFC after: 2 weeks

13 years agoRename 07.lpr to 07.lpd and re-connect to the build. This was
uqs [Sun, 10 Apr 2011 12:43:13 +0000 (12:43 +0000)]
Rename 07.lpr to 07.lpd and re-connect to the build. This was
forgotten in r216178.

Submitted by: antoine
Pointyhat: uqs

13 years agoAdd link to rctl(8).
trasz [Sun, 10 Apr 2011 10:17:01 +0000 (10:17 +0000)]
Add link to rctl(8).

13 years agoRemove stray semicolon.
trasz [Sun, 10 Apr 2011 10:15:49 +0000 (10:15 +0000)]
Remove stray semicolon.

13 years agoUpdate recommendation for mergemaster. The -a and -i options are exclusive.
dougb [Sun, 10 Apr 2011 03:53:06 +0000 (03:53 +0000)]
Update recommendation for mergemaster. The -a and -i options are exclusive.

PR: docs/156271
Submitted by: Fedor Dikarev <fedor.dikarev@gmail.com>

13 years agoFix a long standing SUJ performance problem:
jeff [Sun, 10 Apr 2011 03:49:53 +0000 (03:49 +0000)]
Fix a long standing SUJ performance problem:

 - Keep a hash of indirect blocks that have recently been freed and are
   still referenced in the journal.
 - Lookup blocks in this hash before forcing a new block write to wait on
   the journal entry to hit the disk.  This is only necessary to avoid
   confusion between old identities as indirects and new identities as
   file blocks.
 - Don't free jseg structures until the journal has written a record that
   invalidates it.  This keeps the indirect block information around for
   as long as is required to be safe.
 - Force an empty journal block write when required to flush out stale
   journal data that is simply waiting for the oldest valid sequence
   number to advance beyond it.

13 years agoAdd support for a backup stable restart file to the nfsd,
rmacklem [Sun, 10 Apr 2011 01:54:42 +0000 (01:54 +0000)]
Add support for a backup stable restart file to the nfsd,
used for NFSv4 restart. This permits the nfsd to create
the stable restart file as required and minimizes the risk
of trouble if the file is lost.

Suggested by: Tim Kientzle
Reviewed by: jhb
MFC after: 2 weeks

13 years agoAdd a VOP_UNLOCK() for the directory, when that is not what
rmacklem [Sat, 9 Apr 2011 23:55:27 +0000 (23:55 +0000)]
Add a VOP_UNLOCK() for the directory, when that is not what
VOP_LOOKUP() returned. This fixes a bug in the experimental
NFS server for the case where VFS_VGET() fails returning EOPNOTSUPP
in the ReaddirPlus RPC, forcing the use of VOP_LOOKUP() instead.

MFC after: 2 weeks

13 years agoLinuxolator calls VOP_READDIR with ncookies pointer. Implement a
kib [Sat, 9 Apr 2011 21:40:48 +0000 (21:40 +0000)]
Linuxolator calls VOP_READDIR with ncookies pointer. Implement a
workaround for fdescfs to not panic when ncookies is not NULL, similar
to the one committed as r152254, but simpler, due to fdescfs_readdir()
not calling vfs_read_dirent().

PR: kern/156177
MFC after: 1 week

13 years agoDon't hardcode assumptions about basic rates, similar to what the rt2661
bschmidt [Sat, 9 Apr 2011 14:45:50 +0000 (14:45 +0000)]
Don't hardcode assumptions about basic rates, similar to what the rt2661
support code does. While here remove an unnecessary loop.

13 years agoAllow the user to use the live environment post-installation, as well
nwhitehorn [Sat, 9 Apr 2011 14:25:58 +0000 (14:25 +0000)]
Allow the user to use the live environment post-installation, as well
as improving error handling.

13 years agoRename the "Reboot" option to "Exit", which reflects what it actually
nwhitehorn [Sat, 9 Apr 2011 14:18:03 +0000 (14:18 +0000)]
Rename the "Reboot" option to "Exit", which reflects what it actually
does. The rc.local wrapper script will also soon grow an option to use the
live environment after installation, so an immediate reboot isn't even
necessarily implied.

13 years agoDocument SHA256/512 modes.
markm [Sat, 9 Apr 2011 14:09:46 +0000 (14:09 +0000)]
Document SHA256/512 modes.

MFC after: 1 month

13 years agoAdd SHA256/512 ($5$ and $6$) to crypt(3). Used in linux-world, doesn't
markm [Sat, 9 Apr 2011 14:02:04 +0000 (14:02 +0000)]
Add SHA256/512 ($5$ and $6$) to crypt(3). Used in linux-world, doesn't
hurt us.

PR: misc/124164
Submitted by: KIMURA Yasuhiro < yasu utahime org >
MFC after: 1 month

13 years agoAdd SHA512 (Actually, this is Colin Percival's code for SHA256, with
markm [Sat, 9 Apr 2011 13:56:29 +0000 (13:56 +0000)]
Add SHA512 (Actually, this is Colin Percival's code for SHA256, with
relevant constants changed).

While I'm here clean up the tests and Makefile.

PR: misc/124164
Submitted by: KIMURA Yasuhiro < yasu utahime org >
MFC after: 1 month

13 years agoFix make buildworld -DMODULES_WITH_WORLD on i386
uqs [Sat, 9 Apr 2011 09:07:31 +0000 (09:07 +0000)]
Fix make buildworld -DMODULES_WITH_WORLD on i386

13 years agoMake it possible to use permission sets (full_set, modify_set, read_set
trasz [Sat, 9 Apr 2011 07:42:25 +0000 (07:42 +0000)]
Make it possible to use permission sets (full_set, modify_set, read_set
and write_set) with setfacl(1).

PR: kern/154113
Submitted by: Shawn Webb <lattera at gmail dot com> (earlier version)
MFC after: 1 month

13 years agoRemove a check in udp6_send() that prevented v4-mapped v6 addresses from
bz [Sat, 9 Apr 2011 02:22:49 +0000 (02:22 +0000)]
Remove a check in udp6_send() that prevented v4-mapped v6 addresses from
working.  We store v4 and v6 addresses as a union but for v4-mapped
addresses only store the 32bits w/o the ::ffff: word.  That failed the
check as for example 127.0.0.1 would be ::7f00:1 rather than ::ffff:7f00:1
and the IN6_IS_ADDR_V4MAPPED() never worked here.  Given we can hardly get
here with an unbound local address or invalid inp_vflags remove the check.

Reported by: tuexen
Reviewed by: tuexen
MFC after: 3 days

13 years agoAfter r219579 and r219779 unbreak v4-mapped v6 sockets for UDP
bz [Sat, 9 Apr 2011 01:29:46 +0000 (01:29 +0000)]
After r219579 and r219779 unbreak v4-mapped v6 sockets for UDP
some more.  Similar to what we do for TCP check for v4-mapped
addresses and then handle them or the normal v6 address case.
For either set inp_vflags before calling into the pcb connect
function so that we have an unambiguous view in case we need to
set the local address or port.

Looked at: tuexen (as part of more)
MFC after: 3 days

13 years agoRemove setting of PCB_FULL_IRET at the places where we are going to call
kib [Fri, 8 Apr 2011 21:27:31 +0000 (21:27 +0000)]
Remove setting of PCB_FULL_IRET at the places where we are going to call
update_gdt_{f,g}sbase. The functions set the flag when td == curthread,
and sysarch is always called with curthread.

Reviewed by: jhb, jkim
MFC after: 1 week

13 years agoDisable local interrupts before testing the PCB_FULL_IRET flag.
kib [Fri, 8 Apr 2011 21:26:50 +0000 (21:26 +0000)]
Disable local interrupts before testing the PCB_FULL_IRET flag.
Thread might be preempted after testing, which causes the flag to be
cleared. If ast was not delivered, we will do sysret with potentially
wrong fs/gs bases.

Reviewed by: jhb, jkim
MFC after: 1 week (together with r220430, r220452)