aboutsummaryrefslogtreecommitdiff
path: root/sys
Commit message (Collapse)AuthorAgeFilesLines
...
* ufs: replace 0 with NULL for pointers.Pedro F. Giffuni2016-04-104-22/+29
| | | | | | | | | | | | | While here also do late initialization of the variables we are changing. Found with devel/coccinelle. Reviewed by: mckusick MFC after: 2 weeks Notes: svn path=/head/; revision=297791
* VM_MAXUSER_ADDRESS is highest page start, not highest address.Justin Hibbits2016-04-101-1/+1
| | | | | | | | In case a single page mapping is requested first, which might overlap the user address space, fix the device map block to the next page. Notes: svn path=/head/; revision=297785
* Restructure device mappings for Book-E.Justin Hibbits2016-04-102-18/+19
| | | | | | | | | | | | | | | | | | | | | Summary: There is currently a 1GB hole between user and kernel address spaces into which direct (1:1 PA:VA) device mappings go. This appears to go largely unused, leaving all devices to contend with the 128MB block at the end of the 32-bit space (0xf8000000-0xffffffff). This easily fills up, and needs to be densely packed. However, dense packing wastes precious TLB1 space, of which there are only 16 (e500v2) or 64(e5500) entries available. Change this by using the 1GB space for all device mappings, and allow the kernel to use the entire upper 1GB for KVA. This also allows us to use sparse device mappings, freeing up TLB entries. Test Plan: Boot tested on p5020. Differential Revision: https://reviews.freebsd.org/D5832 Notes: svn path=/head/; revision=297784
* More complete implementation of /proc/self/limits.Dmitry Chagin2016-04-102-42/+76
| | | | | | | | | | | Fix the way the code accesses process limits struct - pointed out by mjg@. PR: 207386 Reviewed by: no objection form des@ MFC after: 3 weeks Notes: svn path=/head/; revision=297781
* Add a 'show t4 devlog <nexus>' DDB command.John Baldwin2016-04-101-0/+93
| | | | | | | | | | This command displays the adapter's firmware device log similar to the dev.<nexus>.misc.devlog sysctl. Sponsored by: Chelsio Communications Notes: svn path=/head/; revision=297779
* Add a 'show t4 tcb <nexus> <tid>' command to dump a TCB from DDB.John Baldwin2016-04-103-25/+86
| | | | | | | | This allows the contents of a TCB to be extracted from a T4/T5 card in DDB after a panic. Notes: svn path=/head/; revision=297777
* Add a function to lookup a device_t object by name.John Baldwin2016-04-102-6/+17
| | | | | | | | | This just walks the global list of devices looking for one with the requested name. The one use case outside of devctl2's implementation is for DDB commands that wish to lookup devices by name. Notes: svn path=/head/; revision=297776
* [net80211] correctly (i hope, wow) do a ticks comparison to limit A-MPDU ↵Adrian Chadd2016-04-101-1/+1
| | | | | | | | | | | | | | | attempts I was seeing the stack constantly attempt to renegotiate A-MPDU TX even after 3 failures. My hunch is that the direct ticks comparison is failing around the ticks wrap-around point. This failure shouldn't /really/ happen normally, but it turns out being the IBSS master node on FreeBSD doesn't quite setup 11n right, so negotiating A-MPDU TX fails. Notes: svn path=/head/; revision=297775
* [net80211] unconditionally do A-MPDU RX aging.Adrian Chadd2016-04-101-12/+2
| | | | | | | | | | | | | | | | It's 2016 and vendors (including us!) still have 802.11n TX/RX sequence handling bugs. It's suboptimal, but I'd rather see us default to handling things in a sensible way. So, just delete the #ifdef'ed code for now. I'll leave the option in so it doesn't break existing configurations. This all started because I've started getting reports about urtwn not working after I enabled 802.11n support, and it's because the ARM kernel configs don't include A-MPDU RX aging. Notes: svn path=/head/; revision=297774
* Implement support for boot-time DTrace.Mark Johnston2016-04-101-49/+112
| | | | | | | | | | | | | | | | | | | | | | This allows one to enable DTrace probes relatively early during boot, during SI_SUB_DTRACE_ANON, before dtrace(1) can invoked. The desired enabling is created using dtrace -A, which writes a /boot/dtrace.dof file and uses nextboot(8) to ensure that DTrace kernel modules are loaded and that the DOF file describing the enabling is loaded by loader(8) during the subsequent boot. The trace output can then be fetched with dtrace -a. With this commit, boot-time DTrace is only functional on i386 and amd64: on other architectures, the high-resolution timer frequency is initialized during SI_SUB_CLOCKS and is thus not available when the anonymous tracing state is initialized. On x86, the TSC is used and is thus available earlier. MFC after: 1 month Relnotes: yes Notes: svn path=/head/; revision=297773
* Initialize SDT probes during SI_SUB_DTRACE_PROVIDER.Mark Johnston2016-04-101-13/+5
| | | | | | | | | | This is consistent with all other DTrace providers and ensures that SDT probes are available for boot-time tracing. MFC after: 2 weeks Notes: svn path=/head/; revision=297771
* Initialize DTrace hrtimer frequency during SI_SUB_CPU on i386 and amd64.Mark Johnston2016-04-102-36/+60
| | | | | | | | | | | | This allows the hrtimer to be used earlier during boot. This is required for boot-time DTrace: anonymous enablings are created during SI_SUB_DTRACE_ANON, which runs before APs are started. In particular, the DTrace deadman timer requires that the hrtimer be functional. MFC after: 2 weeks Notes: svn path=/head/; revision=297770
* [net80211] log the node pointer when calling ht node init/cleanupAdrian Chadd2016-04-091-6/+7
| | | | | | | | | | | This makes it easier to track which node is having what done do it during normal use. This is likely the eighth time I've done this since I started doing net80211 development, so I think it's about time I just committed it. Notes: svn path=/head/; revision=297769
* [net80211] add back in the ff/superg node init call that I accidentallyAdrian Chadd2016-04-091-0/+8
| | | | | | | | | deleted. It's mostly a no-op right now, so it shouldn't have changed behaviour. Notes: svn path=/head/; revision=297768
* USB: replace 0 with NULL for pointers.Pedro F. Giffuni2016-04-092-2/+2
| | | | | | | | | Found with devel/coccinelle. Reviewed by: hselasky Notes: svn path=/head/; revision=297764
* MFV r297760: 6418 zpool should have a label clearing commandAlexander Motin2016-04-091-0/+4
| | | | | | | | | | | | | | | | | | | | Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com> Reviewed by: Matthew Ahrens <mahrens@delphix.com> Reviewed by: George Wilson <george.wilson@delphix.com> Author: Will Andrews <will@firepipe.net> Closes #83 Closes #32 openzfs/openzfs@9663688425131744221ea99f9e66b9ed964492ae FreeBSD already had `zpool labelclear` functionality, so this is mostly just a diff reduction. MFC after: 1 month Notes: svn path=/head/; revision=297763
* Use DELAY() instead of sleeping during boot-time attach.John Baldwin2016-04-091-1/+4
| | | | | | | Tested by: Wolfgang Zenker <wolfgang@lyxys.ka.sub.org> Notes: svn path=/head/; revision=297762
* Align the start of the text segment to an 8-byte boundary. This fixesIan Lepore2016-04-091-2/+3
| | | | | | | | | | | | | | | alignment aborts in ubldr.bin for RPi that started happening with clang 3.8 (earlier clang apparently didn't generate strd instructions that trigger the alignment fault). The abort happened in ubldr.bin and not ubldr (elf version) because the elf headers are 0xf4 bytes long, and stripping them off left everything 4-byte aligned. While here, also stop aligning the data segment to a page boundary, align it to 8 bytes instead (aligning to a page just needlessly makes the file bigger); pointed out by andrew@. Notes: svn path=/head/; revision=297758
* Add couple new constants from SPC5r08.Alexander Motin2016-04-091-0/+2
| | | | Notes: svn path=/head/; revision=297756
* ixl(4): replace 0 with NULL for pointers.Pedro F. Giffuni2016-04-092-3/+3
| | | | | | | | | | Found by devel/coccinelle. Differential Revision: https://reviews.freebsd.org/D5894 Reviewed by: erj Notes: svn path=/head/; revision=297753
* Register symbolic port/node names in FC name server.Alexander Motin2016-04-096-6/+181
| | | | | | | | | | | | This is cosmetics that simplifies identification of new ports on FC switch. It would be good to use target name from CTL here instead of hostname, but it is not passed here through CAM now. MFC after: 2 weeks Notes: svn path=/head/; revision=297751
* Add more fine-grained kernel options for NUMA support.John Baldwin2016-04-0910-43/+99
| | | | | | | | | | | | | | | | VM_NUMA_ALLOC is used to enable use of domain-aware memory allocation in the virtual memory system. DEVICE_NUMA is used to enable affinity reporting for devices such as bus_get_domain(). MAXMEMDOM must still be set to a value greater than for any NUMA support to be effective. Note that 'cpuset -gd' always works if MAXMEMDOM is enabled and the system supports NUMA. Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D5782 Notes: svn path=/head/; revision=297748
* ioat(4): ioat_get_dmaengine(): Add M_WAITOK modeConrad Meyer2016-04-094-7/+36
| | | | | | | Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=297746
* Mfp: r296310,r296343Bjoern A. Zeeb2016-04-091-2/+13
| | | | | | | | | | | | | | | | | | It looks like as with the safety belt of DELAY() fastened (*) we can completely tear down and free all memory for TCP (after r281599). (*) in theory a few ticks should be good enough to make sure the timers are all really gone. Could we use a better matric here and check a tcbcb count as an optimization? PR: 164763 Reviewed by: gnn, emaste MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5734 Notes: svn path=/head/; revision=297742
* Reduce code duplication when executing Passthrough IOCB.Alexander Motin2016-04-091-187/+80
| | | | | | | MFC after: 2 weeks Notes: svn path=/head/; revision=297741
* Mfp: r296260Bjoern A. Zeeb2016-04-091-2/+1
| | | | | | | | | | | | | The tcp_inpcb (pcbinfo) zone should be safe to destroy. PR: 164763 Reviewed by: gnn MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5732 Notes: svn path=/head/; revision=297740
* Enable PHY regulator when the optional "phy-supply" property is present.Jared McNeill2016-04-091-0/+11
| | | | | | | Submitted by: Emmanuel Vadot <manu@bidouilliste.com> Notes: svn path=/head/; revision=297739
* Mfp: r296259Bjoern A. Zeeb2016-04-092-4/+9
| | | | | | | | | | | | | | | | | We attach the "counter" to the tcpcbs. Thus don't free the TCP Fastopen zone before the tcpcbs are gone, as otherwise the zone won't be empty. With that it should be safe to destroy the "tfo" zone without leaking the memory. PR: 164763 Reviewed by: gnn MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5731 Notes: svn path=/head/; revision=297738
* Mfp: r296309Bjoern A. Zeeb2016-04-091-2/+6
| | | | | | | | | | | | | | While there is no dependency interaction, stopping the timer before freeing the rest of the resources seems more natural and avoids it being scheduled an extra time when it is no longer needed. Reviewed by: gnn, emaste MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5733 Notes: svn path=/head/; revision=297736
* Mfp: r296345Bjoern A. Zeeb2016-04-091-2/+1
| | | | | | | | | | | | | | | No need to keep type stability on raw sockets zone. We've also been running with a KASSERT since r222488 to make sure the ipi_count is 0 on destroy. PR: 164763 Reviewed by: gnn MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5735 Notes: svn path=/head/; revision=297735
* Mfp: r296346Bjoern A. Zeeb2016-04-091-2/+1
| | | | | | | | | | | | No reason identified to keep UMA_ZONE_NOFREE here. Reviewed by: gnn MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5736 Notes: svn path=/head/; revision=297734
* Try to unbreak the build: the 'vap' variable is only used if ieee80211Bjoern A. Zeeb2016-04-091-1/+1
| | | | | | | debugging compile is on. Notes: svn path=/head/; revision=297733
* Make the KASSERT message in hash destroy more informative.Bjoern A. Zeeb2016-04-091-1/+2
| | | | | | | | | | | | | While the pointer might not be too helpful, the malloc type might at least give a good hint about which hashtbl we are talking. MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Reviewed by: gnn, emaste Differential Revision: https://reviews.freebsd.org/D5802 Notes: svn path=/head/; revision=297732
* [net80211] print out the channel type (eg a, b, g, n) when creatingAdrian Chadd2016-04-091-2/+3
| | | | | | | an IBSS network. Notes: svn path=/head/; revision=297731
* Fix a masking bug for e500 PMC.Justin Hibbits2016-04-091-3/+4
| | | | | | | | No idea how this slipped through my regression testing. pe_code is the event to count, pe_cpu is the CPU family mask. Notes: svn path=/head/; revision=297730
* [ath] Only process beacon frames for the IBSS/BSSID if appropriate.Adrian Chadd2016-04-091-64/+81
| | | | | | | | | | | | | | | | | | | | | * Don't use arbitrary frames for the average RX RSSI - only frames from the current BSSID * Don't log / do the syncbeacon logic for another BSSID and definitely don't do the syncbeacon call if we miss beacons outside of STA mode. * Don't do the IBSS merge bits if the current node plainly won't ever match our current BSS (ie, the IBSS doesn't have to match, but all the same bits that we check in ieee80211_ibss_merge() have to match.) Tested: * ath(4), AR9380, IBSS mode, surrounded by a lot of IBSS 11ac networks. Sponsored by: Eva Automation, Inc. Notes: svn path=/head/; revision=297729
* [net8021] Pull out the ibss check code into a public function.Adrian Chadd2016-04-092-15/+30
| | | | | | | | | | | | | | | The ath(4) driver now sees beacons and management frames for different BSSIDs in IBSS mode, which is a problem when you're in a very busy IBSS environment. So, expose this function so drivers can use it to check if the current RX node is actually for a BSS we need to pay attention to or not. PR: kern/208644 Sponsored by: Eva Automation. Inc. Notes: svn path=/head/; revision=297728
* [net80211] revert part of r282405 in order to restore IBSS behaviour.Adrian Chadd2016-04-091-4/+1
| | | | | | | | | | | | | | | | | | | This prevents nodes being created for peers on BSSes that are not our own. (Ie, same channel, IBSS, but different BSS.) The "IBSS merge" thing was fixed by me enabling "see all beacons" in the ath(4) driver a few months ago. Trouble is, we now need the filtering again. Tested: * ath(4), IBSS, on a very busy IBSS channel with lots (> 15) IBSS networks. PR: kern/208643 Sponsored by: Eva Automation, Inc. Notes: svn path=/head/; revision=297727
* Fix incorrect pin definitions for Allwinner A31.Jared McNeill2016-04-081-20/+20
| | | | Notes: svn path=/head/; revision=297726
* Attach hwreset resources at the same time as clock resources.Jared McNeill2016-04-081-1/+2
| | | | Notes: svn path=/head/; revision=297725
* Make it possible to tweak RCTL throttling sysctls at runtime.Edward Tomasz Napierala2016-04-081-17/+110
| | | | | | | | MFC after: 1 month Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=297722
* Fix sending TSO packets larger than single DMA segment on VNICZbigniew Bodek2016-04-081-7/+1
| | | | | | | | | | | | Due to the bug in the number of 'GATHER' subdescriptors for TSO packets, VNIC was not able to transmit more than one DMA segment with TSO enabled. Obtained from: Semihalf Sponsored by: Cavium Notes: svn path=/head/; revision=297721
* Fix MIPS INTRNG omissions, add soft/hard interrupts with different namesStanislav Galabov2016-04-081-12/+12
| | | | | | | | | Reviewed by: kan Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D5888 Notes: svn path=/head/; revision=297720
* Introduce better locking for mtk_gpio_v[12] driversStanislav Galabov2016-04-082-21/+79
| | | | | | | | | Approved by: adrian (mentor) Sponsored by: Smartcom - Bulgaria AD Differential Revision: https://reviews.freebsd.org/D5887 Notes: svn path=/head/; revision=297718
* Introduce Mediatek/Ralink PCIe supportStanislav Galabov2016-04-082-0/+1653
| | | | | | | | | | | | | | This revision introduces PCIe support for the relevant Mediatek/Ralink SoCs. Currently the PCIe support is not converted to INTRNG, this may be a task for the future. Approved by: adrian (mentor) Sponsored by: Smartcom - Bulgaria AD Differential Revision: https://reviews.freebsd.org/D5886 Notes: svn path=/head/; revision=297717
* Introduce XHCI support for MT7621 SoCStanislav Galabov2016-04-081-0/+298
| | | | | | | | | | | | | Tested on a MT7621 board, similar to the WiTi board. More testing will be required to confirm everything is fine, but things look good so far. Approved by: adrian (mentor) Sponsored by: Smartcom - Bulgaria AD Differential Revision: https://reviews.freebsd.org/D5885 Notes: svn path=/head/; revision=297716
* Disable USB PHY slew rate calibration for Mediatek SoCs for nowStanislav Galabov2016-04-081-1/+11
| | | | | | | | | | | | | | | | | | USB on both MT7621 and MT7688 seems to work much better without doing slew rate calibration. These are the only two SoCs, apart from MT7628, which actually make use of the slew rate calibration routines implemented in the mtk_usb_phy driver. Since MT7628 is actually a superset of MT7688 things should be the same for it as well. We do not remove the code, we simply define it out. Approved by: adrian (mentor) Sponsored by: Smartcom - Bulgaria AD Differential Revision: https://reviews.freebsd.org/D5884 Notes: svn path=/head/; revision=297715
* Fix wrong memory mappingStanislav Galabov2016-04-081-1/+1
| | | | | | | | | | | | In mtk_soc.c memory is mapped incorrectly for MT7621. This revision fixes this. Approved by: adrian (mentor) Sponsored by: Smartcom - Bulgaria AD Differential Revision: https://reviews.freebsd.org/D5882 Notes: svn path=/head/; revision=297714
* topo_set_pu_id: turn a check into an assertionAndriy Gapon2016-04-081-2/+2
| | | | | | | | | The new id must not be present in any cpu set in any topology element. MFC after: 30 days Notes: svn path=/head/; revision=297710
* zio write issue threads should have lower (numerically greater) priorityAndriy Gapon2016-04-081-1/+1
| | | | | | | | | | | This is because they might do data compression which is quite CPU expensive. The original code is correct for illumos, because there a higher priority corresponds to a greater number. MFC after: 2 weeks Notes: svn path=/head/; revision=297709