Commit Graph

189077 Commits

Author SHA1 Message Date
John Baldwin
9941de49ad Don't leak the TCP pcbinfo lock if a time wait connection is closed
in between grabbing a reference on the connection structure and obtaining
the pcbinfo lock.

Reviewed by:	Julien Charbon
2014-04-11 13:11:43 +00:00
Alexander Motin
f6e1dc83c3 Create zvol devices on zfs clone.
While big and shiny patch is not ready, it is better to have something.

PR:		kern/178999
MFC after:	1 week
2014-04-11 11:56:16 +00:00
Hans Petter Selasky
67eb1bdac2 Correct IMOD default value according to comment.
Reported by:	Daniel O'Connor <doconnor@gsoft.com.au>
MFC after:	1 week
2014-04-11 08:25:54 +00:00
Justin Hibbits
181ca73b1a Small performance optimization. Clobber only cr0, rather than the entire CR.
Discussed with:	rdivacky,nwhitehorn
MFC after:	3 weeks
2014-04-11 06:17:44 +00:00
Marius Strobl
bdc8dbd208 Refine r264257; given that I later on decided to nuke the wildcard for
the Sunix 0x1999 line of chips there actually is no need to explicitly
keep puc(4) from attaching to the single port version anymore.
2014-04-10 21:03:46 +00:00
Peter Grehan
201b1ccc22 Rework r264179.
- remove redundant code
- remove erroneous setting of the error return
  in vmmdev_ioctl()
- use style(9) initialization
- in vmx_inject_pir(), document the race condition
  that the final conditional statement was detecting,

Tested with both gcc and clang builds.

Reviewed by:	neel
2014-04-10 19:15:58 +00:00
Bruce M Simpson
d565e5f206 In if_freemulti(), relax the paranoid KASSERT() on ifma->ifma_protospec.
This KASSERT() existed as a sanity check that upper layers in the network
stack (e.g. inet, inet6) had released their reference to the underlying
driver's multicast memberships (ifmultiaddr{}). However it assumes the
lifecycle of the driver membership corresponds to the lifecycle of the
network layer membership.

In the submitter's case, ieee80211_ioctl_updatemulti() attempts to
reprogram the (parent, physical) ifnet{} memberships in response
to a change in membership on the (child, virtual) VAP ifnet, using
a batched update mechanism. These updates happen independently from
the network layer, causing a "false negative" assertion failure.

There are possibly other use cases where this KASSERT() may be triggered
by other networking stack activity (e.g. where a nesting relationship
exists between multiple ifnet{} instances). This suggests that further
review of FreeBSD's approach to nested ifnet relationships is needed.

MFC after:	6 weeks
Submitted by:	adrian@
2014-04-10 18:43:02 +00:00
Johannes Jost Meixner
606b39f1e0 - Adding myself to the committers-ports.dot
- Adding myself to the freebsd calendar

Approved by: swills (mentor)
2014-04-10 18:34:26 +00:00
John Baldwin
66eefb1eae Currently, the TCP slow timer can starve TCP input processing while it
walks the list of connections in TIME_WAIT closing expired connections
due to contention on the global TCP pcbinfo lock.

To remediate, introduce a new global lock to protect the list of
connections in TIME_WAIT.  Only acquire the TCP pcbinfo lock when
closing an expired connection.  This limits the window of time when
TCP input processing is stopped to the amount of time needed to close
a single connection.

Submitted by:	Julien Charbon <jcharbon@verisign.com>
Reviewed by:	rwatson, rrs, adrian
MFC after:	2 months
2014-04-10 18:15:35 +00:00
Bryan Drewery
1e4b22b44b Fix spelling error in g_trace() call.
Sponsored by:	EMC / Isilon Storage Division
MFC after:	1 week
2014-04-10 17:00:44 +00:00
Ed Maste
7a5f5e3794 Fix EFI loader object tree creation on 9.x build hosts
Previously ${COMPILER_TYPE} was checked in sys/boot/amd64, and the efi
subdirectory was skipped altogether for gcc (since GCC does not support
a required attribute).  However, during the early buildworld stages
${COMPILER_TYPE} is the existing system compiler (i.e., gcc on 9.x build
hosts), not the compiler that will eventually be used.  This caused
"make obj" to skip the efi subdirectory.  In later build stages
${COMPILER_TYPE} is "clang", and then the efi loader would attempt to
build in the source directory.

Sponsored by:	The FreeBSD Foundation
2014-04-10 16:53:21 +00:00
Alexander Motin
1229e83d2b Fix wrong sizes used to access PD_Type and PD_State DDF metadata fields.
This caused incorrect behavior of arrays with big-endian DDF metadata.
Little-endian (like used by Adaptec controllers) should not be harmed.
Add workaround should be enough to manage compatibility.

MFC after:	2 weeks
2014-04-10 16:00:33 +00:00
Kevin Lo
ed8023f58b Add the Asus USB-N10 NANO.
Tested by:	Kuan-Chung Chiu <buganini@gmail.com>
2014-04-10 14:37:37 +00:00
Christian Brueffer
3d11dc42ab Fix stray "." left over from previous commit.
MFC after:	1 week
2014-04-10 10:56:11 +00:00
Christian Brueffer
d043fece6e Fix Xref order in SEE ALSO.
MFC after:	1 week
2014-04-10 10:54:06 +00:00
Christian Brueffer
796b4eb567 More mdoc/spelling/grammar cleanup. 2014-04-10 10:18:30 +00:00
Alexander Motin
66b92c07fe Do not increment bio_data in case of BIO_DELETE.
This fixes KASSERT() panic in g_io_request().
2014-04-10 10:12:56 +00:00
Steven Hartland
43d0f063c2 Fix build breakage caused by r264295
X-MFC-With: r264295
MFC after:	1 week
2014-04-10 05:04:23 +00:00
David Xu
7d62aec6fe Add kqueue support for devctl.
Reviewed by:	kib,mjg
2014-04-10 02:30:51 +00:00
Dag-Erling Smørgrav
b8f726b41c Restore the pX part to the version number printed in debugging mode. 2014-04-09 20:42:00 +00:00
Alexander Motin
7081bb15b0 Fix three refcounter leaks and lock recursion they covered.
MFC after:	1 week
2014-04-09 19:16:40 +00:00
Sean Bruno
84cb72d1c6 Really, really, really only allow this option for amd64/i386 builds.
Submitted by:	imp@ and tinderbox
2014-04-09 18:44:54 +00:00
Tycho Nightingale
8b4a7f857b Constrain the amount of data returned to what is actually available
not the size of the buffer.

Approved by:	grehan (co-mentor)
2014-04-09 14:50:55 +00:00
Alexander Motin
004008d6e6 Introduce new serialization type CTL_SERIDX_UNMAP.
Unfortunately we can't check range collisions for UNMAP commands alike
to writes, because they include multiple ranges, which are also passed
in data block, not in CDB.  As result, UNMAP commands have to be treated
as colliding with any other command accessing the media.

From the other side all UNMAPs are equal (we don't support ANCHOR flag),
so we can execute several UNMAPs same time.
2014-04-09 10:58:52 +00:00
Alexander Motin
8f5a226a3c When splitting huge unmap requests, do it on sector boundary. 2014-04-09 10:44:09 +00:00
Alexander Motin
b8a8ed5664 Remove support of LUN-based CD changers from cd(4) driver.
This code was heavily broken few months ago during CAM locking changes.
Fixing it would require almost complete rewrite.  Since there are no
known devices on market using this interface younger then ~15 years, and
they are CD, not even DVD, I don't see much reason to rewrite it.

This change does not mean those devices won't work.  They will just work
slower due to inefficient disks load/unload schedule if several LUNs
accessed same time.

Discussed with:	ken@
Silence on:	scsi@, hardware@
MFC after:	1 week
2014-04-09 08:57:57 +00:00
Hans Petter Selasky
a955cde712 Fix for infinite XHCI reset loops when the set address USB request fails.
MFC after:	2 days
2014-04-09 06:27:04 +00:00
Pyun YongHyeon
a173db2d8c Add workaround for MCP61 Ethernet controller found on MSI K9
motherboard.  PHY hardware used for the controller responded at
all possible addresses which in turn resulted in having 32 PHYs
for the controller.  If driver detects "MSI K9N6PGM2-V2 (MS-7309)"
motherboard, tell miibus(4) PHY is located at 0.

Tested by:	Chris H
2014-04-09 05:15:40 +00:00
Adrian Chadd
6ed22fae0a Add a function to check whether the given register can be accessed whilst
the chip is asleep.

It's AR5416 and later specific; I'll add a HAL method to generalise it
later.

Tested:

* AR5416, STA mode
2014-04-09 03:51:05 +00:00
Sean Bruno
4ab550cafe Spell imgact_binmisc correctly 2014-04-09 03:46:04 +00:00
Peter Wemm
eccee15da4 Bump osreldate for tracking SA-14:06 2014-04-09 01:26:58 +00:00
Alexander Motin
7e0be0226f Another fix for r264274. Last moment cosmetic changes are evil! 2014-04-08 22:36:39 +00:00
Sean Bruno
b888dae4c8 sys/kern/imgact_binmisc.c -- free the right pointer mask vs magic
sys/sys/imagact_binmisc.h -- cleanup white space tabs vs spaces
                          -- remove stray " in comment

Submitted by:	jmallett@
2014-04-08 22:12:01 +00:00
Warner Losh
9329931e3f Also ignore files from Murcirial (.hg) and git (.git) when copying
file trees.
2014-04-08 21:58:04 +00:00
Sean Bruno
b434acb306 Actually, since this is what I thought I was doing, only allow the
binmisc code to be build on amd64/i386 for the kernel.

Update NOTES with some indication of what this code is used for.

Pointed out by jhb@ ... thanks!

Submitted by:	jhb@
2014-04-08 21:39:51 +00:00
Alexander Motin
f7ad1c4625 Oops! Few quick fixes for r264274. 2014-04-08 21:30:10 +00:00
Jung-uk Kim
560ede85d4 Merge OpenSSL 1.0.1g.
Approved by:	benl (maintainer)
2014-04-08 21:06:58 +00:00
John Baldwin
2cf4f7ef79 Handle single-byte reads from the bvmcons port (0x220) by returning
0xff.  Some guests may attempt to read from this port to identify
psuedo-PNP ISA devices.  (The ie(4) driver in FreeBSD/i386 is one
example.)

Reviewed by:	grehan
2014-04-08 21:02:03 +00:00
Christian Brueffer
1f0283145c Quick mdoc/whitespace/spelling pass, this needs some more work. 2014-04-08 20:59:02 +00:00
John Baldwin
96c2ac37d3 Explicitly initialize 'vmname' to NULL.
Reviewed by:	grehan
2014-04-08 20:54:13 +00:00
Alexander Motin
ee7f31c068 Add support for SCSI UNMAP commands to CTL.
This patch adds support for three new SCSI commands: UNMAP, WRITE SAME(10)
and WRITE SAME(16).  WRITE SAME commands support both normal write mode
and UNMAP flag.  To properly report UNMAP capabilities this patch also adds
support for reporting two new VPD pages: Block limits and Logical Block
Provisioning.

UNMAP support can be enabled per-LUN by adding "-o unmap=on" to `ctladm
create` command line or "option unmap on" to lun sections of /etc/ctl.conf.

At this moment UNMAP supported for ramdisks and device-backed block LUNs.
It was tested to work great with ZFS ZVOLs.  For file-backed LUNs UNMAP
support is unfortunately missing due to absence of respective VFS KPI.

Reviewed by:	ken
MFC after:	1 month
Sponsored by:	iXsystems, Inc
2014-04-08 20:50:48 +00:00
Jung-uk Kim
06369e3974 Import OpenSSL 1.0.1g.
Approved by:	benl (maintainer)
2014-04-08 20:15:18 +00:00
Warner Losh
5e9d46791b Put proper ${} around variable expansion. This fixes the build on 9.2
with fmake (which complained). Not sure why bmake didn't complain though...
2014-04-08 20:10:57 +00:00
Sean Bruno
6d75644981 Add Stacey Son's binary activation patches that allow remapping of
execution to a emumation program via parsing of ELF header information.

With this kernel module and userland tool, poudriere is able to build
ports packages via the QEMU userland tools (or another emulator program)
in a different architecture chroot, e.g. TARGET=mips TARGET_ARCH=mips

I'm not connecting this to GENERIC for obvious reasons, but this should
allow the kernel module to be built by default and enable the building
of the userland tool (which automatically loads the kernel module).

Submitted by:	sson@
Reviewed by:	jhb@
2014-04-08 20:10:22 +00:00
Ed Maste
9e61717ac8 (Re)connect sys/boot/amd64 to the build
Sponsored by:	The FreeBSD Foundation
2014-04-08 19:19:58 +00:00
Xin LI
25bfde79d6 Fix NFS deadlock vulnerability. [SA-14:05]
Fix "Heartbleed" vulnerability and ECDSA Cache Side-channel
Attack in OpenSSL. [SA-14:06]
2014-04-08 18:27:32 +00:00
Alexander Motin
1fa3ca3ca7 Wakeup only one thread of added in r263978i at a time.
This slightly reduces lock congestion between threads.

Submitted by:	trasz
2014-04-08 18:22:03 +00:00
Ed Maste
b900a57189 Add explicit casts to quiet warnings in libefi
Sponsored by:	The FreeBSD Foundation
2014-04-08 18:21:38 +00:00
Ed Maste
f58d027be1 Fix printf args for 64-bit archs
Sponsored by:	The FreeBSD Foundation
2014-04-08 18:02:32 +00:00
Ed Maste
6cf1ada9e1 Correct a variable's type for 64-bit Ficl
FICL_INT is long.
2014-04-08 17:50:27 +00:00