summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* MFC 285730gnn2016-03-031-1/+1
| | | | | | | | Only report the lack of ALTQ support if pfctl is using verbose (-v) mode. PR: 194935 Submitted by: Jim Thompson Approved by: re (gjb)
* MFC: r296025:kp2016-03-031-2/+3
| | | | | | | | | | | | | | | | | | | pf: Fix possible out-of-bounds write In the DIOCRSETADDRS ioctl() handler we allocate a table for struct pfr_addrs, which is processed in pfr_set_addrs(). At the users request we also provide feedback on the deleted addresses, by storing them after the new list ('bcopy(&ad, addr + size + i, sizeof(ad));' in pfr_set_addrs()). This means we write outside the bounds of the buffer we've just allocated. We need to look at pfrio_size2 instead (i.e. the size the user reserved for our feedback). That'd allow a malicious user to specify a smaller pfrio_size2 than pfrio_size though, in which case we'd still read outside of the allocated buffer. Instead we allocate the largest of the two values. Reported By: Paul J Murphy <paul@inetstat.net> PR: 207463 Approved by: re (marius)
* Merge OpenSSL 1.0.1s. This is a security update.delphij2016-03-02389-1121/+2322
| | | | | Relnotes: yes Approved by: re (so@ implicit)
* MFC r295969:ae2016-03-022-2/+2
| | | | | | | | Fix bug in filling and handling ipfw's O_DSCP opcode. Due to integer overflow CS4 token was handled as BE. PR: 207459 Approved by: re (gjb)
* MFC r295995:bdrewery2016-03-021-11/+1
| | | | | | | BDECFLAGS has not been available since r82604 removed /etc/defaults/make.conf. Approved by: re (gjb)
* MFC [Hyper-V]: r296028sephe2016-03-013-6/+9
| | | | | | | | | | | | hyperv: Wait 5 seconds for hyperv result, instead of 500ms This addresses various devices (network, stoarge) attach failure. Approved by: re (gjb) Reported by: Hongxiong Xian <v-hoxian microsoft com> Tested by: Hongxiong Xian <v-hoxian microsoft com> Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5435
* MFC r295944:jimharris2016-02-291-1/+1
| | | | | | | | | | | nvme: fix intx handler to not dereference ioq during initialization This was a regression from r293328, which deferred allocation of the controller's ioq array until after interrupts are enabled during boot. Approved by: re (gjb) Sponsored by: Intel
* Update stable/10 to BETA3 in preparation for 10.3-BETA3 builds.marius2016-02-261-1/+1
| | | | Approved by: re (implicit)
* MFC: r295906marius2016-02-265-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix and clean up usage of DMA and TSO segments: - At Intel it is believed that most of their products support "only" 40 DMA segments so lower {EM,IGB}_MAX_SCATTER accordingly. Actually, 40 is more than plenty to handle full size TSO packets so it doesn't make sense to further distinguish between MAC variants that really can do 64 DMA segments. Moreover, capping at 40 DMA segments limits the stack usage of {em,igb}_xmit() that - given the rare use of more than these - previously hardly was justifiable, while still being sufficient to avoid the problems seen with em(4) and EM_MAX_SCATTER set to 32. - In igb(4), pass the actually supported TSO parameters up the stack. Previously, the defaults set in if_attach_internal() were applied, i. e. a maximum of 35 TSO segments, which made supporting more than these in the driver pointless. However, this might explain why no problems were seen with IGB_MAX_SCATTER at 64. - In em(4), take the 5 m_pullup(9) invocations performed by em_xmit() in the TSO case into account when reporting TSO parameters upwards. In the worst case, each of these calls will add another mbuf and, thus, the requirement for an additional DMA segment. So for best performance, it doesn't make sense to advertize a maximum of TSO segments that typically will require defragmentation in em_xmit(). Again, this leaves enough room to handle full size TSO packets. - Drop TSO macros from if_lem.h given that corresponding MACS don't support TSO in the first place. Reviewed by: erj, sbruno, jeffrey.e.pieper_intel.com Approved by: re (gjb)
* MFC r295830davidcs2016-02-254-1064/+110
| | | | | | Remove dead code. Code Cleanup. Improve clarity in debug messages Approved by:re (marius)
* MFC r295823davidcs2016-02-252-42/+56
| | | | | | | | | | Modified the use of bxe_grc_dump() function so that it can be invoked directly at any potential error path, where a fwdump is needed. The fwdump (a.k.a grcdump) is stored in a driver buffer. The sysctl grcdump_done indicates if a fwdump was taken and waiting to be retrieved. The sysctl trigger_grcdump can be used to manually trigger a fwdump. Approved by:re (marius)
* MFC r294854davidcs2016-02-252-147795/+147789
| | | | | | | Upgrade FW to 5.4.56 Update driver version to 3.10.26 Approved by:re (marius)
* MFC r295273:tuexen2016-02-251-7/+11
| | | | | | | | | | In FreeBSD 10 and higher the driver announces SCTP checksum offloading support also for 82598, which doesn't support it. The legacy code has a check for it, which was missed when the code for dealing with CSUM_IP6_* was added. Add the same check for FreeBSD 10 and higher. Approved by: re (marius) Differential Revision: D5192
* MFC r295323:erj2016-02-2524-333/+1457
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update em(4) to 7.6.1; update igb(4) to 2.5.3. Major changes: - Add i219/i219(2) hardware support. (Found on Skylake generation and newer chipsets.) - Further to the last Skylake support diff, this one also includes support for the Lewisburg chipset (i219(3)). - Add a workaround to an igb hardware errata. All 1G server products need to have IPv6 extension header parsing turned off. This should be listed in the specification updates for current 1G server products, e.g. for i350 it's errata #37 in this document: http://www.intel.com/content/dam/www/public/us/en/documents/specification-updates/ethernet-controller-i350-spec-update.pdf - Avoton (i354) PHY errata workaround added And a bunch of minor fixes, as well as #defines for things that the current em(4)/igb(4) drivers don't implement. MFC r287465: igb(4): Update and fix HW errata - HW errata workaround for IPv6 offload w/ extension headers - Edited start of if_igb.c (Device IDs / #includes) to match ixgbe/ixl Approved by: re (gjb) Sponsored by: Intel Corporation
* MFC r295549:tuexen2016-02-2511-106/+161
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Loopback addresses are 127.0.0.0/8, not 127.0.0.1/32. MFC r295668: Improve the teardown of the SCTP stack. MFC r295670: Whitespace changes. MFC r295708: Address a warning reported by D5245 / PVS. MFC r295709: Code cleanup which will silence a warning in PVS / D5245. MFC r295710: Add protection code for issues reported by PVS / D5245. MFC r295771: Fix reporting of mapped addressed in getpeername() and getsockname() for IPv6 SCTP sockets. This bugs were found because of an issue reported by PVS / D5245. MFC r295772: Add some protection code. MFC r295773: Add protection code. MFC r295805: Use the SCTP level pointer, not the interface level. MFC r295929: Don't leak an address in an error path. Approved by: re (marius)
* MFH 295796 (based on)araujo2016-02-251-2/+3
| | | | | | | | | | | Fix regression introduced on 272446r. lagg(4) supports the protocol none, where it disables any traffic without disabling the lagg(4) interface itself. PR: 206478 Submitted by: Erin Clark <erin.clark.ix@gmail.com> Reviewed by: rpokala, bapt Approved by: re (glebius) Differential Revision: https://reviews.freebsd.org/D5188
* MFC r294933,r294949,r294952,r294953,r294957,r294965,r294967,r294968,r295017,bdrewery2016-02-244-144/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r295026,r295027,r295029,r295030,r295649: r294933: Drop any previous fd when setting a new one. r294949: filemon_ioctl: Handle error from devfs_get_cdevpriv(9). r294952: filemon_ioctl: Lock the associated filemon handle before writing to it. r294953: filemon_comment has nothing to do with wrappers so move it out of filemon_wrapper.c. r294957: filemon_dtr: Lock the associated filemon handle before writing to it. r294965: filemon: Use process_exit EVENTHANDLER to capture process exit. r294967: filemon: Trace fork via process_fork event. r294968: Follow-up r294967: Mark flags unused. r295017: filemon: Use process_exec EVENTHANDLER to capture sys_execve. r295026: filemon_open: Don't record a process to trace here. r295027: filemon: Track the process pointer rather than a pid. r295029: Document the purpose and non-purpose of filemon(4). r295030: Note the double fork behavior with filemon. r295649: filemon: Fix panic when fork1() is called from kproc_create(). Approved by: re (marius)
* MFC 295636,295637:jhb2016-02-242-1/+3
| | | | | | | | | | | | | | | | Fix issues with tracing Linux/i386 binaries. 295636: Sign extend the error value for failing Linux/i386 system calls. This restores the mapping of Linux errors to native FreeBSD errno values after the refactoring in r288424. 295637: Correct the ABI name for Linux/i386 binaries under FreeBSD/i386. This allows truss to work for these binaries again after r288424. Approved by: re (marius)
* MFC r295717:kib2016-02-241-0/+9
| | | | | | | | After nullfs rmdir operation, reclaim the directory vnode which was unlinked. Otherwise the vnode stays cached, causing leak. This is similar to r292961 for regular files. Approved by: re (marius)
* MFC r295914: MFV r295913:delphij2016-02-241-2/+5
| | | | | | | | | | | | Partially apply upstream changeset 6e06b1c8 (kientzle). Limit filter recursion level to 25 (instead of infinite). This fixes a potential crash issue discovered by Alexander Cherepanov. PR: 207362 Reported by: Robert Clausecker Obtained from: libarchive github project Approved by: re (marius)
* MFH: 285685araujo2016-02-245-4/+40
| | | | | | | | | | | Add support to the jail framework to be able to mount linsysfs(5) and linprocfs(5). PR: 207179 Requested by: thomas@gibfest.dk Reviewed by: jamie, bapt Approved by: re (gjb) Sponsored by: gandi.net Differential Revision: https://reviews.freebsd.org/D5390
* MFC [Hyper-V]: r294553, r294700sephe2016-02-249-188/+593
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r294553 hyperv/vmbus: Lookup channel through id table Vmbus event handler will need to find the channel by its relative id, when software interrupt for event happens. The original lookup searches the channel list, which is not very efficient. We now create a table indexed by the channel relative id to speed up the channel lookup. Submitted by: Hongjiang Zhang <honzhan microsoft com> Reviewed by: delphij, adrain, sephe, Dexuan Cui <decui microsoft com> Approved by: adrian (mentor) Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D4802 ------------- r294700 hyperv/hn: Partly rework transmission path - Avoid unnecessary malloc/free on transmission path. - busdma(9)-fy transmission path. - Properly handle IFF_DRV_OACTIVE. This should fix the network stalls reported by many. - Properly setup TSO parameters. - Properly handle bpf(4) tapping. This 5 times the performance during TCP sending test, when there is one bpf(4) attached. - Allow size of chimney sending be tuned on a running system. Default value still needs more test to determine. Reviewed by: adrian, delphij Approved by: adrian (mentor) Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D4972 Approved by: re (marius) Sponsored by: Microsoft OSTC
* In preparation for 10.3-RELEASE, temporarily revert the MFC of r291244marius2016-02-231-242/+80
| | | | | | | | | | | done as part of r292895 on stable/10 as that change causes hangs with ZFS and the cause on at least amd64 so far not understood. Discussed with: kib For further information see: https://lists.freebsd.org/pipermail/freebsd-stable/2016-February/084045.html PR: 207281 Approved by: re (gjb)
* MFC r295665:bdrewery2016-02-231-8/+0
| | | | | | Remove temporary hack from r294370 for SSH upgrades. Approved by: re (marius)
* MFC r295737:markj2016-02-221-2/+3
| | | | | | | Use the _SAFE loop variant. PR: 207146 Approved by: re (gjb, glebius)
* MFC r295574:markj2016-02-221-1/+4
| | | | | | Clear the cookie pointer on error in tmpfs_readdir(). Approved by: re (glebius)
* Revert 295285 which was an MFC of the tryforward work (r290383,295282,295283)gnn2016-02-2210-20/+151
| | | | | | | In the IPFW+NAT+divergent MTU case there is a bug in sening ICMP MTU updates. Approved by: re (marius, gjb) Sponsored by: Rubicon Communications (Netgate)
* MFC r286641 (from oshogbo):garga2016-02-221-2/+2
| | | | | | | | | | | | Use correct src/dst ports when removing states. Submitted by: Milosz Kaniewski <m.kaniewski@wheelsystems.com>, UMEZAWA Takeshi <umezawa@iij.ad.jp> (orginal) Reviewed by: glebius Approved by: re (marius) Obtained from: OpenBSD Sponsored by: Rubicon Communications (Netgate) Differential revision: https://reviews.freebsd.org/D5392
* MFC: r287299 [1]marius2016-02-223-23/+1227
| | | | | | | | | | | | | | | | | | | Add a gop command to help diagnose VT efifb problems. The gop command has the following sub-commands: list - list all possible modes (paged) get - return the current mode set <mode> - set the current mode to <mode> MFC: r287317, r287422, r287475, r287489, r287538 [2] Add support for the UGA draw protocol. This includes adding a command called 'uga' to show whether UGA is implemented by the firmware and what the settings are. It also includes filling the efi_fb structure from the UGA information when GOP isn't implemented by the firmware. PR: 207313 [1], 202730 [2] Approved by: re (gjb)
* MFC: r264565marius2016-02-211-1/+76
| | | | | | | | | | | | | | | | | | | Do not set M_BESTFIT if a strategy has already been provided. This fixes problems when using M_FIRSTFIT. MFC: r280805 Add four new DDB commands to display vmem(9) statistics. In particular, such DDB commands were added: show vmem <addr> show all vmem show vmemdump <addr> show all vmemdump As possible usage, that allows to see KVA usage and fragmentation. Approved by: re (gjb)
* MFH (r294326): fall back to standard / configured CA storedes2016-02-201-3/+10
| | | | | PR: 193871 Approved by: re (gjb)
* MFC r272785:smh2016-02-201-3/+5
| | | | | | | | Null terminate boot config buffer PR: 207070 Approved by: re (gjb) Sponsored by: Multiplay
* MFC, r295417:ken2016-02-191-1/+1
| | | | | | | | | | | | | | r295417 | ken | 2016-02-08 15:13:08 -0700 (Mon, 08 Feb 2016) | 9 lines Fix the SCSI Extended INQUIRY probe case when an error is returned and a retry is scheduled. Instead of leaving the device queue frozen, unfreeze the device queue so that the retry can happen. Sponsored by: Spectra Logic Approved by: re (gjb)
* MFC [Hyper-V]: r293719-r293722, r293869-r293871, r293873-r293875, r293877sephe2016-02-1916-189/+603
| | | | | | | | | | | | | | | | | r293719 hyperv/hn: Implement LRO r293720 hyperv/hn: Implement SIOC[SG]IFMEDIA support r293721 hyperv/hn: Avoid mbuf cluster allocation, if the packet is small. r293722 hyperv/hn: Removed unused netvsc_init() r293869 hyperv/hn: Unbreak LINT-NOIP r293870 hyperv: use x86 generic code to do the hypervisor detection r293871 hyperv: remove unused vmbus definitions r293873 hyperv: implement an event timer r293874 hyperv: add interrupt counters r293875 hyperv: set receive buffer size according to NVSP protocol version r293877 Unbreak `make depend` with sys/modules/hyperv/vmbus after r293870 Approved by: re (glebius), adrian (mentor) Sponsored by: Microsoft OSTC
* MFC r295616:pfg2016-02-171-5/+8
| | | | | | | | | | | | ext2fs: Remove panics for rename() race conditions. Sync with r84642 from UFS: The panics are inappropriate because the IN_RENAME flag only fixes a few of the huge number of race conditions that can result in the source path becoming invalid even prior to the VOP_RENAME() call. Approved by: re (glebius)
* MFC r295022:jimharris2016-02-172-3/+28
| | | | | | | | | | | | | | | | | nvd: add hw.nvd.delete_max tunable The NVMe specification does not define a maximum or optimal delete size, so technically max delete size is min(full size of namespace, 2^32 - 1 LBAs). A single delete operation for a multi-TB NVMe namespace though may take much longer to complete than the nvme(4) I/O timeout period. So choose a sensible default here that is still suitably large to minimize the number of overall delete operations. This also fixes possible uint32_t overflow on initial TRIM operation for zpool create operations for NVMe namespaces with >4G LBAs. Approved by: re (glebius) Sponsored by: Intel
* MFC r295532:jimharris2016-02-171-8/+10
| | | | | | | | | | | | | | | | | | | nvme: avoid duplicate SET_NUM_QUEUES commands nvme(4) issues a SET_NUM_QUEUES command during device initialization to ensure enough I/O queues exists for each of the MSI-X vectors we have allocated. The SET_NUM_QUEUES command is then issued again during nvme_ctrlr_start(), to ensure that is properly set after any controller reset. At least one NVMe drive exists which fails this second SET_NUM_QUEUES command during device initialization. So change nvme_ctrlr_start() to only issue its SET_NUM_QUEUES command when it is coming out of a reset - avoiding the duplicate SET_NUM_QUEUES during device initialization. Approved by: re (glebius) Sponsored by: Intel
* MFH (r295536): fix double-free error when SSL connection failsdes2016-02-171-1/+0
| | | | | | PR: 206774 Submitted by: Christian Heckendorf <heckendorfc@gmail.com> Approved by: re (glebius)
* MFH (r295535): use insecure-lan-zones option instead of hardcoded listdes2016-02-1715-139/+269
| | | | | Approved by: re (glebius) Relnotes: yes
* MFH (r295533): remove broken unbound-control-setup scriptdes2016-02-173-2/+2
| | | | | Approved by: re (glebius) Relnotes: yes
* MFC r295455bapt2016-02-161-1/+2
| | | | | | | Fix make universe when running with non POSIX/C locales using a locale sensitive pattern Approved by: re@ (gjb, marius)
* MFC 295418,295419:jhb2016-02-162-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix hangs or panics when misbehaved kernel threads return from their main function. 295418: Mark proc0 as a kernel process via the P_KTHREAD flag. All other kernel processes have this flag set and all threads in proc0 (including thread0) have the similar TDP_KTHREAD flag set. 295419: Call kthread_exit() rather than kproc_exit() for a premature kthread exit. Kernel threads (and processes) are supposed to call kthread_exit() (or kproc_exit()) to terminate. However, the kernel includes a fallback in fork_exit() to force a kthread exit if a kernel thread's "main" routine returns. This fallback was added back when the kernel only had processes and was not updated to call kthread_exit() instead of kproc_exit() when threads were added to the kernel. This mistake was particularly exciting when the errant thread belonged to proc0. Due to the missing P_KTHREAD flag the fallback did not kick in and instead tried to return to userland via whatever garbage was in the trapframe. With P_KTHREAD set it tried to terminate proc0 resulting in other amusements. PR: 204999 Approved by: re (glebius)
* MFC r295497: Update uefi.8 for ZFS and multi device boot supportemaste2016-02-161-20/+12
| | | | Approved by: re (gjb)
* drm/i915: Restore pci_enable_busmaster() call in the init pathdumbbell2016-02-155-13/+7
| | | | | | | | | | | | | | This fixes a GPU hang on i945GM. While here, merge some minor fixes to DRM core and i915: * Remove obsolete drm_agp_*_memory() prototypes * Fix comment in drm_fops.c (outisde -> outside) * Fix some formatting issues in drm_stub.c (spaces -> tabs) Approved by: re (marius) MFC of: r288653, r288952, r293851 Submitted by: <s3erios@gmail.com> Differential Revision: https://reviews.freebsd.org/D3413
* MFC r295495 - Update leapsecond file in non-chroot environments.cy2016-02-141-4/+4
| | | | | | PR: 207095 Submitted by: madpilot Approved by: re (marius)
* MFC r295496: Document boot1.efi's handling of /boot.configemaste2016-02-141-1/+12
| | | | Approved by: re (marius)
* MFC r294598:kib2016-02-141-5/+10
| | | | | | In tty_dealloc(), clear the queues. Approved by: re (marius)
* MFC r294596:kib2016-02-141-2/+3
| | | | | | | Limit the accesses to file' f_advice member to VREG vnodes only. Recheck that f_advice is not NULL after lock is taken. Approved by: re (marius)
* MFC r294595:kib2016-02-141-0/+7
| | | | | | | | When devfs dirent is freed, a vnode might still keep a pointer to it, apparently. Interlock and clear the pointer to avoid free memory dereference. Approved by: re (marius)
* Update stable/10 to BETA2 in preparation for 10.3-BETA2 builds.marius2016-02-121-1/+1
| | | | Approved by: re (implicit)
OpenPOWER on IntegriCloud