]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
13 years agoExtend this check for const unsigned char *.
rdivacky [Wed, 13 Oct 2010 14:27:47 +0000 (14:27 +0000)]
Extend this check for const unsigned char *.

Approved by:    rpaulo (mentor)

13 years agoMake DEBUG traces 64-bit clean:
jhb [Wed, 13 Oct 2010 13:22:11 +0000 (13:22 +0000)]
Make DEBUG traces 64-bit clean:
- Use %t to print ptrdiff_t values.
- Cast a ptrdiff_t value explicitly to int for a field width specifier.

While here, sort includes.

Submitted by: Garrett Cooper

13 years agoSuggest that DEBUG_FLAGS be used to enable extra debugging rather than
jhb [Wed, 13 Oct 2010 13:17:38 +0000 (13:17 +0000)]
Suggest that DEBUG_FLAGS be used to enable extra debugging rather than
frobbing CFLAGS directly.  DEBUG_FLAGS is something that can be specified
on the make command line without having to edit the Makefile directly.

Submitted by: Garrett Cooper

13 years agoMark acpi_bus_number() as __unused. This allows clang to this file
rpaulo [Wed, 13 Oct 2010 11:38:24 +0000 (11:38 +0000)]
Mark acpi_bus_number() as __unused. This allows clang to this file
without any warnings.

13 years agoIgnore the return value of DE_INTERNALIZE().
rpaulo [Wed, 13 Oct 2010 11:37:39 +0000 (11:37 +0000)]
Ignore the return value of DE_INTERNALIZE().

13 years agoExplicitly tell the compiler that we don't care about the return value
rpaulo [Wed, 13 Oct 2010 11:37:12 +0000 (11:37 +0000)]
Explicitly tell the compiler that we don't care about the return value
of kbdd_ioctl().

13 years agoThe canonical way to print __func__ when using KASSERT() is to write
rpaulo [Wed, 13 Oct 2010 11:35:59 +0000 (11:35 +0000)]
The canonical way to print __func__ when using KASSERT() is to write
("%s", __func__). This avoids clang's -Wformat-string warnings.

13 years agoPurposely tell the compiler that we ignore the return value of ADDCARRY()
rpaulo [Wed, 13 Oct 2010 10:45:22 +0000 (10:45 +0000)]
Purposely tell the compiler that we ignore the return value of ADDCARRY()
in the REDUCE macro.

Reviewed by: dim, rdivacky

13 years agoDefine YY_NO_INPUT. This makes aicasm buildable by clang with Werror
rpaulo [Wed, 13 Oct 2010 10:33:01 +0000 (10:33 +0000)]
Define YY_NO_INPUT. This makes aicasm buildable by clang with Werror
turned on.

13 years agoDon't define the input() function ifdef YY_NO_INPUT.
rpaulo [Wed, 13 Oct 2010 10:31:32 +0000 (10:31 +0000)]
Don't define the input() function ifdef YY_NO_INPUT.

This was previously done for the input() function.

Submitted by: Norberto Lopes <nblopes.ml at gmail.com>

13 years agoUse the RFC2606 domain example.com in examples.
brucec [Wed, 13 Oct 2010 09:33:26 +0000 (09:33 +0000)]
Use the RFC2606 domain example.com in examples.

13 years agoo) Make it possible to attach a PHY directly to an octe device rather than
jmallett [Wed, 13 Oct 2010 09:17:44 +0000 (09:17 +0000)]
o) Make it possible to attach a PHY directly to an octe device rather than
   using miibus, since for some devices that use multiple addresses on the bus,
   going through miibus may be unclear, and for devices that are not standard
   MII PHYs, miibus may throw a fit, necessitating complicated interfaces to
   fake the interface that it expects during probe/attach.
o) Make the mv88e61xx SMI interface in octe attach a PHY directly and fix some
   mistakes in the code that resulted from trying too hard to present a nice
   interface to miibus.
o) Add a PHY driver for the mv88e61xx.  If attached (it is optional in kernel
   compiles so the default behavior of having a dumb switch is preserved) it
   will place the switch in a VLAN-tagging mode such that each physical port
   has a VLAN associated with it and interfaces for the VLANs can be created to
   address or bridge between them.
   XXX It would be nice for this to be part of a single module including the
       SMI interface, and for it to fit into a generic switch configuration
       framework and for it to use DSA rather than VLANs, but this is a start
       and gives some sense of the parameters of such frameworks that are not
       currently present in FreeBSD.  In lieu of a switch configuration
       interface, per-port media status and VLAN settings are in a sysctl tree.
   XXX There may be some minor nits remaining in the handling of broadcast,
       multicast and unknown destination traffic.  It would also be nice to go
       through and replace the few remaining magic numbers with macros at some
       point in the future.
   XXX This has only been tested with the MV88E6161, but it should work with
       minimal or no modification on related switches, so support for probing
       them was included.

Thanks to Pat Saavedra of TELoIP and Rafal Jaworowski of Semihalf for their
assistance in understanding the switch chipset.

13 years agosigqueue_collect_set() is no longer needed because other functions
davidxu [Wed, 13 Oct 2010 06:28:40 +0000 (06:28 +0000)]
sigqueue_collect_set() is no longer needed because other functions
maintain pending set correctly.

13 years agoConsistently use "STATIC" for all functions in order to be able to set
obrien [Wed, 13 Oct 2010 04:01:01 +0000 (04:01 +0000)]
Consistently use "STATIC" for all functions in order to be able to set
breakpoints with in a debugger.  And use naked "static" for variables.

Noticed by: bde

13 years agoFix the krpc so that it can handle NFSv3,UDP mounts with a read/write
rmacklem [Wed, 13 Oct 2010 00:57:14 +0000 (00:57 +0000)]
Fix the krpc so that it can handle NFSv3,UDP mounts with a read/write
data size greater than 8192. Since soreserve(so, 256*1024, 256*1024)
would always fail for the default value of sb_max, modify clnt_dg.c
so that it uses the calculated values and checks for an error return
from soreserve(). Also, add a check for error return from soreserve()
to clnt_vc.c and change __rpc_get_t_size() to use sb_max_adj instead of
the bogus maxsize == 256*1024.

PR: kern/150910
Reviewed by: jhb
MFC after: 2 weeks

13 years agoUse AcpiReset() from ACPICA instead of rolling our own, which is actually
jkim [Wed, 13 Oct 2010 00:21:53 +0000 (00:21 +0000)]
Use AcpiReset() from ACPICA instead of rolling our own, which is actually
incomplete.  If FADT says the register is available, enable the capability
by default.  Remove the previous default value from acpi(4).

13 years agoCreate the /bin/rmail symlink (which mailers such as postfix
markm [Tue, 12 Oct 2010 21:01:26 +0000 (21:01 +0000)]
Create the /bin/rmail symlink (which mailers such as postfix
and Exim can use).

This is something I thought I committed MONTHS ago, but it appears
that I fatfingered it and made a local commit.

Pass the pointy hat, please.

13 years agoRemove trailing ", " from `sysctl machdep.idle_available' output.
jkim [Tue, 12 Oct 2010 20:53:12 +0000 (20:53 +0000)]
Remove trailing ", " from `sysctl machdep.idle_available' output.

13 years agoProtect bge(4) from accessing invalid NIC internal memory regions
yongari [Tue, 12 Oct 2010 19:31:25 +0000 (19:31 +0000)]
Protect bge(4) from accessing invalid NIC internal memory regions
on BCM5906.

Tested by: Buganini < buganini <> gmail dot com >

13 years agoIf DEBUG is 3 or greater, disable STATICization of functions.
obrien [Tue, 12 Oct 2010 19:24:41 +0000 (19:24 +0000)]
If DEBUG is 3 or greater, disable STATICization of functions.
Also correct the documented location of the trace file.

13 years agoAlways set cm_complete_data before calling mps_config_complete().
mdf [Tue, 12 Oct 2010 19:24:29 +0000 (19:24 +0000)]
Always set cm_complete_data before calling mps_config_complete().

Reviewed by: ken

13 years agoFix a regression introduced in r213495. r213495 disabled mini
yongari [Tue, 12 Oct 2010 19:22:03 +0000 (19:22 +0000)]
Fix a regression introduced in r213495. r213495 disabled mini
receive producer ring only for BCM5700. It was believed that
BCM5700 with external SSRAM is the only controller that supports
mini ring but it seems all BCM570[0-4] requires to disable mini
receive producer ring. Otherwise, it caused unexpected RX DMA
error or watchdog timeouts.

Reported by: marius, Steve Kargl <sgk <> troutmask dot apl dot washington dot edu>
Tested by: marius, Steve Kargl <sgk <> troutmask dot apl dot washington dot edu>

13 years agoDocument the fact that bwn works really well on the laptop I'm using
joel [Tue, 12 Oct 2010 19:00:18 +0000 (19:00 +0000)]
Document the fact that bwn works really well on the laptop I'm using
right now (HP 6715b).

13 years agoRe-expose and briefly document taskqueue_run(9). The function is used
mdf [Tue, 12 Oct 2010 18:36:03 +0000 (18:36 +0000)]
Re-expose and briefly document taskqueue_run(9).  The function is used
in at least one 3rd party driver.

Requested by: jhb

13 years agoAllow one to regression test 'sh' changes without having to install
obrien [Tue, 12 Oct 2010 18:20:38 +0000 (18:20 +0000)]
Allow one to regression test 'sh' changes without having to install
a potentially bad /bin/sh first.

13 years agoacpi_ec: changes in communication with hardware
avg [Tue, 12 Oct 2010 17:53:01 +0000 (17:53 +0000)]
acpi_ec: changes in communication with hardware

Short description of the changes:
- attempt to retry some commands for which it is possible (read, query)
- always make a short sleep before checking EC status in polled mode
- periodically poll EC status in interrupt mode
- change logic for detecting broken interrupt delivery and falling back
  to polled mode
- check that EC is ready for input before starting a new command, wait
  if necessary

This commit is based on the original patch by David Naylor.

PR: kern/150517
Submitted by: David Naylor <naylor.b.david@gmail.com>
Reviewed by: jkim
MFC after: 3 weeks

13 years agogeneric_stop_cpus: prevent parallel execution
avg [Tue, 12 Oct 2010 17:40:45 +0000 (17:40 +0000)]
generic_stop_cpus: prevent parallel execution

This is based on the same approach as used in panic().
In theory parallel execution of generic_stop_cpus()  could lead to two CPUs
stopping each other and everyone else, and thus a total system halt.
Also, in theory, we should have some smarter locking here, because two
(or more CPUs) could be stopping unrelated sets of CPUs.
But in practice, it seems, this function is only used to stop
"all other" CPUs.

Additionally, I took this opportunity to make amd64-specific suspend_cpus()
function use generic_stop_cpus() instead of rolling out essentially
duplicate code.

This code is based on code by Sandvine Incorporated.

Suggested by: mdf
Reviewed by: jhb, jkim (earlier version)
MFC after: 2 weeks

13 years agotmpfs + sendfile: do not produce partially valid pages for vnode's tail
avg [Tue, 12 Oct 2010 17:16:51 +0000 (17:16 +0000)]
tmpfs + sendfile: do not produce partially valid pages for vnode's tail

See r213730 for details of analogous change in ZFS.

MFC after: 3 days

13 years agozfs + sendfile: do not produce partially valid pages for vnode's tail
avg [Tue, 12 Oct 2010 17:04:21 +0000 (17:04 +0000)]
zfs + sendfile: do not produce partially valid pages for vnode's tail

Since r212650 and before this change sendfile(2) could produce
a partially valid page for a trailing portion of a ZFS vnode.
vm_fault() always wants to see a fully valid page even if it's the last
page that partially extends beyond vnode's end.  Otherwise it calls
vop_getpages() to bring in the page.  In the case of ZFS this means
that the data is read from the page into the same page and this breaks
checks in ZFS mappedread() - a thread that set VPO_BUSY on the page in
vm_fault() will get blocked forever waiting for it to be cleared.

Many thanks to Kai and Jeremy for reproducing the issue and providing
important debugging information and help.

Reported by: Kai Gallasch <gallasch@free.de>,
Jeremy Chadwick <freebsd@jdc.parodius.com>
Tested by: Kai Gallasch <gallasch@free.de>,
Jeremy Chadwick <freebsd@jdc.parodius.com>
Reviewed by: kib
MFC after: 3 days
To-Do: apply the same treatment to tmpfs + sendfile

13 years agoFix monitor mode which is implemented by doing a firmware scan. This
bschmidt [Tue, 12 Oct 2010 16:52:13 +0000 (16:52 +0000)]
Fix monitor mode which is implemented by doing a firmware scan. This
is a port of stable/6, seems like the code got lost during the
background scan changes in r170530.

Pointed out by: danfe
MFC after: 2 weeks

13 years agoFormat prototypes to follow style(9) more closely.
jh [Tue, 12 Oct 2010 15:58:52 +0000 (15:58 +0000)]
Format prototypes to follow style(9) more closely.

Discussed with: kib, phk

13 years agoSmall grammar nit in a printf message.
joel [Tue, 12 Oct 2010 11:05:32 +0000 (11:05 +0000)]
Small grammar nit in a printf message.

13 years ago- Add support for xz compression to pkg_create, bzip2 remains the default
flz [Tue, 12 Oct 2010 10:04:44 +0000 (10:04 +0000)]
- Add support for xz compression to pkg_create, bzip2 remains the default
compression algorithm.
- Bump PKG_INSTALL_VERSION to 20101012.

Submitted by: mm
MFC after: 1 month

13 years agoWe already have dummy receive buffer in sc->buffer.
glebius [Tue, 12 Oct 2010 09:41:42 +0000 (09:41 +0000)]
We already have dummy receive buffer in sc->buffer.

Suggested by: hselasky

13 years agoAdd macro DECLARE_MODULE_TIED to denote a module as requiring the
kib [Tue, 12 Oct 2010 09:18:17 +0000 (09:18 +0000)]
Add macro DECLARE_MODULE_TIED to denote a module as requiring the
kernel of exactly the same __FreeBSD_version as the headers module was
compiled against.

Mark our in-tree ABI emulators with DECLARE_MODULE_TIED. The modules
use kernel interfaces that the Release Engineering Team feel are not
stable enough to guarantee they will not change during the life cycle
of a STABLE branch. In particular, the layout of struct sysentvec is
declared to be not part of the STABLE KBI.

Discussed with: bz, rwatson
Approved by: re (bz, kensmith)
MFC after: 2 weeks

13 years agoAdd a flag TDF_TIDHASH to prevent a thread from being
davidxu [Tue, 12 Oct 2010 00:36:56 +0000 (00:36 +0000)]
Add a flag TDF_TIDHASH to prevent a thread from being
added to or removed from thread hash table multiple times.

13 years agoCorrect regression test to not show a false positive when run as root.
obrien [Mon, 11 Oct 2010 23:24:57 +0000 (23:24 +0000)]
Correct regression test to not show a false positive when run as root.

13 years agoTry and make the nfsrv_localunlock() function in the experimental
rmacklem [Mon, 11 Oct 2010 23:15:18 +0000 (23:15 +0000)]
Try and make the nfsrv_localunlock() function in the experimental
NFSv4 server more readable. Mostly changes to comments, but a
case of >= is changed to >, since == can never happen. Also, I've
added a couple of KASSERT()s and a slight optimization, since
once the "else if" case happens, subsequent locks in the list can't
have any effect. None of these changes fixes any known bug.

MFC after: 2 weeks

13 years agoThe IFF_DRV_RUNNING flag is set at the end of bge_init_locked. But
yongari [Mon, 11 Oct 2010 23:07:12 +0000 (23:07 +0000)]
The IFF_DRV_RUNNING flag is set at the end of bge_init_locked. But
before setting the flag, interrupt was already enabled such that
interrupt handler could be run before setting IFF_DRV_RUNNING flag.
This can lose initial link state change interrupt which in turn
make bge(4) think that it still does not have valid link. Fix this
race by protecting the taskqueue with a driver lock.
While I'm here move reenabling interrupt code after handling of link
state chage.

Reviewed by: davidch

13 years agoRemove one last reference of BGE_MI_MODE register for auto polling.
yongari [Mon, 11 Oct 2010 22:56:23 +0000 (22:56 +0000)]
Remove one last reference of BGE_MI_MODE register for auto polling.
Previously bge(4) always enabled auto polling for non-BGE_FLAG_TBI
controllers. With this change, auto polling is not used anymore so
polling through mii(4) was introduced.

Reviewed by: davidch

13 years agoRe-work the internal user ioctl command table, and support the FW_UPLOAD
mdf [Mon, 11 Oct 2010 22:44:15 +0000 (22:44 +0000)]
Re-work the internal user ioctl command table, and support the FW_UPLOAD
command.

Reviewed by: ken (previous version)

13 years agoAdd function prototypes for static functions.
mdf [Mon, 11 Oct 2010 22:44:05 +0000 (22:44 +0000)]
Add function prototypes for static functions.

Requested by: ken

13 years agoAdd the XHCI USB controller to NOTES.
thompsa [Mon, 11 Oct 2010 21:53:03 +0000 (21:53 +0000)]
Add the XHCI USB controller to NOTES.

Reviewed by: hselasky

13 years agoFix a memory leak and locking inconsistency in mps(4) ioctl handling.
mdf [Mon, 11 Oct 2010 21:38:31 +0000 (21:38 +0000)]
Fix a memory leak and locking inconsistency in mps(4) ioctl handling.
Check copyin(9) for error and sanity check the length before copyin.

Reviewed by: ken

13 years agocamlib.c: update one overlooked comment
avg [Mon, 11 Oct 2010 21:34:35 +0000 (21:34 +0000)]
camlib.c: update one overlooked comment

13 years agoFix up the COMPAT_FREEBSD32 ioctl logic for mps(4).
mdf [Mon, 11 Oct 2010 21:26:24 +0000 (21:26 +0000)]
Fix up the COMPAT_FREEBSD32 ioctl logic for mps(4).

Reviewed by: ken

13 years agoUpgrade xz to git snapshot as of 20101010
mm [Mon, 11 Oct 2010 21:16:50 +0000 (21:16 +0000)]
Upgrade xz to git snapshot as of 20101010

Approved by: delphij (mentor)
MFC after: 1 month

13 years agoRemove two non-vendor files as recommended.
mm [Mon, 11 Oct 2010 20:34:35 +0000 (20:34 +0000)]
Remove two non-vendor files as recommended.

Approved by: delphij (mentor)

13 years agoFix reference to nonexistent manpage getuid(3).
ed [Mon, 11 Oct 2010 20:30:57 +0000 (20:30 +0000)]
Fix reference to nonexistent manpage getuid(3).

Submitted by: pluknet

13 years agoRemove stale reference to wtmp(5).
ed [Mon, 11 Oct 2010 20:17:23 +0000 (20:17 +0000)]
Remove stale reference to wtmp(5).

Reported by: pluknet

13 years agoDo not setup interrupt endpoint for axe(4).
yongari [Mon, 11 Oct 2010 19:20:53 +0000 (19:20 +0000)]
Do not setup interrupt endpoint for axe(4).
It seems axe(4) controllers support interrupt endpoint such that
enabling interrupt endpoint generates about 1000 interrupts/sec.
Controllers transfer 8 bytes data through interrupt endpoint and
the data include link UP/DOWN state as well as some PHY related
information. Previously axe(4) didn't use the transferred data and
didn't even try to read the data. Because axe(4) counts on mii(4)
to detect link state changes there is no need to use interrupt
endpoint here.

This change fixes generation of unnecessary interrupts which was
seen when interface is brought to UP.

No objections from: hselasky

13 years agoRemove more unneeded files and directories from contrib/llvm. This
dim [Mon, 11 Oct 2010 17:22:16 +0000 (17:22 +0000)]
Remove more unneeded files and directories from contrib/llvm.  This
still allows us to build tblgen and clang, and further reduces the
footprint in the tree.

Approved by: rpaulo (mentor)

13 years agoRework the analysis of the 'r' specifier. It turns out that we can't
rpaulo [Mon, 11 Oct 2010 17:18:23 +0000 (17:18 +0000)]
Rework the analysis of the 'r' specifier. It turns out that we can't
make it like xArg because they are different ('x' doesn't accept sign,
but 'r' does).
This fixes some warnings when building DDB with clang.

With help from: rdivacky

13 years agoAdd code to print the number and type of the CPU that is present in
gnn [Mon, 11 Oct 2010 14:31:24 +0000 (14:31 +0000)]
Add code to print the number and type of the CPU that is present in
the system as well has how many PMCs there are per CPU.  In this code
CPU and core are equivalent.

MFC after: 1 day

13 years agoVendor import of xz (stripped)
mm [Mon, 11 Oct 2010 12:43:51 +0000 (12:43 +0000)]
Vendor import of xz (stripped)
Git revision: d52b411716a614c202e89ba732492efb9916cd3f

Approved by: delphij (mentor)

13 years agocam_get_device, cam_open_device: make behavior simpler and more deterministic
avg [Mon, 11 Oct 2010 09:27:37 +0000 (09:27 +0000)]
cam_get_device, cam_open_device: make behavior simpler and more deterministic

Remove or re-work support for the several features from the past:
- remove incomplete support for trimming slice/partition names
- remove mapping from old device names "sd" and "st"
- remove whitespace trimming
- remove unconditional skipping of leading 'r' in a device name
- skip leading 'n' or 'e' only if the following device name matches
  a list of known devices that support no-rewind and eject-on-close
  features; currently this is only sa(4)
- reflect the above changes in comments in code and in cam(3)
- remove a note cautioning against use of cam_get_device and
  cam_open_device in cam(3)

Reviewed by: mjacob

13 years agoRestore the support for the 'r' and the 'y' conversion specifiers, first
rpaulo [Mon, 11 Oct 2010 08:10:12 +0000 (08:10 +0000)]
Restore the support for the 'r' and the 'y' conversion specifiers, first
added on r208987.
These are undocumented but are part of printf(9).

13 years agoFix compile with -DDEBUG by using the correct mfi_pd_ref union definition
randi [Sun, 10 Oct 2010 20:54:01 +0000 (20:54 +0000)]
Fix compile with -DDEBUG by using the correct mfi_pd_ref union definition
in mfireg.h.

Submitted by: gcooper
Reviewed by: jhb
Approved by: cperciva (mentor)
MFC after: 1 week

13 years agoProvide internal ioflags() function that converts ioflag provided by FreeBSD's
pjd [Sun, 10 Oct 2010 20:49:33 +0000 (20:49 +0000)]
Provide internal ioflags() function that converts ioflag provided by FreeBSD's
VFS to OpenSolaris-specific ioflag expected by ZFS. Use it for read and write
operations.

Reviewed by: mm
MFC after: 1 week

13 years agoReport subcommand handler errors in mfiutil/mptutil so that tools that
randi [Sun, 10 Oct 2010 20:37:38 +0000 (20:37 +0000)]
Report subcommand handler errors in mfiutil/mptutil so that tools that
invoke the utilities can robustly report errors.

Submitted by: gcooper
Reviewed by: jhb
Approved by: cperciva (mentor)
MFC after: 1 week

13 years ago- Print the nmount(2) provided error message only when it is set.
jh [Sun, 10 Oct 2010 09:24:19 +0000 (09:24 +0000)]
- Print the nmount(2) provided error message only when it is set.
- Ensure that the error message is NUL-terminated before printing it.

PR: bin/147482
MFC after: 2 weeks

13 years agoThe r184588 changed the layout of struct export_args, causing an ABI
kib [Sun, 10 Oct 2010 07:05:47 +0000 (07:05 +0000)]
The r184588 changed the layout of struct export_args, causing an ABI
breakage for old mount(2) syscall, since most struct <filesystem>_args
embed export_args. The mount(2) is supposed to provide ABI
compatibility for pre-nmount mount(8) binaries, so restore ABI to
pre-r184588.

Requested and reviewed by: bde
MFC after:    2 weeks

13 years agoReplace strlen(_PATH_DEV) with sizeof(_PATH_DEV) - 1.
ae [Sat, 9 Oct 2010 20:20:27 +0000 (20:20 +0000)]
Replace strlen(_PATH_DEV) with sizeof(_PATH_DEV) - 1.

Suggested by: kib
Approved by: kib (mentor)
MFC after: 5 days

13 years agomdoc: drop redundant .Pp calls, kill EOL whitespace
uqs [Sat, 9 Oct 2010 11:43:00 +0000 (11:43 +0000)]
mdoc: drop redundant .Pp calls, kill EOL whitespace

13 years agoadd kmem_map_free sysctl: query largest contiguous free range in kmem_map
avg [Sat, 9 Oct 2010 09:03:17 +0000 (09:03 +0000)]
add kmem_map_free sysctl: query largest contiguous free range in kmem_map

Suggested by: alc
Reviewed by: alc
MFC after: 1 week

13 years agoInitial patches to install images...
imp [Sat, 9 Oct 2010 08:52:09 +0000 (08:52 +0000)]
Initial patches to install images...

PR: 150921

13 years agoFix typo: thanks Kris for pointing this out.
imp [Sat, 9 Oct 2010 08:39:14 +0000 (08:39 +0000)]
Fix typo: thanks Kris for pointing this out.

13 years agopanic_cpu variable should be volatile
avg [Sat, 9 Oct 2010 08:07:49 +0000 (08:07 +0000)]
panic_cpu variable should be volatile

This is to prevent caching of its value in a register when it is checked
and modified by multiple CPUs in parallel.
Also, move the variable  into the scope of the only function that uses it.

Reviewed by: jhb
Hint from: mdf
MFC after: 1 week

13 years agoEnable softupdate + journals support.
imp [Sat, 9 Oct 2010 07:45:24 +0000 (07:45 +0000)]
Enable softupdate + journals support.

PR: 150862
Submitted by: Kris Moore

13 years agoAllow the kernel to generate more spacy things and still have devd
imp [Sat, 9 Oct 2010 07:29:13 +0000 (07:29 +0000)]
Allow the kernel to generate more spacy things and still have devd
cope.  Skip multiple spaces in a few contexts.

PR: 96854
Submitted by: Shin'ya Kumabuchi
MFC after: 1 week

13 years agoRemove the manpath.config entry now that it's no longer installed.
gordon [Sat, 9 Oct 2010 05:57:23 +0000 (05:57 +0000)]
Remove the manpath.config entry now that it's no longer installed.

Submitted by: b. f.
Approved by: wes (mentor implicit)

13 years agoAdd entries to remove manpath.config from etc and the examples directory.
gordon [Sat, 9 Oct 2010 05:50:04 +0000 (05:50 +0000)]
Add entries to remove manpath.config from etc and the examples directory.

Approved by: wes (mentor implicit)

13 years agoAdd -D (deterministic) option to ar.
kientzle [Sat, 9 Oct 2010 05:31:08 +0000 (05:31 +0000)]
Add -D (deterministic) option to ar.
When set, it forces all timestamps and owners to zero and
modes to 0644.  Useful for producing libraries that are
bitwise identical across multiple build runs.

Submitted by: Erik Cederstrand
Reviewed by: Kai Wang

13 years agoCreate a global thread hash table to speed up thread lookup, use
davidxu [Sat, 9 Oct 2010 02:50:23 +0000 (02:50 +0000)]
Create a global thread hash table to speed up thread lookup, use
rwlock to protect the table. In old code, thread lookup is done with
process lock held, to find a thread, kernel has to iterate through
process and thread list, this is quite inefficient.
With this change, test shows in extreme case performance is
dramatically improved.

Earlier patch was reviewed by: jhb, julian

13 years agoChange FAPPEND to IO_APPEND as this is a ioflag and not a fflag.
mm [Fri, 8 Oct 2010 23:01:38 +0000 (23:01 +0000)]
Change FAPPEND to IO_APPEND as this is a ioflag and not a fflag.
This corrects writing to append-only files on ZFS.

PR: kern/149495 [1], kern/151082 [2]
Submitted by: Daniel Zhelev <daniel@zhelev.biz> [1], Michael Naef <cal@linu.gs> [2]
Approved by: delphij (mentor)
MFC after: 1 week

13 years agoDocument net.link.lagg.failover_rx_all.
delphij [Fri, 8 Oct 2010 21:29:48 +0000 (21:29 +0000)]
Document net.link.lagg.failover_rx_all.

MFC after: 1 week

13 years agoRemove superfluous cast in usr.bin/netstat/sctp.c.
dim [Fri, 8 Oct 2010 20:40:05 +0000 (20:40 +0000)]
Remove superfluous cast in usr.bin/netstat/sctp.c.

Found by: clang
Submitted by: Norberto Lopes, nlopes dot ml at gmail dot com
Approved by: rpaulo (mentor)

13 years agoDon't let the "available"/"not available" logs flap quite so badly. In the
markm [Fri, 8 Oct 2010 20:17:17 +0000 (20:17 +0000)]
Don't let the "available"/"not available" logs flap quite so badly. In the
case of a multi-interfaced host, sub-second flapping can fill up the logs
too quickly. This fixes that.

13 years agoExtend the "example" section a bit, for other mailers.
markm [Fri, 8 Oct 2010 20:13:12 +0000 (20:13 +0000)]
Extend the "example" section a bit, for other mailers.

13 years agoDo not blindly UP the interface when interface's MTU is changed. If
yongari [Fri, 8 Oct 2010 17:58:07 +0000 (17:58 +0000)]
Do not blindly UP the interface when interface's MTU is changed. If
driver is not running there is no need to up the interface. While
I'm here hold driver lock before modifying MTU as it is referenced
in RX handler.

13 years agoDon't blow away /bin/rmail symlink if we are keeping mailwrapper.
markm [Fri, 8 Oct 2010 17:42:09 +0000 (17:42 +0000)]
Don't blow away /bin/rmail symlink if we are keeping mailwrapper.
Mailwrapper can provide a perfectly good rmail with other
mailers.

13 years agorm(1): clarify that -P works only when blocks are updated in-place
uqs [Fri, 8 Oct 2010 15:20:20 +0000 (15:20 +0000)]
rm(1): clarify that -P works only when blocks are updated in-place

Suggested by: pjd, ivoras, arundel

13 years agoWe can't zero out ggio request, as we have some fields in there we initialize
pjd [Fri, 8 Oct 2010 15:05:39 +0000 (15:05 +0000)]
We can't zero out ggio request, as we have some fields in there we initialize
once during start-up.

Reported by: Mikolaj Golub <to.my.trociny@gmail.com>
MFC after: 3 days

13 years agoWe close the event socketpair early in the mainloop to prevent spaming with
pjd [Fri, 8 Oct 2010 15:02:15 +0000 (15:02 +0000)]
We close the event socketpair early in the mainloop to prevent spaming with
error messages, so when we clean up after child process, we have to check if
the event socketpair is still there.

Submitted by: Mikolaj Golub <to.my.trociny@gmail.com>
MFC after: 3 days

13 years agoIn the replacement text of the __bswapN_const() macros cast the argument
marius [Fri, 8 Oct 2010 14:59:45 +0000 (14:59 +0000)]
In the replacement text of the __bswapN_const() macros cast the argument
to the expected type so they work like the corresponding __bswapN_var()
functions and the compiler doesn't complain when arguments of different
width are passed.

13 years agoJust use the sparc64 version of this header rather than duplicating it.
marius [Fri, 8 Oct 2010 14:50:58 +0000 (14:50 +0000)]
Just use the sparc64 version of this header rather than duplicating it.

13 years agoClean up tools in tools/tools/netrate.
pluknet [Fri, 8 Oct 2010 14:31:49 +0000 (14:31 +0000)]
Clean up tools in tools/tools/netrate.

- tcpconnect incorrectly uses err() in usage() with errx() semantics [1]
  That produces dirty error message:
  tcpconnect: usage: tcpconnect [ip]: Unknown error: 0
- 64-bit aware fixes in printf() usage [2]
o   netrate/juggle: time_t has arch-dependent size
o   netrate/tcpconnect: don't assume %ll has always 64bit.

PR: 146088 [1], 146086 [2] (modified)
Approved by: kib (mentor)
MFC after: 1 week

13 years agomdoc: drop redundant .Pp and .LP calls
uqs [Fri, 8 Oct 2010 12:40:16 +0000 (12:40 +0000)]
mdoc: drop redundant .Pp and .LP calls

They have no effect when coming in pairs, or before .Bl/.Bd

13 years agomdoc: fix manlint warnings by unbreaking mdoc syntax
uqs [Fri, 8 Oct 2010 12:39:49 +0000 (12:39 +0000)]
mdoc: fix manlint warnings by unbreaking mdoc syntax

13 years agoEnsure that a make from sys/boot does not pick up include files from
pho [Fri, 8 Oct 2010 10:27:52 +0000 (10:27 +0000)]
Ensure that a make from sys/boot does not pick up include files from
/usr/include.

Discussed with:  kib

13 years agoImport ee 1.5.2 into HEAD.
ed [Fri, 8 Oct 2010 09:43:06 +0000 (09:43 +0000)]
Import ee 1.5.2 into HEAD.

PR: bin/145921
MFC after: 2 weeks

13 years agoRegen.
kib [Fri, 8 Oct 2010 07:19:05 +0000 (07:19 +0000)]
Regen.

13 years agoFix typo.
kib [Fri, 8 Oct 2010 07:18:44 +0000 (07:18 +0000)]
Fix typo.

Submitted by: arundel
MFC after: 3 days

13 years agoAdd a comment describing the reason for calling cache_purge(fvp).
kib [Fri, 8 Oct 2010 07:17:22 +0000 (07:17 +0000)]
Add a comment describing the reason for calling cache_purge(fvp).

Requested by: danfe
MFC after: 6 days

13 years agoOops, don't remove -fexceptions flag.
davidxu [Fri, 8 Oct 2010 01:53:33 +0000 (01:53 +0000)]
Oops, don't remove -fexceptions flag.

13 years agounwind.h was imported, gcc directory is no longer needed.
davidxu [Fri, 8 Oct 2010 01:47:14 +0000 (01:47 +0000)]
unwind.h was imported, gcc directory is no longer needed.

13 years agoIn r207768 I silenced a console warning from rum(4). There was legitimate
emaste [Fri, 8 Oct 2010 01:03:30 +0000 (01:03 +0000)]
In r207768 I silenced a console warning from rum(4).  There was legitimate
opposition to the change, since really we need to implement missing
functionality in drivers or the 802.3 layer.

For now, restore a reminder message for a missing rum_update_mcast, but
print it only once.

13 years agoMake a thread's address available via the kern proc sysctl, just like the
emaste [Fri, 8 Oct 2010 00:44:53 +0000 (00:44 +0000)]
Make a thread's address available via the kern proc sysctl, just like the
process address.

Add "tdaddr" keyword to ps(1) to display this thread address.

Distilled from Sandvine's patch set by Mark Johnston.

13 years agoTurn on serialization of task management commands going down to the
ken [Thu, 7 Oct 2010 21:56:10 +0000 (21:56 +0000)]
Turn on serialization of task management commands going down to the
controller, but make it optional.

After a problem report from Andrew Boyer, it looks like the LSI
chip may have issues (the watchdog timer fired) if too many aborts
are sent down to the chip at the same time.  We know that task
management commands are serialized, and although the manual doesn't
say it, it may be a good idea to just send one at a time.

But, since I'm not certain that this is necessary, add a tunable
and sysctl variable (hw.mps.%d.allow_multiple_tm_cmds) to control
the driver's behavior.

mps.c: Add support for the sysctl and tunable, and add a
comment about the possible return values to
mps_map_command().

mps_sas.c: Run all task management commands through two new
routines, mpssas_issue_tm_request() and
mpssas_complete_tm_request().

This allows us to optionally serialize task
management commands.  Also, change things so that
the response to a task management command always
comes back through the callback.  (Before it could
come via the callback or the return value.)

mpsvar.h: Add softc variables for the list of active task
management commands, the number of active commands,
and whether we should allow multiple active task
management commands.  Add an active command flag.

mps.4: Describe the new sysctl/loader tunable variable.

Sponsored by: Spectra Logic Corporation

13 years agoUpgrade Clang and LLVM to the 2.8 release. See here for release notes:
dim [Thu, 7 Oct 2010 20:31:07 +0000 (20:31 +0000)]
Upgrade Clang and LLVM to the 2.8 release.  See here for release notes:
http://llvm.org/releases/2.8/docs/ReleaseNotes.html

Approved by: rpaulo (mentor)