summaryrefslogtreecommitdiff
path: root/sys
Commit message (Collapse)AuthorAgeFilesLines
...
* MFC 252576:John Baldwin2013-07-172-10/+7
| | | | | | | | | | | | | | | | | Don't perform the acpi_DeviceIsPresent() check for PCI-PCI bridges. If we are probing a PCI-PCI bridge it is because we found one by enumerating the devices on a PCI bus, so the bridge is definitely present. A few BIOSes report incorrect status (_STA) for some bridges that claimed they were not present when in fact they were. While here, move this check earlier for Host-PCI bridges so attach fails before doing any work that needs to be torn down. PR: kern/91594 Approved by: re (marius) Notes: svn path=/stable/9/; revision=253426
* MFC r253141:Konstantin Belousov2013-07-171-1/+3
| | | | | | | | | | When panicing due to the gjournal overflow, print the geom metadata journal id. Approved by: re (rodrigc) Notes: svn path=/stable/9/; revision=253415
* MFC r253079: dtrace/fasttrap: install hook functions only after all dataAndriy Gapon2013-07-161-7/+7
| | | | | | | | | is initialized Approved by: re (marius) Notes: svn path=/stable/9/; revision=253394
* MFC r253078: audit_proc_coredump: check return value of audit_newAndriy Gapon2013-07-161-0/+2
| | | | | | | Approved by: re (kib) Notes: svn path=/stable/9/; revision=253388
* MFC r253075: namecache sdt: freebsd doesn't support structuredAndriy Gapon2013-07-161-2/+2
| | | | | | | | | characters yet Approved by: re (kib) Notes: svn path=/stable/9/; revision=253382
* MFC r253094:Konstantin Belousov2013-07-162-6/+18
| | | | | | | | | Use MSI for xhci(4), if supported. Approved by: re (delphij) Notes: svn path=/stable/9/; revision=253379
* MFC: r253284, r253285, r253303:Jack F Vogel2013-07-157-14/+41
| | | | | | | | | | | | Correct the Intel network driver module builds. They were not defining INET or INET6, and in the case of ixgbe this will cause a panic in the TSO setup code, but in all cases the ioctl behavior is different, this change makes the module and static consistent. Approved by: re Notes: svn path=/stable/9/; revision=253374
* Merge r244451 from head (originally by pjd):Gavin Atkinson2013-07-151-1/+1
| | | | | | | | | | | Use correct file permissions when looking for available core file if kern.corefile contains %I. Discussed with: pjd (some time ago) Approved by: re (kib) Notes: svn path=/stable/9/; revision=253373
* MFC of 253330Matt Jacob2013-07-152-3/+14
| | | | | | | | | | | | | | | | When fiddling with options of which registers to copy out for a mailbox command and which registers to copy back in when the command completes, the bits being set need to not only specify what bits you want to add from the default from the table but also what bits you want *subtract* (mask) from the default from the table. A failing ISP2200 command pointed this out. Approved by: re Notes: svn path=/stable/9/; revision=253371
* MFC r253274 and r253368:Kenneth D. Merry2013-07-151-8/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r253274 | ken | 2013-07-12 11:09:50 -0600 (Fri, 12 Jul 2013) | 40 lines Fix a problem with READ ELEMENT STATUS that occurs on some changers that don't support the DVCID and CURDATA bits that were introduced in the SMC spec. These changers will return an Illegal Request type error if the bits are set. This causes "chio status" to fail. The fix is two-fold. First, for changers that claim to be SCSI-2 or older, don't set the DVCID and CURDATA bits for READ ELEMENT STATUS. For newer changers (SCSI-3 and newer), we default to setting the new bits, but back off and try the READ ELEMENT STATUS without the bits if we get an Illegal Request type error. This has been tested on a Qualstar TLS-8211, which is a SCSI-2 changer that does not support the new bits, and a Spectra T-380, which is a SCSI-3 changer that does support the new bits. In the absence of a SCSI-3 changer that does not support the bits, I tested that with some error injection code. (The SMC spec says that support for CURDATA is mandatory, and DVCID is optional.) scsi_ch.c: Add a new quirk, CH_Q_NO_DVCID that gets set for SCSI-2 and older libraries, or newer libraries that report errors when the DVCID/CURDATA bits are set. In chgetelemstatus(), use the new quirk to determine whether or not to set DVCID and CURDATA. If we get an error with the bits set, back off and try without the bits. Set the quirk flag if the read element status succeeds without the bits set. Increase the READ ELEMENT STATUS timeout to 60 seconds after testing with a Spectra T-380. The previous value was 10 seconds, and too short for the T-380. This may be decreased later after some additional testing and investigation. Tested by: Andre Albsmeier <Andre.Albsmeier@siemens.com> Sponsored by: Spectra Logic ------------------------------------------------------------------------ r253368 | ken | 2013-07-15 10:38:48 -0600 (Mon, 15 Jul 2013) | 5 lines Fix an argument reversal in calls to scsi_read_element_status(). Reported by: Ulrich Spoerlein <uqs@FreeBSD.org> Approved by: re (kib) Notes: svn path=/stable/9/; revision=253369
* MFC r253209:Jim Harris2013-07-151-3/+3
| | | | | | | | | Fix a poorly worded comment in nvme(4). Approved by: re (kib) Notes: svn path=/stable/9/; revision=253366
* MFC r235899:Alexander Motin2013-07-151-3/+4
| | | | | | | | | Hide warning behind bootverbose. Average user has nothing to do about it. Approved by: re (marius) Notes: svn path=/stable/9/; revision=253359
* MFC of 252527:Kirk McKusick2013-07-132-3/+25
| | | | | | | | | | | Make better use of metadata area by avoiding using it for data blocks that no should no longer immediately follow their indirect blocks. Reviewed by: Bruce Evans Approved by: re (marius@) Notes: svn path=/stable/9/; revision=253324
* MFC r253113:Jim Harris2013-07-121-0/+4
| | | | | | | | | | Add comment explaining why CACHE_LINE_SIZE is defined in nvme_private.h if not already defined elsewhere. Approved by: re (kib) Notes: svn path=/stable/9/; revision=253297
* MFC r253112:Jim Harris2013-07-1210-10/+10
| | | | | | | | | Update copyright dates. Approved by: re (kib) Notes: svn path=/stable/9/; revision=253296
* MFC r253108:Jim Harris2013-07-121-5/+5
| | | | | | | | | Do not retry failed async event requests. Approved by: re (kib) Notes: svn path=/stable/9/; revision=253295
* MFC r253107:Jim Harris2013-07-121-0/+3
| | | | | | | | | | Add pci_enable_busmaster() and pci_disable_busmaster() calls in nvme_attach() and nvme_detach() respectively. Approved by: re (kib) Notes: svn path=/stable/9/; revision=253294
* MFC r252294 and r252295:Remko Lodder2013-07-122-0/+3
| | | | | | | | | | | | Add support for the NTT Docomo L-02C Card PR: 180017 Submitted by: Masaharu FUJITA Glanced at by: imp Approved by: re (delphij) Notes: svn path=/stable/9/; revision=253292
* MFC r252710:Mikolaj Golub2013-07-125-20/+31
| | | | | | | | | | | | | | | | | | | | | | | | | In r227207, to fix the issue with possible NULL inp_socket pointer dereferencing, when checking for SO_REUSEPORT option (and SO_REUSEADDR for multicast), INP_REUSEPORT flag was introduced to cache the socket option. It was decided then that one flag would be enough to cache both SO_REUSEPORT and SO_REUSEADDR: when processing SO_REUSEADDR setsockopt(2), it was checked if it was called for a multicast address and INP_REUSEPORT was set accordingly. Unfortunately that approach does not work when setsockopt(2) is called before binding to a multicast address: the multicast check fails and INP_REUSEPORT is not set. Fix this by adding INP_REUSEADDR flag to unconditionally cache SO_REUSEADDR. PR: 179901 Submitted by: Michael Gmelin freebsd grem.de (initial version) Reviewed by: rwatson Approved by: re (kib) Notes: svn path=/stable/9/; revision=253281
* MFC: r240981, r240990, r240992, r244695Marius Strobl2013-07-121-14/+222
| | | | | | | | | | | | | Add 32-bit ABI compat shims. Those are necessary for i386 binary-only tools like sysutils/hpacucli (HP P4xx RAID controller management suite) working on amd64 systems. PR: 139271 Submitted by: Kazumi MORINAGA, Eugene Grosbein Approved by: re (kib) Notes: svn path=/stable/9/; revision=253278
* MFC: r253120Marius Strobl2013-07-124-36/+77
| | | | | | | | | | | | | | | | | | | | - As it turns out, not only MSI-X is broken for devices passed through by VMware up to at least ESXi 5.1. Actually, using INTx in that case instead may still result in interrupt storms, with MSI being the only working option in some configurations. So introduce a PCI_QUIRK_DISABLE_MSIX quirk which only blacklists MSI-X but not also MSI and use it for the VMware PCI-PCI-bridges. Note that, currently, we still assume that if MSI doesn't work, MSI-X won't work either - but that's part of the internal logic and not guaranteed as part of the API contract. While at it, add and employ a pci_has_quirk() helper. Reported and tested by: Paul Bucher - Use NULL instead of 0 for pointers. Submitted by: jhb (mostly) Approved by: re (hrs), jhb Notes: svn path=/stable/9/; revision=253273
* MFC r253099:Michael Tuexen2013-07-121-2/+2
| | | | | | | | | | Use IPSECSTAT_INC() and IPSEC6STAT_INC() macros for ipsec statistics accounting. Approved by: re@ Notes: svn path=/stable/9/; revision=253263
* MFC r251282:Konstantin Belousov2013-07-121-1/+2
| | | | | | | | | | | | | | | | When auto-sizing the buffer cache, limit the amount of physical memory used as the estimation of size, to 16GB. This provides around 100K of buffer headers and corresponding KVA for buffer map at the peak. Sizing the cache larger is not useful, also resulting in the wasting and exhausting of KVA for large machines. MFC note: the commit message was adjusted to match the code change, the sizing cap is for 16GB, as noted by delphij. Approved by: re (delphij) Notes: svn path=/stable/9/; revision=253259
* MFC r253095:Konstantin Belousov2013-07-121-1/+1
| | | | | | | | | Fix typo in comment. Approved by: re (hrs) Notes: svn path=/stable/9/; revision=253257
* MFC r245066Peter Grehan2013-07-121-0/+1
| | | | | | | | | | | | | | | ------------------------------------------------------------------------- Teach the kernel to recognize that it is executing inside a bhyve virtual machine. ------------------------------------------------------------------------- This will help a 9.2 guest to run more effectively as a bhyve guest. Reviewed by: neel Approved by: re Notes: svn path=/stable/9/; revision=253250
* MFC r253134:Pyun YongHyeon2013-07-121-0/+6
| | | | | | | | Avoid controller reinitialization which could be triggered by dhclient(8) or alias addresses are added. Notes: svn path=/stable/9/; revision=253245
* MFC r251516Sean Bruno2013-07-121-0/+4
| | | | | | | | | Implement foreign device handling. PR: kern/172091 Notes: svn path=/stable/9/; revision=253244
* MFC 232379, 252511, 252548, 253060:Hiroki Sato2013-07-127-44/+167
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - Allow to configure net.inet6.ip6.{accept_rtadv,no_radr} by the loader tunables as well because they have to be configured before interface initialization for AF_INET6. - Allow ND6_IFF_AUTO_LINKLOCAL for IFT_BRIDGE. An interface with IFT_BRIDGE is initialized with !ND6_IFF_AUTO_LINKLOCAL && !ND6_IFF_ACCEPT_RTADV regardless of net.inet6.ip6.accept_rtadv and net.inet6.ip6.auto_linklocal. To configure an autoconfigured link-local address (RFC 4862), the following rc.conf(5) configuration can be used: ifconfig_bridge0_ipv6="inet6 auto_linklocal" - if_bridge(4) now removes IPv6 addresses on a member interface to be added when the parent interface or one of the existing member interfaces has an IPv6 address. if_bridge(4) merges each link-local scope zone which the member interfaces form respectively, so it causes address scope violation. Removal of the IPv6 addresses prevents it. - if_lagg(4) now removes IPv6 addresses on a member interfaces unconditionally. - Set reasonable flags to non-IPv6-capable interfaces. Notes: svn path=/stable/9/; revision=253239
* MFC r253050:Pedro F. Giffuni2013-07-111-9/+20
| | | | | | | | | | | | Enhancement when writing an entire block of a file (from UFS r231313). This change first attempts the uiomove() to the newly allocated (and dirty) buffer and only zeros it if the uiomove() fails. The effect is to eliminate the gratuitous zeroing of the buffer in the usual case where the uiomove() successfully fills it. Notes: svn path=/stable/9/; revision=253218
* - Set stable/9 branch to -PRERELEASE status.Glen Barber2013-07-111-2/+2
| | | | | | | | | | - Add 9.2 mdoc(7) macro. Approved by: re (implicit) Approved by: kib (mentor) Notes: svn path=/stable/9/; revision=253216
* MFC r245910,r247370,r249371,r252492,r252586:Warren Block2013-07-112-0/+239
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | r252586: Add descriptions to the FILES list, fix some mdoc complaints, move the "neither" entry out of the table in BOOTING. r252492: Add a new gptboot(8) man page. Factor out the redundant information in gpart(8) and boot(8), adding references to gptboot(8) in both. r249371: Remove kernel options from the SYNOPSIS. They are already documented in the geom(4) manual page SYNOPSIS. r247370: Fix typo in EFI GPT GUID. r245910: Expand description of how gptboot and gptzfsboot choose a partition for booting. Notes: svn path=/stable/9/; revision=253211
* MFC r253077: should_yield: protect from td_swvoltick being uninitializedAndriy Gapon2013-07-111-1/+1
| | | | | | | or too stale Notes: svn path=/stable/9/; revision=253203
* MFC r253091:Steven Hartland2013-07-112-0/+16
| | | | | | | Added 4K QUIRK for OCZ Vertex 4 SSDs Notes: svn path=/stable/9/; revision=253200
* MFC r245867:Pyun YongHyeon2013-07-111-1/+1
| | | | | | | For 57765 class controllers, set low watermark max receive frames to 1. Notes: svn path=/stable/9/; revision=253197
* MFC r245870:Pyun YongHyeon2013-07-111-2/+2
| | | | | | | | bge_attach() can fail before attaching mii(4). So make sure to check bge_miibus before detaching mii(4). Notes: svn path=/stable/9/; revision=253195
* MFC r253069, r253074:Alexander Motin2013-07-111-0/+2
| | | | | | | | Add one more ID of Marvell SATA controller. Add ID for Marvell 88SE9215 AHCI SATA controller. Notes: svn path=/stable/9/; revision=253194
* MFC r253036:Alexander Motin2013-07-112-0/+8
| | | | | | | Add quirk to configure headphones redirection on ASUS UX31A laptop. Notes: svn path=/stable/9/; revision=253193
* Fix for lost software interrupts/cam lockup.Alfred Perlstein2013-07-111-9/+11
| | | | | | | MFC: 252683 Notes: svn path=/stable/9/; revision=253184
* MFC r252714:Konstantin Belousov2013-07-111-1/+6
| | | | | | | | | | The tvp vnode on rename is usually unlinked. Drop the cached null vnode for tvp to allow the free of the lower vnode, if needed. PR: kern/180236 Notes: svn path=/stable/9/; revision=253183
* MFC: r252673Rick Macklem2013-07-111-2/+13
| | | | | | | | | | | | | | | | | | | | | | | A problem with the old NFS client where large writes to large files would sometimes result in a corrupted file was reported via email. This problem appears to have been caused by r251719 (reverting r251719 fixed the problem). Although I have not been able to reproduce this problem, I suspect it is caused by another thread increasing np->n_size after the mtx_unlock(&np->n_mtx) but before the vnode_pager_setsize() call. Since the np->n_mtx mutex serializes updates to np->n_size, doing the vnode_pager_setsize() with the mutex locked appears to avoid the problem. Unfortunately, vnode_pager_setsize() where the new size is smaller, cannot be called with a mutex held. This patch returns the semantics to be close to pre-r251719 such that the call to the vnode_pager_setsize() is only delayed until after the mutex is unlocked when np->n_size is shrinking. Since the file is growing when being written, I believe this will fix the corruption. Tested by: remy.nonnenmacher@activnetworks.com Notes: svn path=/stable/9/; revision=253177
* MFC r252956:Pedro F. Giffuni2013-07-101-0/+20
| | | | | | | Implement SEEK_HOLE/SEEK_DATA for ext2fs. Notes: svn path=/stable/9/; revision=253170
* Jump on the 9.2r MFC bonanza and update ciss(4)Sean Bruno2013-07-101-1/+18
| | | | | | | | | | | | r250031 - zero a data structure for notifications r250022 r249977 r249947 r249908 - handle cases of controllers advertising an sg_list of less than CISS_MAX_SG_ELEMENTS. Fixes ciss(4) ZMR cases. Notes: svn path=/stable/9/; revision=253160
* MFC VirtIO r252702,r252703,r252704,r252706,r252707,r252708,r252709Bryan Venteicher2013-07-1014-560/+595
| | | | | | | | | | | | | | | | This brings in several bug fixes and better conformance with various aspects of the spec that have changed. r252702: Convert VirtIO to use ithreads instead of taskqueues r252703: Block driver bug fixes and spec changes r252704: Balloon driver improvements r252706: Minor network driver improvements r252707: Minor misc VirtIO changes r252708: PCI driver bug fixes and cleanup r252709: Fix SCSI driver lock not owned panic Notes: svn path=/stable/9/; revision=253132
* MFC r252404:Pyun YongHyeon2013-07-102-1/+30
| | | | | | | | Fix triggering false watchdog timeout as done in bce(4) when controller is in PAUSE state. Notes: svn path=/stable/9/; revision=253130
* MFC r252402:Pyun YongHyeon2013-07-102-3/+31
| | | | | | | | | Fix triggering false watchdog timeout when controller is in PAUSE state. Previously it used to check if controller has sent a PAUSE frame to the remote peer. Notes: svn path=/stable/9/; revision=253128
* MFC r252227:Pyun YongHyeon2013-07-101-1/+1
| | | | | | | | Don't blidly clear GPIOs configuration. Just use firmware configured one. This change also fixes non-working traffic LED on BCM57780. Notes: svn path=/stable/9/; revision=253126
* MFC: r252528Rick Macklem2013-07-101-2/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | A problem with the old NFS client where large writes to large files would sometimes result in a corrupted file was reported via email. This problem appears to have been caused by r251719 (reverting r251719 fixed the problem). Although I have not been able to reproduce this problem, I suspect it is caused by another thread increasing np->n_size after the mtx_unlock(&np->n_mtx) but before the vnode_pager_setsize() call. Since the np->n_mtx mutex serializes updates to np->n_size, doing the vnode_pager_setsize() with the mutex locked appears to avoid the problem. Unfortunately, vnode_pager_setsize() where the new size is smaller, cannot be called with a mutex held. This patch returns the semantics to be close to pre-r251719 (actually pre-r248567, r248581, r248567 for the new client) such that the call to vnode_pager_setsize() is only delayed until after the mutex is unlocked when np->n_size is shrinking. Since the file is growing when being written, I believe this will fix the corruption. A better solution might be to replace the mutex with a sleep lock, but that is a non-trivial conversion, so this fix is hoped to be sufficient in the meantime. Tested by: remy.nonnenmacher@activnetworks.com Notes: svn path=/stable/9/; revision=253124
* MFC r252501:Hiroki Sato2013-07-092-0/+2
| | | | | | | | | Add Planex MZK-UE150N. Submitted by: Yusuke Tanaka Notes: svn path=/stable/9/; revision=253059
* MFC r252203:Alexander Motin2013-07-081-5/+30
| | | | | | | | | | | | | Add test for SATA registers writability and skip using them if it failed. There are some systems reported, where PCI BAR(5), used for SATA registers access, is present, but not functional. Attempt to use it brakes devices detection logic. Try to detect those cases on attach by setting and testing some bits in SControl register. If bits are unsettable, fallback to legacy ATA without hot-plug detection, speed control/reporting, etc. Notes: svn path=/stable/9/; revision=253041
* MFC r252204, r252250:Alexander Motin2013-07-081-0/+186
| | | | | | | Add bunch of names for Seagate and HGST vennor-specififc ASC/ASCQ codes. Notes: svn path=/stable/9/; revision=253039