wblock [Thu, 3 Jan 2013 21:58:28 +0000 (21:58 +0000)]
Document the output of the show command. Modified version of patch
provided by Bas Smeelen <b.smeelen@ose.nl>. Use of 'gpart list'
suggested by by Andrey V. Elsukov <ae@FreeBSD.org>.
kib [Thu, 3 Jan 2013 19:17:57 +0000 (19:17 +0000)]
Add the "nocache" nullfs mount option, which disables the caching of
the free nullfs vnodes, switching nullfs behaviour to pre-r240285.
The option is mostly intended as the last-resort when higher pressure
on the vnode cache due to doubling of the vnode counts is not
desirable.
Note that disabling the cache costs more than 2x wall time in the
metadata-hungry scenarious. The default is "cache".
markj [Thu, 3 Jan 2013 16:14:51 +0000 (16:14 +0000)]
Make sure to update the mtime of a logfile after archiving it. This
ensures that the next rotation happens at the correct time when using
interval-based rotations.
marius [Thu, 3 Jan 2013 13:44:25 +0000 (13:44 +0000)]
- Replace partially incorrect function names in panic(9) strings with
__func__ and add some missing ones.
- Remove a stale comment.
- Remove unused NUM_ELEMENTS macro.
- Remove extra empty lines.
- Use DEVMETHOD_END.
- Use NULL rather than 0 for pointers.
marius [Thu, 3 Jan 2013 13:42:45 +0000 (13:42 +0000)]
- Fix !SMP build.
- Replace incorrect function names in printf(9) strings with __func__.
- Make xctrl_shutdown_reasons table const.
- Use nitems() rather than rolling an own version.
- Use DEVMETHOD_END.
- Use NULL rather than 0 for pointers.
nwhitehorn [Wed, 2 Jan 2013 13:25:11 +0000 (13:25 +0000)]
Make sade actually be a symlink to partedit, as per the commit message in
r244859, rather than a hardlink. This fixes installation if /usr/sbin
is on a different filesystem than /usr/libexec.
adrian [Wed, 2 Jan 2013 00:38:01 +0000 (00:38 +0000)]
Bring over the basic spectral scan framework code from Qualcomm Atheros.
This includes the HAL routines to setup, enable/activate/disable spectral
scan and configure the relevant registers.
This still requires driver interaction to enable spectral scan reporting.
Specifically:
* call ah_spectralConfigure() to configure and enable spectral scan;
* .. there's currently no way to disable spectral scan... that will have
to follow.
* call ah_spectralStart() to force start a spectral report;
* call ah_spectralStop() to force stop an active spectral report.
The spectral scan results appear as PHY errors (type 0x5 on the AR9280,
same as radar) but with the spectral scan bit set (0x10 in the last byte
of the frame) identifying it as a spectral report rather than a radar
FFT report.
Caveats:
* It's likely quite difficult to run spectral _and_ radar at the same
time. Enabling spectral scan disables the radar thresholds but
leaves radar enabled. Thus, the driver (for now) needs to ensure
that only one or the other is enabled.
* .. it needs testing on HT40 mode.
Tested:
* AR9280 in STA mode, HT/20 only
TODO:
* Test on AR9285, AR9287;
* Test in both HT20 and HT40 modes;
* .. all the driver glue.
rwatson [Tue, 1 Jan 2013 19:42:06 +0000 (19:42 +0000)]
Merge @219932 from Perforce:
FDT headers can't be included if the kernel is compiled without
FDT support, due to dependence on generated kobj headers. BERI
supports both FDT and non-FDT kernels.
pfg [Tue, 1 Jan 2013 19:20:51 +0000 (19:20 +0000)]
libedit: bind the correct command when using "bind -k".
"ed-argument-digit" (i. e. command 0) was incorrectly used
instead.
This bug comes from the original sources imported in 1994
and has been confirmed in upstream NetBSD.
Reported by: Yamagi Burmeister
Submitted by: Christoph Mallon
MFC after: 3 days
kientzle [Tue, 1 Jan 2013 18:55:04 +0000 (18:55 +0000)]
Overhauled CPSW driver for TI CPSW Ethernet module
(as used in AM335x SoC for BeagleBone).
Among other things:
* Watchdog reset doesn't hang the driver.
* Disconnecting cable doesn't hang the driver.
* ifconfig up/down doesn't hang the driver
* Out-of-memory no longer panics the driver.
Known issues:
* Doesn't have good support for fragmented packets
(calls m_defrag() on TX, assumes RX packets are never fragmented)
* Promisc and allmulti still unimplimented
* addmulti and delmulti still unimplemented
* TX queue still stalls (but watchdog now consistently recovers in ~5s)
* No sysctl monitoring
* Only supports port0
* No switch configuration support
* Not tested on anything but BeagleBone
kib [Tue, 1 Jan 2013 16:14:48 +0000 (16:14 +0000)]
The process_deferred_inactive() function locks the vnodes of the ufs
mount, which means that is must not be called while the snaplock is
owned. The vfs_write_resume(9) does call the function as the
VFS_SUSP_CLEAN() method, which is too early and falls into the region
still protected by snaplock.
Add yet another flag for the vfs_write_resume_flags() to avoid calling
suspension cleanup handler after the suspend is lifted, and use it in
the ffs_snapshot() call to vfs_write_resume.
Reported and tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
markj [Mon, 31 Dec 2012 21:54:43 +0000 (21:54 +0000)]
Explicitly specify that the beforelinking target depends on the
generated object files, ensuring that the beforelinking recipe won't be
executed until compilation has finished.
Also define SHLIB_NAME_FULL to denote ${SHLIB_NAME}.debug if
DEBUG_FILES is set and ${SHLIB_NAME} otherwise, which helps avoid
obfuscating the compilation and linking rules.
gonzo [Mon, 31 Dec 2012 21:19:44 +0000 (21:19 +0000)]
PL310 driver update:
- Add pl310.disable tunable to disable L2 cache altogether. In
order to make sure that it's 100% disabled we use cache event
counters for cache line eviction and read allocate events
and panic if any of these counters increased. This is purely
for debugging purpose
- Direct access DEBUG_CTRL and CTRL might be unavailable in
unsecure mode, so use platform-specific functions for
these registers
- Replace #if 1 with proper erratum numbers
- Add erratum 753970 workaround
- Remove wait function for atomic operations
- Protect cache operations with spin mutex in order to prevent race condition
- Disable instruction cache prefetch and make sure data cache
prefetch is enabled in OMAP4-specific intialization
gonzo [Mon, 31 Dec 2012 21:00:38 +0000 (21:00 +0000)]
Merge r234561 from busdma_machdep.c to ARMv6 version of busdma:
Interrupts must be disabled while handling a partial cache line flush,
as otherwise the interrupt handling code may modify data in the non-DMA
part of the cache line while we have it stashed away in the temporary
stack buffer, then we end up restoring a stale value.
rwatson [Sun, 30 Dec 2012 21:10:48 +0000 (21:10 +0000)]
When a partially initialised FDT-based device instance can't attach,
perhaps due to an interrupt configuration problem, do not try to free
device ivars that have not yet have been allocated.
nwhitehorn [Sun, 30 Dec 2012 16:28:06 +0000 (16:28 +0000)]
With the old sade removed, libdisk is no longer used by anything in HEAD
and uses a number of problematic pre-gpart interfaces. Since it has been
entirely obsoleted by interfaces in geom, remove it.
kevlo [Sun, 30 Dec 2012 15:20:27 +0000 (15:20 +0000)]
- Use BN_set_negative() and BN_is_negative() instead of subtracting or
comparing to zero.
- Fix fractional number exponentiation, especially for negative exponents.
nwhitehorn [Sun, 30 Dec 2012 14:35:00 +0000 (14:35 +0000)]
Replace sade the extracted piece of sysinstall with sade the extracted
piece of bsdinstall (although this time with a symlink instead of duplicated
source code).
adrian [Sun, 30 Dec 2012 06:48:12 +0000 (06:48 +0000)]
Add the initial HAL glue for the spectral analysis support.
* Finish adding the HAL capability to announce whether a NIC supports
spectral scan or not;
* Add spectral scan methods to the HAL structure;
* Add HAL_SPECTRAL_PARAM for configuration of the spectral scan logic.
The capability ID and HAL_SPECTRAL_PARAM struct are from Qualcomm
Atheros.
nwhitehorn [Sun, 30 Dec 2012 04:22:34 +0000 (04:22 +0000)]
Revert r241818 that updated dialog to 20120706. This turns out to horribly
break mixed form dialogs in conjunction with the FreeBSD termcap, making
the bsdinstall partition editor Add dialog, among other things, completely
nonfunctional. This restores dialog 20110707.
dteske [Fri, 28 Dec 2012 23:49:17 +0000 (23:49 +0000)]
Allow debug output to be logged to a file (set $debugFile to target pathname)
or both stdout and a file (precede $debugFile pathname with a plus-sign, `+').
kib [Fri, 28 Dec 2012 23:08:30 +0000 (23:08 +0000)]
Make it possible to atomically resume writes on the mount and account
the write start, by adding a variation of the vfs_write_resume(9)
which accepts flags.
Use the new function to prevent a deadlock between parallel suspension
and snapshotting a UFS mount. The ffs_snapshot() code performed
vfs_write_resume() followed by vn_start_write() while owning the
snaplock. If the suspension intervene between resume and
vn_start_write(), the deadlock occured after the suspending thread
tried to lock the snaplock, most typically during the write in the
ffs_copyonwrite().
Reported and tested by: Andreas Longwitz <longwitz@incore.de>
Reviewed by: mckusick
MFC after: 2 weeks
X-MFC-note: make the vfs_write_resume(9) function a macro after the MFC,
in HEAD