dragonfly.git
3 years agokernel/acpi: Improve the disabling of Debug object output.
Sascha Wildner [Tue, 20 May 2014 19:55:52 +0000 (21:55 +0200)]
kernel/acpi: Improve the disabling of Debug object output.

It is actually a global in ACPICA (since 20100304) so add a new
sysctl debug.acpi.enable_debug_objects that can be used to toggle
it, with the default being 0.

Unlike the previous attempt (which I had to revert again), this
time also clear ACPI_LV_DEBUG_OBJECT in the AcpiDbgLevel global in
case ACPI_DEBUG is not defined. My assumption that ACPICA would
initialize AcpiDbgLevel to 0 was wrong. It really is initialized
to ACPI_NORMAL_DEFAULT. It is kind of weird that
ACPI_NORMAL_DEFAULT == ACPI_DEBUG_DEFAULT in acoutput.h, but FWIW,
leave the other bits in AcpiDbgLevel set for now.

This commit reverts (again) a previous commit by sephe which solved
it differently (in the ACPICA code).

Taken-from:    FreeBSD (with modification by me)
Dragonfly-bug: <http://bugs.dragonflybsd.org/issues/2672>

3 years agoacpica: Use only one #ifdef _KERNEL ... and use 'inline' directly.
Sascha Wildner [Tue, 20 May 2014 17:57:49 +0000 (19:57 +0200)]
acpica: Use only one #ifdef _KERNEL ... and use 'inline' directly.

3 years agokernel/acpi: Fix memory and port I/O functions in the OS services layer.
Sascha Wildner [Tue, 20 May 2014 04:17:05 +0000 (06:17 +0200)]
kernel/acpi: Fix memory and port I/O functions in the OS services layer.

This makes AcpiOsReadPort(), AcpiOsWritePort(), AcpiOsReadMemory()
and AcpiOsWriteMemory() match the behavior requested in the "ACPI
User Guide and Programmer Reference".

When the width of the location that is read from or written to is less
than the (return) value's width, the read functions must ensure the
rest of the bits are zero and the write functions must write no more
than the location's width.

This should fix at least a number of temperature reading issues we
were seeing, such as the messages we were getting lately:

acpi_tz0: _TMP value is absurd, ignored (-204.0C)
acpi_tz0: _TMP value is absurd, ignored (-204.0C)
acpi_tz0: _TMP value is absurd, ignored (-203.0C)

Found-in: FreeBSD

3 years agokernel/acpi: Remove an Itanium define.
Sascha Wildner [Tue, 20 May 2014 01:47:22 +0000 (03:47 +0200)]
kernel/acpi: Remove an Itanium define.

3 years agoin_pcbladdr: Break long line; no functional changes
Sepherosa Ziehau [Mon, 19 May 2014 12:46:01 +0000 (20:46 +0800)]
in_pcbladdr: Break long line; no functional changes

3 years agoinet: Return NULL from IN_LOOKUP_MULTI if ifnet is NULL
Sepherosa Ziehau [Mon, 19 May 2014 11:45:31 +0000 (19:45 +0800)]
inet: Return NULL from IN_LOOKUP_MULTI if ifnet is NULL

This could happen for mbufs on ip_input path, whose rcvif could be NULL.

3 years agoip_input: Only multicast forwarding may be not MPSAFE
Sepherosa Ziehau [Mon, 19 May 2014 11:37:16 +0000 (19:37 +0800)]
ip_input: Only multicast forwarding may be not MPSAFE

3 years agoip_output: if_simloop is MPSAFE
Sepherosa Ziehau [Mon, 19 May 2014 11:37:01 +0000 (19:37 +0800)]
ip_output: if_simloop is MPSAFE

3 years agokernel: Fix kernel build when _KPOSIX_PRIORITY_SCHEDULING is not set.
Sascha Wildner [Mon, 19 May 2014 00:49:25 +0000 (02:49 +0200)]
kernel: Fix kernel build when _KPOSIX_PRIORITY_SCHEDULING is not set.

Define p31b_proc() and p31b_proc_done() only when it is set.

3 years agoacpi: s/ACPI[ -]CA/ACPICA/ in a few places.
Sascha Wildner [Sun, 18 May 2014 22:24:12 +0000 (00:24 +0200)]
acpi: s/ACPI[ -]CA/ACPICA/ in a few places.

3 years agoAdjust some LDADD/DPADD.
Sascha Wildner [Sun, 18 May 2014 20:50:21 +0000 (22:50 +0200)]
Adjust some LDADD/DPADD.

3 years agokernel/acpi: Use AE_OK.
Sascha Wildner [Sun, 18 May 2014 13:31:48 +0000 (15:31 +0200)]
kernel/acpi: Use AE_OK.

3 years agoix.4: Fix description of TSO and multiple tranmission queue arbitration.
Sepherosa Ziehau [Sun, 18 May 2014 08:36:15 +0000 (16:36 +0800)]
ix.4: Fix description of TSO and multiple tranmission queue arbitration.

3 years agonetisr: Don't free mbuf, if hash function has already done it.
Sepherosa Ziehau [Sun, 18 May 2014 08:32:17 +0000 (16:32 +0800)]
netisr: Don't free mbuf, if hash function has already done it.

3 years agotest/mcast: Install to /usr/local/bin
Sepherosa Ziehau [Sun, 18 May 2014 08:30:25 +0000 (16:30 +0800)]
test/mcast: Install to /usr/local/bin

And join multicast group on the interface specified.

3 years agoifnet: Properly protect if_multiaddrs using ifnet serializers
Sepherosa Ziehau [Tue, 13 May 2014 13:59:18 +0000 (21:59 +0800)]
ifnet: Properly protect if_multiaddrs using ifnet serializers

- Protect ifnet.if_multiaddrs using ifnet serializers.  Add some
  comment in the places, where only main serailizer is necessary.
- Fix if_delallmulti().  Using TAILQ_FOREACH_MUTABLE is incorrect for
  deleting an ifmultiaddr from ifnet.if_multiaddrs.  Since deleting one
  ifmultiaddr may cause additional ifmultiaddr deletion (e.g. the AF_LINK
  ifmultiaddr for AF_INET ifmultiaddr).
- Change IN_LOOKUP_MULTI and IN6_LOOKUP_MULTI macros into inline
  functions.
- Redispatch multicast IP packets to netisr0 for further processing.
  Software based IP packet hash function is changed.  And hash value
  fixup for multicast IP packets is added to the beginning of ip_input();
  this is mainly for IP packets, whose hash is calculated by hardware.
- For wlan's multicast hardware filter updating, we no longer need to
  release wlan serializer and mess up w/ the if_ioctl setting.

In netisr0, read and test ifma_refcount for AF_INET ifmultiaddr is MPSAFE
w/o ifnet serializers, since its ifma_refcount is only altered in netisr0.

In netisr0, any operation on in_multi, which is obtained from the
corresponding ifmuliaddr's ifma_protospec, is MPSAFE w/o ifnet
serializers, since ifmultiaddr for AF_INET is only set and cleared in
netisr0.

While I'm here also redispatch IP packets w/o hash to the proper netisrs,
on ip_input() path.  And unnecessary critical sections in
in_{add,del}multi() are removed.

3 years agokernel/acpi: Include <sys/ktr.h> from acpi_ec.c instead of from acpivar.h.
Sascha Wildner [Sun, 18 May 2014 00:59:30 +0000 (02:59 +0200)]
kernel/acpi: Include <sys/ktr.h> from acpi_ec.c instead of from acpivar.h.

3 years agokernel/acpi: Use ACPI_COMPARE_NAME().
Sascha Wildner [Sun, 18 May 2014 00:01:06 +0000 (02:01 +0200)]
kernel/acpi: Use ACPI_COMPARE_NAME().

3 years agokernel/acpi: Add missing header to the Makefile.
Sascha Wildner [Sun, 18 May 2014 00:00:47 +0000 (02:00 +0200)]
kernel/acpi: Add missing header to the Makefile.

3 years agokernel/acpi: Remove unneeded kprintf when overriding DSDT.
Sascha Wildner [Sat, 17 May 2014 23:15:52 +0000 (01:15 +0200)]
kernel/acpi: Remove unneeded kprintf when overriding DSDT.

ACPI will print a notice ("Logical table override...") itself.

3 years agoacpi.4: Remove COMPATIBILITY altogether.
Sascha Wildner [Sat, 17 May 2014 23:14:02 +0000 (01:14 +0200)]
acpi.4: Remove COMPATIBILITY altogether.

It can be brought back once we support more platforms.

3 years agoacpi.4: Refresh COMPATIBILITY and update the spec reference.
Sascha Wildner [Sat, 17 May 2014 23:05:35 +0000 (01:05 +0200)]
acpi.4: Refresh COMPATIBILITY and update the spec reference.

3 years agoloader.conf: Fix ACPI DSDT overriding.
Sascha Wildner [Sat, 17 May 2014 22:58:47 +0000 (00:58 +0200)]
loader.conf: Fix ACPI DSDT overriding.

Also, fix the instructions in the acpi(4) manual page.

3 years agotest: my first commit
Imre Vadasz [Sat, 17 May 2014 17:58:44 +0000 (19:58 +0200)]
test: my first commit

3 years agokernel/netgraph7: Remove KMODDEPS.
Sascha Wildner [Sat, 17 May 2014 09:45:22 +0000 (11:45 +0200)]
kernel/netgraph7: Remove KMODDEPS.

3 years agokernel/netgraph7: Fix Makefile.
Sascha Wildner [Sat, 17 May 2014 09:42:42 +0000 (11:42 +0200)]
kernel/netgraph7: Fix Makefile.

3 years agokernel/ral: Clean up a mis-delete I did.
Sascha Wildner [Fri, 16 May 2014 09:21:54 +0000 (11:21 +0200)]
kernel/ral: Clean up a mis-delete I did.

3 years agokernel/acpi: ACPI_INTEGER is obsolete since 20100121 (replaced with UINT64).
Sascha Wildner [Fri, 16 May 2014 09:09:52 +0000 (11:09 +0200)]
kernel/acpi: ACPI_INTEGER is obsolete since 20100121 (replaced with UINT64).

3 years agokernel/ral: Bring in support for further chips (RT2700/2800/3090 series).
Sascha Wildner [Thu, 15 May 2014 09:42:35 +0000 (11:42 +0200)]
kernel/ral: Bring in support for further chips (RT2700/2800/3090 series).

Unfortunately I don't have any hardware to test and no one volunteered
when I asked on the lists. Pushing anyway because it shouldn't break
RT2500/2501/2600 support. We'll see if someone reports issues with
it.

3 years agoUpdate the pciconf(8) database.
Sascha Wildner [Thu, 15 May 2014 09:20:06 +0000 (11:20 +0200)]
Update the pciconf(8) database.

May 13, 2014 snapshot from http://pciids.sourceforge.net/

3 years agokernel/acpi: i386 build fixes.
Sascha Wildner [Thu, 15 May 2014 09:06:07 +0000 (11:06 +0200)]
kernel/acpi: i386 build fixes.

3 years agokernel/acpi: Remove a debug printf I accidentally pushed.
Sascha Wildner [Thu, 15 May 2014 06:59:13 +0000 (08:59 +0200)]
kernel/acpi: Remove a debug printf I accidentally pushed.

3 years agolibmagic(3): Some MLINKS adjustments for the most recent upgrade.
Sascha Wildner [Thu, 15 May 2014 06:55:43 +0000 (08:55 +0200)]
libmagic(3): Some MLINKS adjustments for the most recent upgrade.

3 years agounits(1): Sync with FreeBSD
Eitan Adler [Thu, 15 May 2014 05:31:38 +0000 (22:31 -0700)]
units(1): Sync with FreeBSD
- fix -f and -V option
- fix a few typos
- call el_end()
- use builtin functions where appropriate

3 years agokernel/acpi: Add quirks framework (and some quirks) from FreeBSD.
Sascha Wildner [Wed, 14 May 2014 22:08:49 +0000 (00:08 +0200)]
kernel/acpi: Add quirks framework (and some quirks) from FreeBSD.

I don't know how common the signatures from the supplied quirks
are nowadays (the last addition was in 2005) but the framework
could nevertheless be useful.

For now, the ACPI_Q_MADT_IRQ0 quirk remains unimplemented because
of the way the associated code is implemented in DragonFly. This
will need further work in the future.

In-discussion-with: sephe

3 years agoktrdump(8): Remove some stuff that was not meant to be pushed.
Sascha Wildner [Wed, 14 May 2014 19:31:32 +0000 (21:31 +0200)]
ktrdump(8): Remove some stuff that was not meant to be pushed.

3 years agoktrdump(8): Add some needed newlines and remove some unneeded ones.
Sascha Wildner [Wed, 14 May 2014 17:08:06 +0000 (19:08 +0200)]
ktrdump(8): Add some needed newlines and remove some unneeded ones.

err*() will add one automatically, and some printfs were missing one.

Also, fix a small table formatting issue.

3 years agoSync zoneinfo database with tzdata2014c from ftp://ftp.iana.org/tz/releases
Sascha Wildner [Wed, 14 May 2014 07:03:31 +0000 (09:03 +0200)]
Sync zoneinfo database with tzdata2014c from ftp://ftp.iana.org/tz/releases

* africa: Egypt observes DST starting 2014-05-15 at 24:00.
    (Thanks to Ahmad El-Dardiry and Gunther Vermier.)

* asia: Remove now-confusing comment about Jordan.
    (Thanks to Oleksii Nochovnyi.)

* europe: Add a clarifying comment about how clocks in Simferopol
    Sevastopol were actually changed.

3 years agokernel/acpi: Print any errors returned by CPU capability setting using _OSC.
Sascha Wildner [Tue, 13 May 2014 04:11:33 +0000 (06:11 +0200)]
kernel/acpi: Print any errors returned by CPU capability setting using _OSC.

3 years agomcast: ifma_protospec is pointer; use NULL for it.
Sepherosa Ziehau [Mon, 12 May 2014 13:22:40 +0000 (21:22 +0800)]
mcast: ifma_protospec is pointer; use NULL for it.

3 years agoRevert "kernel/acpi: Improve the disabling of Debug object dumping."
Sascha Wildner [Mon, 12 May 2014 05:01:42 +0000 (07:01 +0200)]
Revert "kernel/acpi: Improve the disabling of Debug object dumping."

This reverts commit c9ed7d9ef60d6ffb82c02ec4822a68a29703a389.

Revert it until I've figured it out.

Reported-by: davshao
3 years agokernel/acpi: Improve the disabling of Debug object dumping.
Sascha Wildner [Sun, 11 May 2014 19:16:54 +0000 (21:16 +0200)]
kernel/acpi: Improve the disabling of Debug object dumping.

It is actually a global in ACPICA (since 20100304) so add a new
sysctl debug.acpi.enable_debug_objects that can be used to toggle
it, with the default being 0.

This commit reverts e59c6bdadc7ee647f2ac508a3d1c210b89a680b1 which
solved it differently (in the ACPICA code).

Taken-from:  FreeBSD
Reported-by: dillon (iirc)
3 years agokernel/acpi: Remove an unused define.
Sascha Wildner [Sun, 11 May 2014 17:25:55 +0000 (19:25 +0200)]
kernel/acpi: Remove an unused define.

3 years agokernel/acpi: Add some ktr events to the acpi_ec code.
Sascha Wildner [Sun, 11 May 2014 14:56:13 +0000 (16:56 +0200)]
kernel/acpi: Add some ktr events to the acpi_ec code.

Translates what FreeBSD has to our ktr(9) syntax.

Also, reduce differences with FreeBSD in some other places
but it is just cosmetical.

3 years agoix.4: Update according to the overhaul of ix(4)
Sepherosa Ziehau [Sun, 11 May 2014 13:18:54 +0000 (21:18 +0800)]
ix.4: Update according to the overhaul of ix(4)

3 years agoloader: Remove some commented out code to load modules based on PNP IDs.
Sascha Wildner [Sun, 11 May 2014 12:43:56 +0000 (14:43 +0200)]
loader: Remove some commented out code to load modules based on PNP IDs.

3 years agox86_64/ioapic: Enable GSI target CPU auto-balance by default
Sepherosa Ziehau [Sun, 11 May 2014 11:22:02 +0000 (19:22 +0800)]
x86_64/ioapic: Enable GSI target CPU auto-balance by default

The original bug, which prevented GSI target CPU auto-balance, probably
was fixed by 902419bf6d9fd0f80afc9d07cd4b3e99d20f23ca.

3 years agopolling.4: Add ix(4)
Sepherosa Ziehau [Sun, 11 May 2014 07:26:56 +0000 (15:26 +0800)]
polling.4: Add ix(4)

3 years agoinet: in_{add,del}multi should only be called in netisr0
Sepherosa Ziehau [Sun, 11 May 2014 07:14:29 +0000 (15:14 +0800)]
inet: in_{add,del}multi should only be called in netisr0

Add KASSERT to make sure about it.

While I'm here, add blank line before in_addmulti()

3 years agoinet: Dispatch in_ifdetach to netisr0 to run
Sepherosa Ziehau [Sun, 11 May 2014 06:57:06 +0000 (14:57 +0800)]
inet: Dispatch in_ifdetach to netisr0 to run

Currently:
- It only goes through two inpcb lists.  Accessing to these two lists
  is lockless MPSAFE only if the accessing is in netisr0.
- It only modifies inpcbs' multicast option, which should be modified
  in netisr0.

3 years agopfsync: Dispatch in_{add,del}multi to netisr0
Sepherosa Ziehau [Sat, 10 May 2014 13:48:44 +0000 (21:48 +0800)]
pfsync: Dispatch in_{add,del}multi to netisr0

Netisr0 is where multicast is handled.

3 years agokernel/acpi: Use ACPI_SUCCESS()/ACPI_FAILURE() in a few places.
Sascha Wildner [Sat, 10 May 2014 23:30:05 +0000 (01:30 +0200)]
kernel/acpi: Use ACPI_SUCCESS()/ACPI_FAILURE() in a few places.

3 years agokernel/acpi: Move the declaration of _debug_acpi to acpivar.h.
Sascha Wildner [Sat, 10 May 2014 23:11:37 +0000 (01:11 +0200)]
kernel/acpi: Move the declaration of _debug_acpi to acpivar.h.

3 years agokernel - Fix racing assertion
Matthew Dillon [Fri, 9 May 2014 17:24:56 +0000 (10:24 -0700)]
kernel - Fix racing assertion

* Two semaphore assertions could panic the box because they were testing
  conditions subject to SMP races.

* Move the assertions past the lock so they are no longer subject to SMP
  races.

Reported-by: marino
3 years agoigmp: Dispatch fast and slow timeout handler to netisr0
Sepherosa Ziehau [Thu, 8 May 2014 13:02:36 +0000 (21:02 +0800)]
igmp: Dispatch fast and slow timeout handler to netisr0

Netisr0 is where IGMP is to be handled.

3 years agotcp: Multicast sockopts do not make sense on TCP sockets
Sepherosa Ziehau [Wed, 7 May 2014 14:33:40 +0000 (22:33 +0800)]
tcp: Multicast sockopts do not make sense on TCP sockets

3 years agokernel: Remove two oldusb wlan drivers, rum and ural.
Sascha Wildner [Wed, 7 May 2014 13:01:43 +0000 (15:01 +0200)]
kernel: Remove two oldusb wlan drivers, rum and ural.

Both don't work even with oldusb because they have never been
ported to the current ieee80211 framework. In fact, they were
unhooked from the build at the time.

Both also exist for usb4bsd. rum(4) was ported to DragonFly
while ural(4) has yet to be ported.

3 years agoUpdate files for file-5.18 import.
Peter Avalos [Tue, 6 May 2014 17:52:16 +0000 (10:52 -0700)]
Update files for file-5.18 import.

3 years agoMerge branch 'vendor/FILE'
Peter Avalos [Tue, 6 May 2014 22:37:33 +0000 (15:37 -0700)]
Merge branch 'vendor/FILE'

3 years agokernel: Fix some boolean_t vs. int confusion.
Sascha Wildner [Tue, 6 May 2014 19:52:29 +0000 (21:52 +0200)]
kernel: Fix some boolean_t vs. int confusion.

When boolean_t is defined to be _Bool instead of int (not part of this
commit), this is what gcc is sad about.

3 years agoImport file-5.18.
Peter Avalos [Tue, 6 May 2014 17:40:32 +0000 (10:40 -0700)]
Import file-5.18.

See ChangeLog for details.

3 years agonrelease: Copying pkg.conf.sample to pkg.conf is no longer needed.
Sascha Wildner [Tue, 6 May 2014 09:20:11 +0000 (11:20 +0200)]
nrelease: Copying pkg.conf.sample to pkg.conf is no longer needed.

3 years agohammer2 - dmsg stabilization
Matthew Dillon [Mon, 5 May 2014 06:52:24 +0000 (23:52 -0700)]
hammer2 - dmsg stabilization

This is a general stabilization pass testing xdisk resumption on various
communications failures (killing the local or remote hammer2 service demon).

* Simulate failures on recursive transactions in a bottom-up fashion

* bcmp() does not return an inequality (neg, zero, or positive).  It
  returns only 0 or 1.  Change fs_label RBTREE test to strcmp()

* ref-count the state structure, use dmsg_state_hold()/dmsg_state_drop()
  to control it.  Fix at least one memory leak.

* Consolidate simulated transaction failure core into a helper
  function dmsg_msg_simulate_failure().

* Clean up the tx state on the front-end after the msg has extracted
  necessary information from it, instead of in the transmit thread.
  This is so the state fields are updated synchronously and not delayed
  by the transmit queue.

* Change xdisk's error test to avoid accidently failing a BIO due to
  a communications issue (verses an actual IO error on the remote physical
  disk).

* Remove some invalid assertions, add assertions.

3 years agohammer2 - Retool dmsg mechanics to improve virtual circuit design 2/2
Matthew Dillon [Mon, 5 May 2014 02:52:05 +0000 (19:52 -0700)]
hammer2 - Retool dmsg mechanics to improve virtual circuit design 2/2

* Use transaction stacking to effectively connect resources to consumers.
  Issuing a transaction over a received SPAN effectively creates a virtual
  circuit to the originator.

* The hammer2 service demon (userland) is currently being used to route,
  but direct kernel<->kernel socket connections are now theoretically
  possible for later performance work.  Current performance is going
  to be low due to layering.

* Get subr_diskiocom and the xdisk driver mostly working again.  The
  code is a lot cleaner but still needs considerable stability work and
  better unwinding during failure conditions.

* Start work on hammer2<->hammer2 communications.

3 years ago<setjmp.h>: Make _setjmp() and _longjmp() visible for SUSv2 too.
Sascha Wildner [Sun, 4 May 2014 14:01:36 +0000 (16:01 +0200)]
<setjmp.h>: Make _setjmp() and _longjmp() visible for SUSv2 too.

They were around even earlier (CAE XPG4v2, actually) but to support that
we would need _XOPEN_SOURCE_EXTENSIONS support which we currently lack.

3 years agoix.4: Mention polling(4) support.
Sascha Wildner [Sun, 4 May 2014 12:11:00 +0000 (14:11 +0200)]
ix.4: Mention polling(4) support.

3 years agoix: Add polling(4) support
Sepherosa Ziehau [Wed, 30 Apr 2014 12:23:51 +0000 (20:23 +0800)]
ix: Add polling(4) support

3 years ago wlan/atheros - Remove debugging
Matthew Dillon [Sat, 3 May 2014 22:54:54 +0000 (15:54 -0700)]
 wlan/atheros - Remove debugging

* Remove left-over debug kprintf.

3 years agowlan/atheros - Synchronize sleep state code from FreeBSD
Matthew Dillon [Sat, 3 May 2014 21:25:53 +0000 (14:25 -0700)]
wlan/atheros - Synchronize sleep state code from FreeBSD

* Synchronize Adrian Chadd's sleep state code and wlan updates.

* With this commit if the wlan or ath interface is in a 'down' state,
  it will use full sleep mode and save power.

* We get all of ATH through today but the 802_11 changes are a bit
  too substantial so this commit only brings in the sleep state code
  through today (3-May-2014).

* There is a bunch of other 802_11 work that needs to be brought in
  but it's like 20,000 lines of patches so... not today.

* Verified operational on Acer C720 chromebook.  full-sleep mode saves
  0.3-0.4W.  Network sleep mode code is also verified to be operational
  but does not appear to save any power at the moment.

  Also verified: beacons are working properly for wakeups on packet
  reception.

3 years ago<setjmp.h>: Fix up visibility checks a bit (avoid checking _ANSI_SOURCE).
Sascha Wildner [Sat, 3 May 2014 21:26:32 +0000 (23:26 +0200)]
<setjmp.h>: Fix up visibility checks a bit (avoid checking _ANSI_SOURCE).

3 years agokernel/bwn: Fix a typo. This fixes RF switch state polling.
Imre Vadasz [Sat, 3 May 2014 18:53:26 +0000 (20:53 +0200)]
kernel/bwn: Fix a typo. This fixes RF switch state polling.

Fixes the RF switch state polling by comparing with the revision of the
PHY instead of the revision of the RADIO.

3 years agoMerge branch 'vendor/LIBPCAP'
Matthew Dillon [Sat, 3 May 2014 15:50:32 +0000 (08:50 -0700)]
Merge branch 'vendor/LIBPCAP'

Merge for 1.4.0

3 years agoImport libpcap-1.4.0. vendor/LIBPCAP
Matthew Dillon [Sat, 3 May 2014 15:46:52 +0000 (08:46 -0700)]
Import libpcap-1.4.0.

See CHANGES for the details.

3 years agodrm/i915: Use the Linux workqueue API
François Tigeot [Sat, 3 May 2014 09:12:14 +0000 (11:12 +0200)]
drm/i915: Use the Linux workqueue API

Opportunistically reduce differences with Linux 3.8.13

3 years agolinux/workqueue.h: Adapt to DragonFly
François Tigeot [Sat, 3 May 2014 08:55:10 +0000 (10:55 +0200)]
linux/workqueue.h: Adapt to DragonFly

* Protect callout structures from concurrent operations on MP machines

* Add some functions used by the drm/i915 code from Linux 3.8.x

3 years agolinux/timer.h: Add round_jiffies_up_relative()
François Tigeot [Sat, 3 May 2014 08:53:41 +0000 (10:53 +0200)]
linux/timer.h: Add round_jiffies_up_relative()

3 years agodrm: Import linux/workqueue.h from FreeBSD's OFED stack
François Tigeot [Sat, 3 May 2014 08:52:02 +0000 (10:52 +0200)]
drm: Import linux/workqueue.h from FreeBSD's OFED stack

3 years ago<setjmp.h>: <sys/cdefs.h> must be included before <machine/setjmp.h>.
Sascha Wildner [Sat, 3 May 2014 00:25:52 +0000 (02:25 +0200)]
<setjmp.h>: <sys/cdefs.h> must be included before <machine/setjmp.h>.

3 years agoRemove some more files via 'make upgrade' and fix a typo.
Sascha Wildner [Fri, 2 May 2014 08:14:24 +0000 (10:14 +0200)]
Remove some more files via 'make upgrade' and fix a typo.

3 years agopcidevs: Remove some IDs we don't use.
Sascha Wildner [Fri, 2 May 2014 00:22:22 +0000 (02:22 +0200)]
pcidevs: Remove some IDs we don't use.

3 years agokernel/ral: Switch back to using pcidevs.h.
Sascha Wildner [Fri, 2 May 2014 00:21:58 +0000 (02:21 +0200)]
kernel/ral: Switch back to using pcidevs.h.

It was lost with feb94d24033db5d8fe8e5e4807103d48f3638ceb.

3 years agoRemove ATM protocol support.
Sascha Wildner [Thu, 1 May 2014 22:31:57 +0000 (00:31 +0200)]
Remove ATM protocol support.

FreeBSD ditched it about 6 years ago. Also, I'm not sure if this ever
worked on x86_64.

3 years agokernel: Sync ACPICA with Intel's version 20140424.
Sascha Wildner [Wed, 30 Apr 2014 10:25:14 +0000 (12:25 +0200)]
kernel: Sync ACPICA with Intel's version 20140424.

Some highlights:

* Implemented support to skip/ignore NULL address entries in the
  RSDT/XSDT.

* Removed an extraneous error message for the case where there
  are a large number of system GPEs (> 124).

* Implemented and deployed additional configuration support for
  the public ACPICA external interfaces.

* iASL and disassembler: Add full support for the LPIT table
  (Low Power Idle Table).

* AcpiDump utility:
  1) Add option to force the use of the RSDT (over the XSDT).
  2) Improve validation of the RSDP signature (use 8 chars
     instead of 4).

* Debugger: Updated the GPE command (which simulates a GPE by
  executing the GPE code paths in ACPICA).

* Unix application OSL: Update line-editing support.

For a more detailed list, see sys/contrib/dev/acpica/changes.txt.

3 years agoAdd the <stdnoreturn.h> header for C11 conformance.
Sascha Wildner [Wed, 30 Apr 2014 09:39:03 +0000 (11:39 +0200)]
Add the <stdnoreturn.h> header for C11 conformance.

Per clause 7.23 from the final draft.

Taken-from: FreeBSD

3 years agoAdd the <stdalign.h> header for C11 conformance.
Sascha Wildner [Mon, 21 Apr 2014 14:08:47 +0000 (16:08 +0200)]
Add the <stdalign.h> header for C11 conformance.

Per clause 7.15 from the final draft.

Along with it, add some helper macros to <sys/cdefs.h>.

While here, adjust an #ifdef in <sys/cdefs.h>.

Taken-from: FreeBSD

3 years ago<assert.h>: Define a static_assert macro for C11.
Sascha Wildner [Mon, 21 Apr 2014 12:27:35 +0000 (14:27 +0200)]
<assert.h>: Define a static_assert macro for C11.

Per clause 7.2 from the final draft:

"The header <assert.h> defines the assert and static_assert macros [...]
 The macro static_assert expands to _Static_assert."

3 years agoOpenSSL: Check the correct pointer in EC_POINT_invert.
Sascha Wildner [Wed, 30 Apr 2014 09:33:31 +0000 (11:33 +0200)]
OpenSSL: Check the correct pointer in EC_POINT_invert.

It looks like this was copied from EC_POINT_dbl() but the check was
overlooked when adjusting.

Reported-by: plundra on #dragonflybsd
Taken-from:  OpenBSD

3 years agoOpenSSL: Add fix for CVE-2010-5298.
Sascha Wildner [Wed, 30 Apr 2014 08:58:52 +0000 (10:58 +0200)]
OpenSSL: Add fix for CVE-2010-5298.

3 years agoMerge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Markus Pfeiffer [Tue, 29 Apr 2014 22:47:05 +0000 (23:47 +0100)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly

3 years agousr.bin/top: Correct formatting for PIDs
Markus Pfeiffer [Tue, 29 Apr 2014 22:44:53 +0000 (23:44 +0100)]
usr.bin/top: Correct formatting for PIDs

DragonFly PIDs can now be up to 6 digits long

3 years agokernel/acpi: Add the ACPI_LV_REPAIR debug level (added in ACPICA 20091214).
Sascha Wildner [Tue, 29 Apr 2014 20:48:43 +0000 (22:48 +0200)]
kernel/acpi: Add the ACPI_LV_REPAIR debug level (added in ACPICA 20091214).

Also sync the list of debug levels in the manual page.

3 years agobin/ps: adjust PIDLEN
Markus Pfeiffer [Tue, 29 Apr 2014 19:49:40 +0000 (20:49 +0100)]
bin/ps: adjust PIDLEN

DragonFly's pids can now become 6 digits long

3 years agobsd-family-tree: Sync with FreeBSD.
Sascha Wildner [Mon, 28 Apr 2014 17:05:57 +0000 (19:05 +0200)]
bsd-family-tree: Sync with FreeBSD.

3 years agopflogd: Make pflog readable by tcpdump
Peeter [Mon, 28 Apr 2014 08:12:00 +0000 (10:12 +0200)]
pflogd: Make pflog readable by tcpdump

pflogd was previously writing incorrectly to the pflog logfile

Changes obtained from FreeBSD

3 years agodrm/i915: Reduce i915_irq.c diffs with Linux 3.8.13
François Tigeot [Sun, 27 Apr 2014 09:26:47 +0000 (11:26 +0200)]
drm/i915: Reduce i915_irq.c diffs with Linux 3.8.13

* i915_handle_rps_change() renamed to ironlake_handle_rps_change()

* pch_irq_handler() replaced by ibx_irq_handler() and cpt_irq_handler()

* Make ironlake_irq_handler() more similar to its Linux 3.8.13 version

* Make ivybridge_irq_handler() more similar to its Linux 3.8.13 version

3 years agokernel/vtnet: Zeroing memory before reusing.
Imre Vadasz [Sat, 26 Apr 2014 10:01:13 +0000 (12:01 +0200)]
kernel/vtnet: Zeroing memory before reusing.

* Forgot a memset to clear sc->vtnet_macfilter before reusing.

* Forgot an __aligned(2) in another case where we need a local
  variable of size 2 to be stored in physically contiguous memory.

* Deletes an unneeded assertion and comment.

3 years agokernel/acpi: Improve a message a bit.
Sascha Wildner [Sat, 26 Apr 2014 10:21:27 +0000 (12:21 +0200)]
kernel/acpi: Improve a message a bit.

3 years agokernel/vtnet: Replace a kmalloc by contigmalloc.
Imre Vadasz [Sat, 26 Apr 2014 06:36:33 +0000 (08:36 +0200)]
kernel/vtnet: Replace a kmalloc by contigmalloc.

* To get physically contiguous memory, we have to use contigmalloc instead
  of kmalloc.

* Use a 2 byte alignment to make sure that a 2 byte local variable is
  stored in physically contiguous memory.

Dragonfly-bug: <http://bugs.dragonflybsd.org/issues/2666>

3 years agovtnet.4: Fix SYNOPSIS ("device if_vtnet" -> "device vtnet").
Sascha Wildner [Fri, 25 Apr 2014 13:45:44 +0000 (15:45 +0200)]
vtnet.4: Fix SYNOPSIS ("device if_vtnet" -> "device vtnet").

3 years agoAdjust newsyslog(8) and pkill(1) for the new PID_MAX.
Sascha Wildner [Wed, 23 Apr 2014 18:00:47 +0000 (20:00 +0200)]
Adjust newsyslog(8) and pkill(1) for the new PID_MAX.

Reported-by: marino