]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
8 years ago- Allocate more space than needed for icl_conn and icl_pdu. The extra
Navdeep Parhar [Tue, 29 Sep 2015 22:33:26 +0000 (22:33 +0000)]
- Allocate more space than needed for icl_conn and icl_pdu.  The extra
  space will be used for driver specific items.

- Do not use the same name as icl_soft for the PDU zone.

8 years ago- Fix minor memory leak (ic_offload is never freed).
Navdeep Parhar [Tue, 29 Sep 2015 21:57:52 +0000 (21:57 +0000)]
- Fix minor memory leak (ic_offload is never freed).

- Remove unused icl_pdu_stailq.

- Do not use the same names as icl_soft for the global connection
  counter or for the per-connection send/recv CVs.

8 years agoUse the base driver's malloc type instead of creating a new one.
Navdeep Parhar [Tue, 29 Sep 2015 21:16:35 +0000 (21:16 +0000)]
Use the base driver's malloc type instead of creating a new one.

8 years ago- Remove unused or write-only fields from ulp_mbuf_cb.
Navdeep Parhar [Tue, 29 Sep 2015 21:07:33 +0000 (21:07 +0000)]
- Remove unused or write-only fields from ulp_mbuf_cb.

- Remove write-only SBUF_ULP_FLAG_COALESCE_OFF flag.

- Failure to allocate ulp_mbuf_cb during rx is a hard error.  Panic
  instead of just freeing the mbuf and pretending nothing happened.  The
  payload in the mbuf is precious because it has been ACK'ed by the TOE.
  (ulp_mbuf_cb is going to go away soon and so will these potential
  failures during rx.)

8 years agoSync up with head (up to r288341).
Navdeep Parhar [Mon, 28 Sep 2015 17:30:07 +0000 (17:30 +0000)]
Sync up with head (up to r288341).

8 years agoHonor VMFORMATS and VMSIZE if set in release.conf.
Glen Barber [Mon, 28 Sep 2015 16:33:38 +0000 (16:33 +0000)]
Honor VMFORMATS and VMSIZE if set in release.conf.

PR: 203420
Submitted by: luca <dot> pizzamiglio <at> gmail <dot> com
MFC after: 3 days
Sponsored by: The FreeBSD Foundation

8 years agodefine aok in libnvpair which is linked to all zfs libraries that need aok
Andriy Gapon [Mon, 28 Sep 2015 15:25:36 +0000 (15:25 +0000)]
define aok in libnvpair which is linked to all zfs libraries that need aok

This removes the circular dependency of libnvpair on libzfs / libzpool.

PR: 199811
Obtained from: bapt
MFC after: 23 days

8 years agoremove unused sgsmsg utility (originally imported from opensolaris)
Andriy Gapon [Mon, 28 Sep 2015 12:38:57 +0000 (12:38 +0000)]
remove unused sgsmsg utility (originally imported from opensolaris)

MFC after: 25 days

8 years agoremove an extra copy of avl.c from illumos contrib code
Andriy Gapon [Mon, 28 Sep 2015 12:23:10 +0000 (12:23 +0000)]
remove an extra copy of avl.c from illumos contrib code

MFC after: 20 days

8 years agosave some bytes by using more concise SDT_PROBE<n> instead of SDT_PROBE
Andriy Gapon [Mon, 28 Sep 2015 12:14:16 +0000 (12:14 +0000)]
save some bytes by using more concise SDT_PROBE<n> instead of SDT_PROBE

SDT_PROBE requires 5 parameters whereas SDT_PROBE<n> requires n parameters
where n is typically smaller than 5.

Perhaps SDT_PROBE should be made a private implementation detail.

MFC after: 20 days

8 years agoStore PID after becoming a daemon() and not before to ensure the
Hans Petter Selasky [Mon, 28 Sep 2015 07:23:05 +0000 (07:23 +0000)]
Store PID after becoming a daemon() and not before to ensure the
correct PID gets written to the PID file.

Submitted by: Maxime Soule <btik-fbsd@scoubidou.com>
PR: 203252
MFC after: 2 weeks

8 years agoRemove some debugging that wasn't supposed to be there.
Adrian Chadd [Mon, 28 Sep 2015 06:26:46 +0000 (06:26 +0000)]
Remove some debugging that wasn't supposed to be there.

8 years agoAdd initial testcases for bin/ls
Enji Cooper [Mon, 28 Sep 2015 03:36:15 +0000 (03:36 +0000)]
Add initial testcases for bin/ls

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

8 years agoinclude opt_wlan.h . Tsk adrian.
Adrian Chadd [Mon, 28 Sep 2015 01:16:44 +0000 (01:16 +0000)]
include opt_wlan.h .  Tsk adrian.

8 years agoif_otus fixes; add fast-frames support.
Adrian Chadd [Mon, 28 Sep 2015 01:09:48 +0000 (01:09 +0000)]
if_otus fixes; add fast-frames support.

Fast-frames:

* include opt_wlan.h ; tsk to not doing it earlier;
* add a tx pending tracking counter for seeing how deep
  the hardware TX queue is;
* add the frame aging code from if_ath;
* add fast-frames capability to the driver setup.

Bugs:

* free the buffers (and node references) before
  detaching net80211 state.  This prevents a use-after-free in
  the node free path where we've destroyed net80211 underneath it.

8 years agoMigrate the fast-frames transmit support away from using the txa_private
Adrian Chadd [Mon, 28 Sep 2015 00:59:07 +0000 (00:59 +0000)]
Migrate the fast-frames transmit support away from using the txa_private
field and into a separate fast-frames staging pointer in ieee80211_node.

The A-MPDU TX path allows txa_private to be used by drivers.  So it will
clash with any attempt to use fast-frames.  Now, fast-frames is not really
anything special - it's just a custom ethernet frame type that contains
two MSDUs into one MPDU.  So all the NIC has to support doing is transmitting
up to a 4KiB frame with an arbitrary ethertype and bam! Fast-frames.
However, using txa_private means we can /either/ do fast-frames or A-MPDU TX,
so fast frames has been turned off in the Atheros HAL for 11n chipsets.
This is a bit silly - it actually means that 802.11 performance to/from
11abg Atheros chips is actually better than between an 11abg atheros device
and an 11n Atheros device.

So:

* create a new mbuf staging queue for fast frames.  It only queues a single
  frame in the staging queue (and there's a top-level ic staging queue
  used for expiry/tracking) so it's just an mbuf pointer per TID.

* Still use the ampdu TX packet counter to determine whether to do
  aggregation or not.  It'll double count if we start doing both A-MPDU TX
  and fast frames, but that's not all that important right now.

* Initialise the pps tracker so ticks isn't zero.  This ensures that
  fast-frames actually gets used - without it, the ticks math overflows
  and the pps math always sets txa_pps=0.  This is the same bug that
  plagued A-MPDU TX starting logic.

This actually allows fast-frames transmit to occur between the AR9331
(in 11n HT/20 mode) and AR9170 (if_otus) in 11bg mode.

Now, this is a great big no-op on atheros 11n hardware, so don't worry.
It may mean you start seeing more reliable fast-frames transmission on
11abg hardware which may expose some more amusing bugs.

TODO:

* further testing and debugging of all of this before flipping on
  fast-frames in if_ath (for 11n) and if_otus.

8 years agoComments, mostly to remind myself of what's going on and why.
Adrian Chadd [Mon, 28 Sep 2015 00:51:24 +0000 (00:51 +0000)]
Comments, mostly to remind myself of what's going on and why.

8 years agoAbstract out the ampdu TX pps initialisation code so it can be reused
Adrian Chadd [Mon, 28 Sep 2015 00:17:51 +0000 (00:17 +0000)]
Abstract out the ampdu TX pps initialisation code so it can be reused
in the superg fast-frames code.

This harks back to an earlier commit (r280349) where I found that
initialising the pps code with ticks=0 would cause hilariously bad
hz ticks wraparound failures, leading to never actually aggregating
traffic.  This is still true for the superg path and so I have to
do the same thing there.

This is a big no-op; a subsequent commit will flip this on so it
works with the fast-frames transmit path.

Tested:

* AR9170, otus(4) - STA mode, 11bg operation
* AR9331, AP mode

8 years agoFix whitespace error in ls(1) detected by igor
Allan Jude [Sun, 27 Sep 2015 22:05:20 +0000 (22:05 +0000)]
Fix whitespace error in ls(1) detected by igor

Approved by: bcr (mentor)
Sponsored by: EuroBSDCon DevSummit

8 years agoUse one fewer made up words in the ls(1) man page
Allan Jude [Sun, 27 Sep 2015 22:02:46 +0000 (22:02 +0000)]
Use one fewer made up words in the ls(1) man page

PR: 203337
Submitted by: Mike Dame <damemi@gmail.com>
Approved by: bcr (mentor)
Sponsored by: EuroBSDCon DevSummit

8 years agoSet the #address-cells and #size-cells for the I2C controllers in RPi2.
Luiz Otavio O Souza [Sun, 27 Sep 2015 18:21:22 +0000 (18:21 +0000)]
Set the #address-cells and #size-cells for the I2C controllers in RPi2.

This allows the use of I2C addresses in 'reg' property.

8 years agoAdd to CTL initial support for CDROMs and removable devices.
Alexander Motin [Sun, 27 Sep 2015 13:47:28 +0000 (13:47 +0000)]
Add to CTL initial support for CDROMs and removable devices.

Relnotes: yes

8 years agofnmatch(): Remove exponential behaviour as in sh r229201.
Jilles Tjoelker [Sun, 27 Sep 2015 12:52:18 +0000 (12:52 +0000)]
fnmatch(): Remove exponential behaviour as in sh r229201.

The old code was exponential in the number of asterisks in the pattern.
However, once a match has been found upto the next asterisk, the previous
asterisks are no longer relevant.

8 years agoFix what looks like a consistent copy&paste error.
Bjoern A. Zeeb [Sun, 27 Sep 2015 12:19:36 +0000 (12:19 +0000)]
Fix what looks like a consistent copy&paste error.
Don't make an integer to a boolean and then compare to a value which
needs an integer comparison.

Spotted by: reading kernel compile time log
MFC after: 2 weeks

8 years agoCompare the correct variable to see if memory allocation succeeded.
Bjoern A. Zeeb [Sun, 27 Sep 2015 12:17:03 +0000 (12:17 +0000)]
Compare the correct variable to see if memory allocation succeeded.
I don't even want to know where the symbol "version" comes from.

Spotted by: reading kernel compile time log
MFC after: 2 weeks

8 years agoAdd support to systat to display zfs arc cache status/info
Michael Reifenberger [Sun, 27 Sep 2015 09:15:54 +0000 (09:15 +0000)]
Add support to systat to display zfs arc cache status/info

PR: 195460
Submitted by: ota

8 years agoReplace N #defines with nitems to simplify ifconfig code slightly
Enji Cooper [Sun, 27 Sep 2015 07:51:18 +0000 (07:51 +0000)]
Replace N #defines with nitems to simplify ifconfig code slightly

MFC after: 1 week

8 years agoEnable parallel subdirectory building with sys/modules/netgraph
Enji Cooper [Sun, 27 Sep 2015 07:40:19 +0000 (07:40 +0000)]
Enable parallel subdirectory building with sys/modules/netgraph

MFC after: 2 weeks

8 years agoMFV r288243: nc from OpenBSD 5.8.
Xin LI [Sun, 27 Sep 2015 07:04:16 +0000 (07:04 +0000)]
MFV r288243: nc from OpenBSD 5.8.

8 years agoEliminate nd6_nud_hint() and its TCP bindings.
Alexander V. Chernikov [Sun, 27 Sep 2015 05:29:34 +0000 (05:29 +0000)]
Eliminate nd6_nud_hint() and its TCP bindings.

Initially function was introduced in r53541 (KAME initial commit) to
  "provide hints from upper layer protocols that indicate a connection
  is making "forward progress"" (quote from RFC 2461 7.3.1 Reachability
  Confirmation).
However, it was converted to do nothing (e.g. just return) in r122922
  (tcp_hostcache implementation) back in 2003. Some defines were moved
  to tcp_var.h in r169541. Then, it was broken (for non-corner cases)
  by r186119 (L2<>L3 split) in 2008 (NULL ifp in nd6_lookup). So,
  right now this code is broken and has no "real" base users.

Differential Revision: https://reviews.freebsd.org/D3699

8 years ago - Collapse vfs_vmio_truncate & vfs_vmio_release into a single function.
Jeff Roberson [Sun, 27 Sep 2015 05:16:06 +0000 (05:16 +0000)]
 - Collapse vfs_vmio_truncate & vfs_vmio_release into a single function.
 - Allow vfs_vmio_invalidate() to free the pages, leaving us with a
   single loop and bufobj lock when B_NOCACHE/B_INVAL is used.
 - Eliminate the special B_ASYNC handling on free that has not been
   relevant for some time.
 - Remove the extraneous page busy from vfs_vmio_truncate().

Reviewed by: kib
Tested by: pho
Sponsored by: EMC / Isilon storage division

8 years agoRemove MLINKS to more non-existent mbuf(9) macros
Enji Cooper [Sun, 27 Sep 2015 04:55:43 +0000 (04:55 +0000)]
Remove MLINKS to more non-existent mbuf(9) macros

X-MFC with: r288295
MFC after: 3 days
Sponsored by: EMC / Isilon Storage Division

8 years agortsock requests for deleting interface address lles started to return EPERM
Alexander V. Chernikov [Sun, 27 Sep 2015 04:54:29 +0000 (04:54 +0000)]
rtsock requests for deleting interface address lles started to return EPERM
  instead of old "ignore-and-return 0" in r287789. This broke arp -da /
  ndp -cn behavior (they exit on rtsock command failure). Fix this by
  translating LLE_IFADDR to RTM_PINNED flag, passing it to userland and
  making arp/ndp ignore these entries in batched delete.

MFC after: 2 weeks

8 years agoPosthumously remove all references to MFREE(9)
Enji Cooper [Sun, 27 Sep 2015 04:40:54 +0000 (04:40 +0000)]
Posthumously remove all references to MFREE(9)

The macro was removed in r90227

MFC after: 3 days
Sponsored by: EMC / Isilon Storage Division

8 years agoEnforce consistent limits of daemons run from rc.subr:
Adrian Chadd [Sun, 27 Sep 2015 04:03:11 +0000 (04:03 +0000)]
Enforce consistent limits of daemons run from rc.subr:

* Allow the user to configure the login class to use in rc.conf
  by using {daemon}_login_class, which;
* Use the daemon class by default;
* .. and then use 'limits' to set the login class so it works both
  via init at startup (which runs this in 'daemon' class) and via
  whichever root environment (eg command line, other daemons, etc.)

Reviewed by: dteske
Differential Revision: https://reviews.freebsd.org/D3630

8 years agoTrack the command response code buffer size and verify it in the
Adrian Chadd [Sun, 27 Sep 2015 03:46:55 +0000 (03:46 +0000)]
Track the command response code buffer size and verify it in the
receive path.

8 years agoThe conversion of kmem_alloc_attr() from operating on a vm map to a vmem
Alan Cox [Sat, 26 Sep 2015 22:57:10 +0000 (22:57 +0000)]
The conversion of kmem_alloc_attr() from operating on a vm map to a vmem
arena in r254025 introduced a bug in the case when an allocation is only
partially successful.  Specifically, the vm object lock was not being
acquired before freeing the allocated pages.  To address this bug, replace
the existing code by a call to kmem_unback().

Change the type of a variable in kmem_alloc_attr() so that an allocation
of two or more gigabytes won't fail.

Replace the error handling code in kmem_back() by a call to kmem_unback().

Reviewed by: kib (an earlier version)
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

8 years agoRemove a check for a condition that is always false by a preceding KASSERT
Mark Johnston [Sat, 26 Sep 2015 22:26:55 +0000 (22:26 +0000)]
Remove a check for a condition that is always false by a preceding KASSERT
that was added in r144704.

8 years agoFree the TX/RX list buffers /before/ tearing down net80211 state.
Adrian Chadd [Sat, 26 Sep 2015 22:20:30 +0000 (22:20 +0000)]
Free the TX/RX list buffers /before/ tearing down net80211 state.

Otherwise buffers in the RX queue get freed with their parent vap
being gone and you end up with a juicy kernel panic.

8 years agoDocument the interface for applying advice up to the end of a file.
Mark Johnston [Sat, 26 Sep 2015 22:20:11 +0000 (22:20 +0000)]
Document the interface for applying advice up to the end of a file.

MFC after: 3 days

8 years agoOops - commit the correct manpage content for otusfw.4.
Adrian Chadd [Sat, 26 Sep 2015 22:19:07 +0000 (22:19 +0000)]
Oops - commit the correct manpage content for otusfw.4.

8 years agoFix argument ordering in vn_printf().
Mark Johnston [Sat, 26 Sep 2015 22:16:54 +0000 (22:16 +0000)]
Fix argument ordering in vn_printf().

MFC after: 3 days

8 years agoRevert r288270 to fix the build
Conrad Meyer [Sat, 26 Sep 2015 20:26:05 +0000 (20:26 +0000)]
Revert r288270 to fix the build

Submitted by: bdrewery
Sponsored by: EMC / Isilon Storage Division

8 years agoExploit r288122 to address a cosmetic issue. Since the pages allocated
Alan Cox [Sat, 26 Sep 2015 17:45:10 +0000 (17:45 +0000)]
Exploit r288122 to address a cosmetic issue.  Since the pages allocated
by noobj_alloc() don't belong to a vm object, they can't be paged out.
Since they can't be paged out, they are never enqueued in a paging queue.
Nonetheless, passing PQ_INACTIVE to vm_page_unwire() creates the appearance
that these pages are being enqueued in the inactive queue.  As of r288122,
we can avoid giving this false impression by passing PQ_NONE.

Submitted by: kmacy
Differential Revision: https://reviews.freebsd.org/D1674

8 years agoFix spelling.
Hans Petter Selasky [Sat, 26 Sep 2015 16:48:25 +0000 (16:48 +0000)]
Fix spelling.

Submitted by: Maxime Soule <btik-fbsd@scoubidou.com>
PR: 203249
MFC after: 2 weeks

8 years agoIncrease group limit for kerberized NFSv4
Josh Paetzel [Sat, 26 Sep 2015 16:30:16 +0000 (16:30 +0000)]
Increase group limit for kerberized NFSv4

PR: 202659
Submitted by: matthew.l.dailey@dartmouth.edu
Reviewed by: rmacklem dfr
MFC after: 1 week
Sponsored by: iXsystems

8 years agoDocument bus_get_resource(9).
Conrad Meyer [Sat, 26 Sep 2015 14:52:47 +0000 (14:52 +0000)]
Document bus_get_resource(9).

Suggested by: Francois Tigeot
Obtained from: DragonFlyBSD 09301a2b29f3ae5edd39a858f909f8770372f71e
Sponsored by: EMC / Isilon Storage Division

8 years agoHookup mkcsmapper_static and mkesdb_static for all but install.
Bryan Drewery [Sat, 26 Sep 2015 14:28:04 +0000 (14:28 +0000)]
Hookup mkcsmapper_static and mkesdb_static for all but install.

These are only handled as 'build-tools' in Makefile.inc1.  This causes
'make clean' from the top of the tree to not clean the directories.  It also
effectively has kept them disconnected and risks them bitrotting.  The
buildworld process never cleans them either.

Connect them so they will always be built, cleaned, etc, but never installed.

Discussed with: imp (briefly)
Sponsored by: EMC / Isilon Storage Division

8 years agoRevert r288268. Wrong change committed.
Bryan Drewery [Sat, 26 Sep 2015 14:27:21 +0000 (14:27 +0000)]
Revert r288268.  Wrong change committed.

8 years agoHookup mkcsmapper_static and mkesdb_static for all but install.
Bryan Drewery [Sat, 26 Sep 2015 14:26:08 +0000 (14:26 +0000)]
Hookup mkcsmapper_static and mkesdb_static for all but install.

These are only handled as 'build-tools' in Makefile.inc1.  This causes
'make clean' from the top of the tree to not clean the directories.  It also
effectively has kept them disconnected and risks them bitrotting.  The
buildworld process never cleans them either.

Connect them so they will always be built, cleaned, etc, but never installed.

Discussed with: imp (briefly)
Sponsored by: EMC / Isilon Storage Division

8 years agoRemove redundant .NOPATH.
Bryan Drewery [Sat, 26 Sep 2015 14:15:01 +0000 (14:15 +0000)]
Remove redundant .NOPATH.

All of these are already in CLEANFILES which is added to .NOPATH in bsd.obj.mk.

Sponsored by: EMC / Isilon Storage Division

8 years agoAdd more SUBDIR_PARALLEL.
Bryan Drewery [Sat, 26 Sep 2015 14:13:51 +0000 (14:13 +0000)]
Add more SUBDIR_PARALLEL.

MFC after: 3 weeks
Sponsored by: EMC / Isilon Storage Division

8 years agoWait up to 10 seconds for late-initializing network interfaces to arrive.
Ian Lepore [Sat, 26 Sep 2015 13:55:55 +0000 (13:55 +0000)]
Wait up to 10 seconds for late-initializing network interfaces to arrive.

Reviewed by: rmacklem

8 years agoAllow LOG SENSE command on non-disk devices.
Alexander Motin [Sat, 26 Sep 2015 13:51:29 +0000 (13:51 +0000)]
Allow LOG SENSE command on non-disk devices.

8 years agoDon't duplicate checks; net80211 now does this for us.
Adrian Chadd [Sat, 26 Sep 2015 13:22:44 +0000 (13:22 +0000)]
Don't duplicate checks; net80211 now does this for us.

Submitted by: s3erios@gmail.com

8 years agoRemove concept of control device.
Alexander Motin [Sat, 26 Sep 2015 12:53:55 +0000 (12:53 +0000)]
Remove concept of control device.

8 years agoMove ioctl frontend defines where they belong.
Alexander Motin [Sat, 26 Sep 2015 11:56:28 +0000 (11:56 +0000)]
Move ioctl frontend defines where they belong.

8 years agoRemove few more unused variables.
Alexander Motin [Sat, 26 Sep 2015 11:39:54 +0000 (11:39 +0000)]
Remove few more unused variables.

8 years agoRemove some duplicate, legacy, dead and questionable code.
Alexander Motin [Sat, 26 Sep 2015 11:28:45 +0000 (11:28 +0000)]
Remove some duplicate, legacy, dead and questionable code.

8 years agoMake the __bitcount*() functions unconditionally available, by moving
Konstantin Belousov [Sat, 26 Sep 2015 07:30:45 +0000 (07:30 +0000)]
Make the __bitcount*() functions unconditionally available, by moving
them out of the #if _BSD_VISIBLE block.  Other headers may depend on
__bitcount().  The dependencies can be a header not specified by
POSIX, and then namespace restrictions by _XOPEN_SOURCE are not
applicable, as it was reported.  Or, we might grow an implementation
of some POSIX facility using __bitcount(), which also should work.

Reported by: Jason Schulz <schulz.j@gmail.com>
Discussed with: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks

8 years ago* Add 11n HT40 support - i needed to send both HTINFO and HTCAP fields
Adrian Chadd [Sat, 26 Sep 2015 07:25:53 +0000 (07:25 +0000)]
* Add 11n HT40 support - i needed to send both HTINFO and HTCAP fields
  in the join message so the firmware would pick it up.

* Strip out the direct hardware fiddling for 40MHz mode - the firmware
  we're using doesn't require it (the rtl8712su firmware does; it
  is less 'fullmac' than what we're using.)

* Fix the mbuf handling during errors - rsu_tx shouldn't free mbufs;
  it's up to the caller to do so.  This brings it in line with
  what other drivers do or should be doing.

Tested:

* RTL8712, HT40 channel, STA mode (during this commit)

8 years agoExploit r288122 to address a cosmetic issue. Since PV chunk pages don't
Alan Cox [Sat, 26 Sep 2015 07:18:05 +0000 (07:18 +0000)]
Exploit r288122 to address a cosmetic issue.  Since PV chunk pages don't
belong to a vm object, they can't be paged out.  Since they can't be paged
out, they are never enqueued in a paging queue.  Nonetheless, passing
PQ_INACTIVE to vm_page_unwire() creates the appearance that these pages
are being enqueued in the inactive queue.  As of r288122, we can avoid
this false impression by passing PQ_NONE.

Submitted by: kmacy (an earlier version)
Differential Revision: https://reviews.freebsd.org/D1674

8 years agoFix a bug in the TX command handling - log when a too-large payload is
Adrian Chadd [Sat, 26 Sep 2015 07:14:00 +0000 (07:14 +0000)]
Fix a bug in the TX command handling - log when a too-large payload is
sent, and fix a bug I found when doing so.

8 years agoAdd man pages for the AR9170 and AR9170 firmware.
Adrian Chadd [Sat, 26 Sep 2015 07:09:46 +0000 (07:09 +0000)]
Add man pages for the AR9170 and AR9170 firmware.

8 years agoAdd an initial driver for the AR9170 series draft-11n hardware from
Adrian Chadd [Sat, 26 Sep 2015 07:08:35 +0000 (07:08 +0000)]
Add an initial driver for the AR9170 series draft-11n hardware from
Atheros.

Thanks to OpenBSD for providing a driver based on the original
Atheros open source driver circa 2008.  This uses the early, pre-carl9170
atheros provided firmware.

It only supports 11bg at the moment.  I've not tested it with 11a
(and so the TX rate control logic may be slightly wrong!) so if
you do have the dual-band version of this hardware please do let me know.

Tested:

* AR9170, TP-Link WN821N 2GHz.

TODO:

* Hook this up to a non-module build.

8 years agoUpdate USB device IDs for the upcoming AR9170 support.
Adrian Chadd [Sat, 26 Sep 2015 06:57:08 +0000 (06:57 +0000)]
Update USB device IDs for the upcoming AR9170 support.

8 years agoMETA_MODE: Make it easier to keep the bootstrap-tools args in sync.
Bryan Drewery [Sat, 26 Sep 2015 04:22:18 +0000 (04:22 +0000)]
META_MODE: Make it easier to keep the bootstrap-tools args in sync.

Sponsored by: EMC / Isilon Storage Division

8 years agoAdd SUBDIR_PARALLEL.
Bryan Drewery [Sat, 26 Sep 2015 01:28:50 +0000 (01:28 +0000)]
Add SUBDIR_PARALLEL.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

8 years agoRemove disconnected directories.
Bryan Drewery [Sat, 26 Sep 2015 01:24:35 +0000 (01:24 +0000)]
Remove disconnected directories.

These were added disconnected in 2005 in r145524.

Sponsored by: EMC / Isilon Storage Division

8 years agoPass to sobind() copy of the address, not the original.
Alexander Motin [Sat, 26 Sep 2015 01:23:29 +0000 (01:23 +0000)]
Pass to sobind() copy of the address, not the original.

8 years agoAdd missing CLEANFILES.
Bryan Drewery [Sat, 26 Sep 2015 01:04:52 +0000 (01:04 +0000)]
Add missing CLEANFILES.

MFC after: 1 week
X-MFC-With: r288199
Sponsored by: EMC / Isilon Storage Division

8 years agoPerform some rather amusing layering violations to add mbuf tags to the
Adrian Chadd [Sat, 26 Sep 2015 00:53:37 +0000 (00:53 +0000)]
Perform some rather amusing layering violations to add mbuf tags to the
net80211 receive path.  This allows drivers (notably USB right now, but
anything/everything!) to optionally defer bulk RX of 802.11 frames until
/outside/ of the driver lock(s), rather than doing:

UNLOCK(sc);
ieee80211_input*()
LOCK(sc);

.. which is really stupid.

The existing API is maintaned - if ieee80211_input() / ieee80211_input_all()
is called then the RSSI/NF values are used.  If the MIMO versions are called
with a given rx status pointer then it's used. Else, it'll use whatever
is in the RX mbuf tag.

8 years agoVendor import nc(1) from OPENBSD_5_8.
Xin LI [Sat, 26 Sep 2015 00:19:13 +0000 (00:19 +0000)]
Vendor import nc(1) from OPENBSD_5_8.

8 years agoCompare the newly allocated array elements to NULL in order to see
Bjoern A. Zeeb [Fri, 25 Sep 2015 23:07:17 +0000 (23:07 +0000)]
Compare the newly allocated array elements to NULL in order to see
if the malloc succeeded.

Spotted by: reading kernel compile time log
MFC after: 2 weeks

8 years agoRemove 'set -e' that are no longer needed as it is already default.
Bryan Drewery [Fri, 25 Sep 2015 23:03:32 +0000 (23:03 +0000)]
Remove 'set -e' that are no longer needed as it is already default.

When bmake was initially imported at r241298 shell commands were no longer
ran with 'set -e' as they were before.  This was fixed in r254980 so they
again always use 'set -e'.

Sponsored by: EMC / Isilon Storage Division

8 years agoExplicitly enable .MAKE.ALWAYS_PASS_JOB_QUEUE for bmake.
Bryan Drewery [Fri, 25 Sep 2015 22:51:30 +0000 (22:51 +0000)]
Explicitly enable .MAKE.ALWAYS_PASS_JOB_QUEUE for bmake.

This is a NOP as r254419 enabled this by default in bmake.  Add it here though
to ensure it is known that we are using this as a default and in case a
bmake import removes the default we have.

This tells bmake to always pass job tokens into sub-commands.  Otherwise
it would only do so if the target being built depended on the special
.MAKE target (which causes _all_ commands to be executed with -n as well)
or if the command matches '${MAKE}/${.MAKE}/$(MAKE)/$(.MAKE)/make' (before
expansion, so ${LIB32WMAKE} would not qualify).  Using '+' on a command
(which runs the command with -n) would not pass the job token even though it
is a documented way to achieve the .MAKE effect on a command.

Sponsored by: EMC / Isilon Storage Division

8 years agoProperly lock LUN in ctl_failover_lun().
Alexander Motin [Fri, 25 Sep 2015 22:45:23 +0000 (22:45 +0000)]
Properly lock LUN in ctl_failover_lun().

8 years agoMFV c3ccd112: Correct off-by-ones in free_exception of emergency buffer
Conrad Meyer [Fri, 25 Sep 2015 22:29:21 +0000 (22:29 +0000)]
MFV c3ccd112: Correct off-by-ones in free_exception of emergency buffer

Note, this has been broken since import in r227825.

PR: https://github.com/pathscale/libcxxrt/issues/29
Reviewed by: emaste (earlier version), kan (informally)
Obtained from: Anton Rang
Relnotes: yes
Sponsored by: EMC / Isilon Storage Division
Differential Revision: https://reviews.freebsd.org/D3733

8 years agoRemove apostrophe from AP's for consistency (arm64 mp_machdep)
Ed Maste [Fri, 25 Sep 2015 21:04:31 +0000 (21:04 +0000)]
Remove apostrophe from AP's for consistency (arm64 mp_machdep)

8 years agoAdd missing binutils ldscripts.
Bryan Drewery [Fri, 25 Sep 2015 20:45:10 +0000 (20:45 +0000)]
Add missing binutils ldscripts.

Some of these are after the fix in r288230 to install them.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

8 years agoFix subdir -j build after r287983 by adding missing dependencies.
Bryan Drewery [Fri, 25 Sep 2015 20:31:04 +0000 (20:31 +0000)]
Fix subdir -j build after r287983 by adding missing dependencies.

Sponsored by: EMC / Isilon Storage Division

8 years agoBuild ofwdump(8) on MIPS too
Ed Maste [Fri, 25 Sep 2015 20:26:59 +0000 (20:26 +0000)]
Build ofwdump(8) on MIPS too

It will be useful as FDT sees increasing usage on FreeBSD/mips.

Sponsored by: DARPA, AFRL

8 years agoxinstall: renumber UCB clauses to avoid skipping #3
Ed Maste [Fri, 25 Sep 2015 20:25:18 +0000 (20:25 +0000)]
xinstall: renumber UCB clauses to avoid skipping #3

8 years agoFix emulation ldscripts not being installed since r131832.
Bryan Drewery [Fri, 25 Sep 2015 20:21:45 +0000 (20:21 +0000)]
Fix emulation ldscripts not being installed since r131832.

For example, 32bit scripts on 64bit host.

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

8 years agoFix bit masks changed for the wrong commands in r288221.
Alexander Motin [Fri, 25 Sep 2015 19:46:34 +0000 (19:46 +0000)]
Fix bit masks changed for the wrong commands in r288221.

8 years agoMETA_MODE: Remove DEP_MACHINE from Makefile.depend files.
Bryan Drewery [Fri, 25 Sep 2015 19:44:01 +0000 (19:44 +0000)]
META_MODE: Remove DEP_MACHINE from Makefile.depend files.

This has not been needed since r246865 in projects/bmake.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA_MODE: Checkin a proper Makefile.depend.
Bryan Drewery [Fri, 25 Sep 2015 19:33:38 +0000 (19:33 +0000)]
META_MODE: Checkin a proper Makefile.depend.

Sponsored by: EMC / Isilon Storage Division

8 years agoMETA_MODE: Remove DEP_RELDIR from Makefile.depend files.
Bryan Drewery [Fri, 25 Sep 2015 19:26:08 +0000 (19:26 +0000)]
META_MODE: Remove DEP_RELDIR from Makefile.depend files.

This has not been needed since r284171 in projects/bmake.

Sponsored by: EMC / Isilon Storage Division

8 years agoAdd missing SVN keywords.
Bryan Drewery [Fri, 25 Sep 2015 19:25:19 +0000 (19:25 +0000)]
Add missing SVN keywords.

Sponsored by: EMC / Isilon Storage Division

8 years agoConstify ctl_serialize_table.
Alexander Motin [Fri, 25 Sep 2015 18:49:25 +0000 (18:49 +0000)]
Constify ctl_serialize_table.

8 years agosbuf: Process more than one char at a time
Conrad Meyer [Fri, 25 Sep 2015 18:37:14 +0000 (18:37 +0000)]
sbuf: Process more than one char at a time

Revamp sbuf_put_byte() to sbuf_put_bytes() in the obvious fashion and
fixup callers.

Add a thin shim around sbuf_put_bytes() with the old ABI to avoid ugly
changes to some callers.

Reviewed by: jhb, markj
Obtained from: Dan Sledz
Sponsored by: EMC / Isilon Storage Division
Differential Revision: https://reviews.freebsd.org/D3717

8 years agoRemove some dead code found by Clang analyzer.
Alexander Motin [Fri, 25 Sep 2015 18:15:34 +0000 (18:15 +0000)]
Remove some dead code found by Clang analyzer.

8 years agoRemove stale comments and some excessive empty lines.
Alexander Motin [Fri, 25 Sep 2015 16:34:59 +0000 (16:34 +0000)]
Remove stale comments and some excessive empty lines.

8 years agoThe bsd.progs.mk -> bsd.prog.mk rework did not pan out yet.
Bryan Drewery [Fri, 25 Sep 2015 16:27:11 +0000 (16:27 +0000)]
The bsd.progs.mk -> bsd.prog.mk rework did not pan out yet.

It may still in the future but for now unmark this deprecated.  bsd.progs.mk
is less bad after r288158.

8 years agoPROGS: Let the parent run the children in parallel.
Bryan Drewery [Fri, 25 Sep 2015 15:57:00 +0000 (15:57 +0000)]
PROGS: Let the parent run the children in parallel.

This seems to work fine.

MFC after: 3 weeks
Sponsored by: EMC / Isilon Storage Division

8 years agoFix non-POSIX-compliant use of getaddrinfo in libfetch
Michael Gmelin [Fri, 25 Sep 2015 14:24:23 +0000 (14:24 +0000)]
Fix non-POSIX-compliant use of getaddrinfo in libfetch

Submitted by: Boris Kolpackov <boris@codesynthesis.com>
Reviewed by: bapt
Approved by: bapt
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D3724

8 years agoUse per-cpu values for base and last in tc_cpu_ticks(). The values
Konstantin Belousov [Fri, 25 Sep 2015 13:03:57 +0000 (13:03 +0000)]
Use per-cpu values for base and last in tc_cpu_ticks().  The values
are updated lockess, different CPUs write its own view of timecounter
state.  The critical section is done for safety, callers of
tc_cpu_ticks() are supposed to already enter critical section, or to
own a spinlock.

The change fixes sporadical reports of too high values reported for
the (W)CPU on platforms that do not provide cpu ticker and use
tc_cpu_ticks(), in particular, arm*.

Diagnosed and reviewed by: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

8 years agoSwitch I/O time accounting from system time to uptime.
Alexander Motin [Fri, 25 Sep 2015 10:14:39 +0000 (10:14 +0000)]
Switch I/O time accounting from system time to uptime.

While there, make num_dmas accounted independently of CTL_TIME_IO.

8 years agoCollect DMA statistics on secondary HA node.
Alexander Motin [Fri, 25 Sep 2015 09:55:51 +0000 (09:55 +0000)]
Collect DMA statistics on secondary HA node.

8 years agoMake HA handle datamove and done in a universal way, using port methods.
Alexander Motin [Fri, 25 Sep 2015 09:14:29 +0000 (09:14 +0000)]
Make HA handle datamove and done in a universal way, using port methods.

Now from primary node point of view requests transferred from secondary
node should look almost normal and always have valid port.