aboutsummaryrefslogtreecommitdiff
path: root/sys
Commit message (Collapse)AuthorAgeFilesLines
* Add the AR9300 HAL into the kernel and module builds.Adrian Chadd2013-05-023-11/+60
| | | | | | | | | Tested: * make universe (honest!) Notes: svn path=/head/; revision=250173
* Fix this code to compile without warnings - AH_DEBUG was pulling inAdrian Chadd2013-05-021-2/+6
| | | | | | | | ichan, but OS_MARK was not using it. It only uses it when AH_DEBUG_ALQ is also defined. Notes: svn path=/head/; revision=250172
* Update Intel email address.Eitan Adler2013-05-022-2/+2
| | | | | | | | | PR: docs/175349 Submitted by: Lars Eggert <lars@netapp.com> Discussed with: jfv Notes: svn path=/head/; revision=250168
* Add device identification and probe/attach support for the QCA9565.Adrian Chadd2013-05-024-0/+7
| | | | | | | | | | | | | | | The QCA9565 is a 1x1 2.4GHz 11n chip with integrated on-chip bluetooth. The AR9300 HAL already has support for this chip; it just wasn't included in the probe/attach path. Tested: * This commit brought to you over a QCA9565 wifi connection from FreeBSD. * .. ie, basic STA, pings, no iperf or antenna diversity checking just yet. Notes: svn path=/head/; revision=250166
* Add the AR933x SoC GPIO pin count limitation.Adrian Chadd2013-05-021-0/+5
| | | | Notes: svn path=/head/; revision=250165
* Bump __FreeBSD_version for accept4() and pipe2().Jilles Tjoelker2013-05-011-1/+1
| | | | Notes: svn path=/head/; revision=250163
* Regenerate files for pipe2().Jilles Tjoelker2013-05-0111-12/+77
| | | | Notes: svn path=/head/; revision=250160
* Add pipe2() system call.Jilles Tjoelker2013-05-014-0/+21
| | | | | | | | | | | | | | | | The pipe2() function is similar to pipe() but allows setting FD_CLOEXEC and O_NONBLOCK (on both sides) as part of the function. If p points to two writable ints, pipe2(p, 0) is equivalent to pipe(p). If the pointer is not valid, behaviour differs: pipe2() writes into the array from the kernel like socketpair() does, while pipe() writes into the array from an architecture-specific assembler wrapper. Reviewed by: kan, kib Notes: svn path=/head/; revision=250159
* Isilon reported that sec=krb5p NFS mounts had a problem when m_len == 0Rick Macklem2013-05-011-3/+21
| | | | | | | | | | | | for the last mbuf of the list with an encrypted message. This patch replaces the KASSERT() with code that handles this case. Reported by: john.gemignani@isilon.com Reviewed by: jhb MFC after: 2 weeks Notes: svn path=/head/; revision=250157
* Regenerate files for accept4().Jilles Tjoelker2013-05-0111-12/+95
| | | | Notes: svn path=/head/; revision=250155
* Add accept4() system call.Jilles Tjoelker2013-05-016-25/+70
| | | | | | | | | | | | | | | | | | The accept4() function, compared to accept(), allows setting the new file descriptor atomically close-on-exec and explicitly controlling the non-blocking status on the new socket. (Note that the latter point means that accept() is not equivalent to any form of accept4().) The linuxulator's accept4 implementation leaves a race window where the new file descriptor is not close-on-exec because it calls sys_accept(). This implementation leaves no such race window (by using falloc() flags). The linuxulator could be fixed and simplified by using the new code. Like accept(), accept4() is async-signal-safe, a cancellation point and permitted in capability mode. Notes: svn path=/head/; revision=250154
* Partially saved extended state must be handled always, i.e. for bothKonstantin Belousov2013-05-011-26/+24
| | | | | | | | | | | | | | | fpu-owned context, and for pcb-saved one. More, the XSAVE could do partial save, same as XSAVEOPT, so qualifier for the handler should be use_xsave and not use_xsaveopt. Since xsave_area_desc is now needed regardless of the XSAVEOPT use, remove the write-only use_xsaveopt variable. In collaboration with: jhb MFC after: 1 week Notes: svn path=/head/; revision=250153
* The check to ensure that xstate_bv always has XFEATURE_ENABLED_X87 andKonstantin Belousov2013-05-011-3/+0
| | | | | | | | | | | | | | | XFEATURE_ENABLED_SSE bits set is not needed. CPU correctly handles any bitmask which is subset of the enabled bits in %XCR0. More, CPU instructions XSAVE and XSAVEOPT could write the mask without e.g. XFEATURE_ENABLED_SSE, after the VZEROALL. The check prevents the restoration of the otherwise valid FPU save area. In collaboration with: jhb MFC after: 1 week Notes: svn path=/head/; revision=250152
* In case ZFS doesn't use UMA for buffers there's no need to waste memoryDavide Italiano2013-05-011-0/+3
| | | | | | | | | creating zones that will remain empty. Reviewed by: pjd Notes: svn path=/head/; revision=250149
* Introduce a constant, ELF_NOTE_ROUNDSIZE, which evidently declare ourMikolaj Golub2013-05-011-9/+10
| | | | | | | | | intention to use 4-byte padding for elf notes. MFC after: 3 weeks Notes: svn path=/head/; revision=250145
* Don't include asm.h in non-asm files.Warner Losh2013-05-014-119/+55
| | | | | | | | | Remove #define to get kludges that asm.h used to define Move clever macros to access assembler instructions to trap.c Remove __ASSEMBLER__ ifdefs in regdef.h: they aren't needed anymore. Notes: svn path=/head/; revision=250138
* Remove asm.h dependency in a hackish way.Warner Losh2013-05-011-5/+17
| | | | | | | Fixed comment. Notes: svn path=/head/; revision=250137
* Import NetBSD's version, which is perfectly fine.Warner Losh2013-05-011-38/+76
| | | | | | | Submitted by: jmallet@ Notes: svn path=/head/; revision=250136
* Add the standard #ifdef header protection.Warner Losh2013-05-011-0/+5
| | | | Notes: svn path=/head/; revision=250135
* Import virgin regdef.h from 4.4 Lite 2's sys/pmax/include/regdef.h,Warner Losh2013-05-011-81/+62
| | | | | | | | | | expand the %sccs.include.redist.c% directive with the standard 3-clause license, and add $FreeBSD$ to keep the commit script happy. # This may break some mips stuff, which will be fixed in the next commit. Notes: svn path=/head/; revision=250134
* Fix incorrect sizeof() in bzero()Eitan Adler2013-05-011-1/+1
| | | | | | | | Submitted by: swildner@DragonFlyBSD.org Reviewed by: alfred, jmallett Notes: svn path=/head/; revision=250132
* Correct a few sizeof()sEitan Adler2013-05-014-4/+4
| | | | | | | | Submitted by: swildner@DragonFlyBSD.org Reviewed by: alfred Notes: svn path=/head/; revision=250131
* Disable TXCONT, it's not here in FreeBSD.Adrian Chadd2013-05-011-0/+2
| | | | Notes: svn path=/head/; revision=250130
* There's no HAL_EEPROM in FreeBSD - use ar9300_eeprom_t instead.Adrian Chadd2013-05-011-1/+1
| | | | Notes: svn path=/head/; revision=250129
* Remove ancient compatibility cruft.Eitan Adler2013-04-302-123/+0
| | | | | | | Reviewed by: delphij Notes: svn path=/head/; revision=250124
* Add missing bracesEitan Adler2013-04-301-1/+2
| | | | | | | | Reviewed by: swildner@dragonflybsd.org Reviewed by: delphij Notes: svn path=/head/; revision=250123
* Fix DDP breakage introduced in r248925. Bitwise OR has higherNavdeep Parhar2013-04-301-2/+7
| | | | | | | | | precedence than ternary conditional. MFC after: 1 week Notes: svn path=/head/; revision=250117
* MFP4 change 222060:Brooks Davis2013-04-301-0/+19
| | | | | | | | | | On Intel devices, put the Factory PPR in kenv. On some FPGA boards it may be the only software accessable unique ID. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=250115
* MFP4 changes 222065 and 222068:Brooks Davis2013-04-303-1/+2
| | | | | | | | | | Add a simplebus attachment for cfi(4)'s FDT support and move cfi_bus_fdt.c to sys/conf/files so non-ppc architectures are supported. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=250114
* Partial MFC of change 228122:Brooks Davis2013-04-301-1/+1
| | | | | | | | | | Due to the requirement that tty prefixes be unique per driver, rename the Altera JTAG UART devices to ttyj#. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=250113
* use netmap_rx_irq() and netmap_tx_irq() instead of replicating theLuigi Rizzo2013-04-301-10/+3
| | | | | | | logic in the individual driver. Notes: svn path=/head/; revision=250109
* use netmap_rx_irq() / netmap_tx_irq() to handle interrupts inLuigi Rizzo2013-04-304-73/+16
| | | | | | | | | netmap mode, removing the logic from individual drivers. (note: if_lem.c not updated yet due to some other pending modifications) Notes: svn path=/head/; revision=250108
* Partial cleanup in preparation for upcoming changes:Luigi Rizzo2013-04-302-35/+87
| | | | | | | | | | | | | | | | - netmap_rx_irq()/netmap_tx_irq() can now be called by FreeBSD drivers hiding the logic for handling NIC interrupts in netmap mode. This also simplifies the case of NICs attached to VALE switches. Individual drivers will be updated with separate commits. - use the same refcount() API for FreeBSD and linux - plus some comments, typos and formatting fixes Portions contributed by Michio Honda Notes: svn path=/head/; revision=250107
* remove $Id$ (whitespace change)Luigi Rizzo2013-04-302-2/+0
| | | | Notes: svn path=/head/; revision=250106
* malloc(9) cannot return NULL if M_WAITOK flag is specified.Davide Italiano2013-04-302-17/+5
| | | | Notes: svn path=/head/; revision=250105
* The Intel PMC architectural events have encodings which are identical toDavide Italiano2013-04-302-25/+49
| | | | | | | | | | | | | | | | | | | | those of some non-architectural core events. This is not a problem in the general case as long as there's an 1:1 mapping between the two, but there are few exceptions. For example, 3CH_01H on Nehalem/Westmere represents both unhalted-reference-cycles and CPU_CLK_UNHALTED.REF_P. CPU_CLK_UNHALTED.REF_P on the aforementioned architectures does not measure reference (i.e. bus) but TSC, so there's the need to disambiguate. In order to avoid the namespace collision rename all the architectural events in a way they cannot be ambigous and refactor the architectural events handling function to reflect this change. While here, per Jim Harris request, rename iap_architectural_event_is_unsupported() to iap_event_is_architectural(). Discussed with: jimharris Reviewed by: jimharris, gnn Notes: svn path=/head/; revision=250103
* socket: Make shutdown() wake up a blocked accept().Jilles Tjoelker2013-04-301-0/+2
| | | | | | | | | | | | | | | | | | | | | | A blocking accept (and some other operations) waits on &so->so_timeo. Once it wakes up, it will detect the SBS_CANTRCVMORE bit. The error from accept() is [ECONNABORTED] which is not the nicest one -- the thread calling accept() needs to know out-of-band what is happening. A spurious wakeup on so->so_timeo appears harmless (sleep retried) except when lingering on close (SO_LINGER, and in that case there is no descriptor to call shutdown() on) so this should be fairly safe. A shutdown() already woke up a blocked accept() for TCP sockets, but not for Unix domain sockets. This fix is generic for all domains. This patch was sent to -hackers@ and -net@ on April 5. MFC after: 2 weeks Notes: svn path=/head/; revision=250102
* Complete r250097:Davide Italiano2013-04-301-3/+6
| | | | | | | Do not change the initialization order in pmc_intel_initialize(). Notes: svn path=/head/; revision=250101
* When hwpmc(4) module is unloaded it reports a double leakage. This happensDavide Italiano2013-04-301-7/+3
| | | | | | | | | | | at least if FreeBSD is ran under VirtualBox. In order to avoid the leakage, properly deallocate structures in case CPU claims that hw performance monitoring counters are not supported. Reported by: hiren Notes: svn path=/head/; revision=250097
* Fixup Westmere hwpmc(4) support: add missing CPU flag so thatDavide Italiano2013-04-301-3/+3
| | | | | | | | | | intrucion-retired, llc-misses and llc-reference events can now be allocated. Reviewed by: jimharris, gnn Notes: svn path=/head/; revision=250096
* Attach to the T580 (2 x 40G) card.Navdeep Parhar2013-04-301-1/+1
| | | | | | | MFC after: 1 week. Notes: svn path=/head/; revision=250093
* - Provide accurate ifmedia information so that 40G ports/transceivers areNavdeep Parhar2013-04-302-6/+44
| | | | | | | | | | | displayed properly in ifconfig, etc. - Use the same number of tx and rx queues for a 40G port as for a 10G port. MFC after: 1 week Notes: svn path=/head/; revision=250092
* cxgbe(4): Some updates to shared code.Navdeep Parhar2013-04-304-30/+94
| | | | | | | | Obtained from: Chelsio MFC after: 1 week Notes: svn path=/head/; revision=250090
* Pass a format string to kproc_create() [1] and thus fix the build withSergey Kandaurov2013-04-301-10/+1
| | | | | | | | | | | | -DBKTR_NEW_MSP34XX_DRIVER and -Wformat-security. This also allows to eliminates a superfluous malloc/snprintf/free on intermediate buffer. PR: kern/175546 MFC after: 1 week Notes: svn path=/head/; revision=250088
* Sync from git - ah_config is in 'ath_hal', not 'ath_hal_private' onAdrian Chadd2013-04-291-1/+1
| | | | | | | FreeBSD. Notes: svn path=/head/; revision=250082
* xenstore/xenstore.c:Justin T. Gibbs2013-04-291-1/+2
| | | | | | | | | | | Prevent access to invalid memory region when listing an empty directory in the XenStore. Reported by: Bei Guan MFC after: 1 week Notes: svn path=/head/; revision=250081
* Add a new driver to support the Intel Non-Transparent Bridge(NTB).Carl Delsey2013-04-2910-0/+2904
| | | | | | | | | | | | | | | | | | | | | | | The NTB allows you to connect two systems with this device using a PCI-e link. The driver is made of two modules: - ntb_hw which is a basic hardware abstraction layer for the device. - if_ntb which implements the ntb network device and the communication protocol. The driver is limited at the moment to CPU memcpy instead of using DMA, and only Back-to-Back mode is supported. Also the network device isn't full featured yet. These changes will be coming soon. The DMA change will also bring in the ioat driver from the project branch it is on now. This is an initial port of the GPL/BSD Linux driver contributed by Jon Mason from Intel. Any bugs are my contributions. Sponsored by: Intel Reviewed by: jimharris, joel (man page only) Approved by: jimharris (mentor) Notes: svn path=/head/; revision=250079
* Fix a bug that allows NFS clients to issue READDIR on files.Dag-Erling Smørgrav2013-04-291-0/+2
| | | | | | | | | PR: kern/178016 Security: CVE-2013-3266 Security: FreeBSD-SA-13:05.nfsserver Notes: svn path=/head/; revision=250055
* whitespace - document alternative locking under linuxLuigi Rizzo2013-04-291-0/+2
| | | | Notes: svn path=/head/; revision=250054
* Only cleanup CMI-related state on detach if the system supports CMI.John Baldwin2013-04-291-12/+10
| | | | | | | | PR: kern/163268 MFC after: 1 week Notes: svn path=/head/; revision=250053