Commit Graph

204204 Commits

Author SHA1 Message Date
Adrian Chadd
a19dbd8d6f rum(4): attach rum_update_slot to ic_updateslot.
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3631
2015-10-03 20:44:16 +00:00
Bryan Drewery
19271eb4c9 Make GCC happy 2015-10-03 20:24:23 +00:00
Bryan Drewery
7bab754097 Include stddef.h for ptrdiff_t 2015-10-03 20:06:50 +00:00
Mark Johnston
a7713f7631 The return value of posix_fadvise(2) is just an error status, so
sys_posix_fadvise() should simply return the errno (or 0) to syscallenter()
rather than setting a return value.

MFC after:	1 week
2015-10-03 19:37:41 +00:00
Alan Cox
bc7275964c Reduce the scope of a variable to the only file where it is used. 2015-10-03 19:27:52 +00:00
Bryan Drewery
0a71c082d2 Style fix. 2015-10-03 19:08:36 +00:00
Bryan Drewery
a776866b44 Add decoding for struct statfs.
Reviewed by:	jhb (briefly)
2015-10-03 18:57:15 +00:00
Adrian Chadd
b780f86455 rum(4): split rum_prepare_beacon() into 'alloc' and 'set' stages
Note: I manually had to merge this; I merged in the "put beacon_offsets
into vap" commit before this.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3628
2015-10-03 17:49:11 +00:00
Adrian Chadd
50a31b4887 rum(4): add support for AHDEMO mode.
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3627
2015-10-03 17:34:11 +00:00
Adrian Chadd
42769826d3 rum(4): simplify rum_set_bssid(), rum_set_macaddr() and rum_update_promisc()
Tested:

* rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528, STA mode

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3626
2015-10-03 17:30:57 +00:00
Bryan Drewery
c364bbdfa3 Mute this cookie as well 2015-10-03 17:28:46 +00:00
Adrian Chadd
1ba67b1130 rum(4): do not corrupt MAC address
Don't override the NIC MAC address with an overridden MAC address for
a VAP.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3625
2015-10-03 17:18:35 +00:00
Adrian Chadd
aa81f85365 rum(4): add error handling for rum_enable_tsf_sync() and rum_prepare_beacon()
Tested:

* rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528, STA mode
  Note: haven't tested AP mode yet; will do once the rest of the
  AP mode / power save commits are in.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3624
2015-10-03 17:11:21 +00:00
Alan Cox
acada7aef0 Perform a single batched update to the object's paging-in-progress count
rather than updating it for each page.
2015-10-03 17:04:52 +00:00
Adrian Chadd
6095f7cad3 rum(4): move some code from rum_init() into separate function.
Tested:

* rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528, STA mode

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3623
2015-10-03 16:37:38 +00:00
Bryan Drewery
43fa36d52c Remove redundant COMPAT_32BIT guard on pkgconfig files. This is already handled
by the LIBRARIES_ONLY mechanism protecting FILES.

Sponsored by:	EMC / Isilon Storage Division
2015-10-03 16:34:21 +00:00
Adrian Chadd
0698c0b3d1 rum(4): add error handling in initialization path
Tested:

* Tested on WUSB54GC, STA mode.
* rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528, STA mode

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3622
2015-10-03 16:21:06 +00:00
Bryan Drewery
4af9d62a19 Avoid make compatibility mode issues with creating cookies from r287844 and r287848.
Also hide the cookie creation.

Suggested by:	imp, Daniel O'Connor
2015-10-03 16:09:55 +00:00
Adrian Chadd
b2a76342fd rum(4): simplify error handling rum_raw_xmit()
Move the mbuf free responsibility to the caller of the hardware xmit
function, not the hardware xmit function itself.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3621
2015-10-03 15:58:00 +00:00
Adrian Chadd
aca2cf3032 rum(4): check mbuf size before accessing its contents
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3610
2015-10-03 15:52:58 +00:00
Adrian Chadd
a6ccd477ac rum(4): add TSF field into radiotap headers
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3607
2015-10-03 15:49:55 +00:00
Adrian Chadd
99feb20233 run(4): Add initial support for IBSS merge.
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3592
2015-10-03 15:48:21 +00:00
Hiroki Sato
1c9fbb5a26 Use getaddrinfo() to fill struct sockaddr_un. It now supports
SOCK_DGRAM and SOCK_SEQPACKET in addition to SOCK_STREAM.
2015-10-03 12:49:05 +00:00
Hiroki Sato
4c60a05d25 - Move PF_LOCAL at the end of the array. PF_INET{,6} is used more often.
- Add SOCKTYPE_ANY to PF_LOCAL.

- Apply AI_CANONNAME to only AF_INET{,6}.  It is not meaningful for the
  other AFs.
2015-10-03 12:40:54 +00:00
Hiroki Sato
6401c828ce - Schedule DAD for IN6_IFF_TENTATIVE addresses in nd6_timer(). This
catches cases that DAD probes cannot be sent because of
  IFF_UP && !IFF_DRV_RUNNING.

- nd6_dad_starttimer() now calls nd6_dad_ns_output(), instead of
  calling it before nd6_dad_starttimer().

- Do not release an entry in dadq when a duplicate entry is being
  added.
2015-10-03 12:09:12 +00:00
Alexander Motin
ec5a8cf7c0 Restore original array_rd_sz semantics.
Before r278702 prefetch was blocked for I/Os > 1MB, after -- >= 1MB.
1MB I/Os are used for bulk operations in CTL (XCOPY, VERIFY), and disabling
prefetch for them reduced the performance.

This is temporary local patch, that should be replaced when upstreamed.

Discussed with:	mahrens
MFC after:	3 days
2015-10-03 11:05:58 +00:00
Hiroki Sato
f1aaad0cd9 Add IFCAP_LINKSTATE support. 2015-10-03 09:15:23 +00:00
Adrian Chadd
30c00a2d89 Remove beacon offsets usage from if_rum.
Differential Revision: https://reviews.freebsd.org/D3658
2015-10-03 06:35:17 +00:00
Adrian Chadd
3eaa0cd531 urtwn(4): fix sequence numbering for QoS frames
Tested:

* urtwn0: MAC/BB RTL8188EU, RF 6052 1T1R, STA mode

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3684
2015-10-03 06:07:01 +00:00
Adrian Chadd
1517a7ba0b ural(4): reduce copy-paste in ural_newstate().
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3656
2015-10-03 05:55:16 +00:00
Adrian Chadd
f28c2f5e54 rum(4): add command queue for running sleepable tasks in non-sleepable contexts
Tested:

* Tested on WUSB54GC, STA mode.
* rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3629
2015-10-03 05:46:35 +00:00
Adrian Chadd
e7b7db3d59 rum(4): some non-functional changes / cleanup
* Remove unused sc_txtap_len/sc_rxtap_len fields.
* Remove unused ackrate variable.
* Remove unneded warning in rum_update_mcast().
* Use nitems().
* Replace some hardcoded values for RT2573_MAC_CSR1 register.
* Remove second argument for RUM_LOCK_ASSERT() - it is always the same.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3605
2015-10-03 05:44:05 +00:00
Alexander V. Chernikov
c6fb65b1df Bump number of prefixes in O_IP_<SRC|DST> from 15 to 31 (max possible).
PR:		203459
Submitted by:	groos at xiplink.com
MFC after:	2 weeks
2015-10-03 05:42:25 +00:00
Andrey V. Elsukov
1a6fb597b0 Always detach encap handler when reconfiguring tunnel.
Reported by:	hrs
MFC after:	1 week
2015-10-03 03:57:58 +00:00
Andrey V. Elsukov
56afe65ca9 Fix possible segmentation fault.
PR:		203494
MFC after:	1 week
2015-10-03 03:12:57 +00:00
Adrian Chadd
15395998e9 net80211: add a possibility to retrieve current TX key without encapsulation.
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3639
2015-10-03 00:57:33 +00:00
Adrian Chadd
c0cb93498d net80211: add new method for ieee80211_cipher (ic_setiv).
This can be used to update IV state for the caller without adding
information to the mbuf.  Some hardware (eg rum) apparently requires
bits of this.

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3638
2015-10-03 00:50:13 +00:00
Adrian Chadd
483755be00 net80211: get rid of tx_phase1_done flag (ieee80211_crypto_tkip.c).
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3596
2015-10-03 00:03:07 +00:00
Peter Grehan
056e398239 Fix post-test typo that snuck in. 2015-10-02 22:05:51 +00:00
Adrian Chadd
ef0d8f6351 net80211: separate ieee80211_crypto_get_keyid() from ieee80211_crypto_encap()
Tested:

* rum(4), STA mode
* rsu(4), STA mode
* urtwn(4), STA mode

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3637
2015-10-02 21:25:48 +00:00
Peter Grehan
88ac695858 Simple sysctl-like firmware query interface. Similar in operation
to the qemu one, and uses the same i/o ports but with different
messaging. Requires the 'bootrom' option to be enabled.

This is used by UEFI (and potentially other BIOSs/firmware) to
request information from bhyve. Currently, only the number of
vCPUs is made available, with more to follow.

A very large thankyou to Ben Perrault who helped out testing
an earlier version of this, and bhyve/Windows in general.

Reviewed by:	tychon
Discussed with:	neel
Sponsored by:	Nahanni Systems
2015-10-02 21:09:49 +00:00
Bryan Drewery
d522a3105a All the games moved to usr.bin/ in r288485.
Sponsored by:	EMC / Isilon Storage Division
2015-10-02 17:58:16 +00:00
Bryan Drewery
121d64e166 Remove defunct games removed in r279150.
Sponsored by:	EMC / Isilon Storage Division
2015-10-02 17:54:05 +00:00
Bryan Drewery
2e23180475 /usr/src/games was removed in r288485. 2015-10-02 17:51:47 +00:00
Xin LI
0ed633d0f8 Fix a regression with SA-15:24 patch that prevented NIS from
working.
2015-10-02 16:35:41 +00:00
Adrian Chadd
d847071cf6 rum(4): sync rum_enable_tsf(_sync) with run(4).
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3611
2015-10-02 15:30:37 +00:00
Adrian Chadd
a05022b22c rum(4): create few wrappers.
Tested:

rum0: <Belkin Belkin 54g USB Network Adapter, class 0/0, rev 2.00/0.01, addr 22> on usbus0
rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3609
2015-10-02 15:28:44 +00:00
Adrian Chadd
cc9ae76160 rum(4): move common part of rum_bbp_write() and rum_bbp_read() into rum_bbp_busy().
Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3608
2015-10-02 15:26:33 +00:00
Adrian Chadd
6d8043213d rum(4): reduce code duplication.
Tested:

rum0: <Belkin Belkin 54g USB Network Adapter, class 0/0, rev 2.00/0.01, addr 21> on usbus0
rum0: MAC/BBP RT2573 (rev 0x2573a), RF RT2528

Submitted by:	<s3erios@gmail.com>
Differential Revision:	https://reviews.freebsd.org/D3606
2015-10-02 15:22:00 +00:00
Konstantin Belousov
5821213b4c Add aarch64 support to truss(1).
Reviewed by:	jhb
Discussed with:	emaste (license)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D3750
2015-10-02 13:30:56 +00:00