Commit Graph

143562 Commits

Author SHA1 Message Date
roy
4be2a728d1 netinet6: only flush prefixes and routers for the given interface.
Unless it's lo0, where we then flush the lot.
The maintains the status-quo with ndp(8) and allows dhcpcd(8) to at least
try and work with kernel RA on one interface and dhcpcd on another.
2018-12-16 08:54:58 +00:00
christos
29ca71246d - Use kmem_intr_{alloc,free}, because on time out we need to free from an
interrupt context.
- Remove parens from returns and useless casts from void.
2018-12-15 22:05:23 +00:00
alnsn
70a698f3bd Add missing include for device_t declaration. 2018-12-15 16:54:30 +00:00
maxv
506b4248b0 Invert the mapping logic.
Until now, the "owner" of the memory was the guest, and by calling
nvmm_gpa_map(), the virtualizer was creating a view towards the guest
memory.

Qemu expects the contrary: it wants the owner to be the virtualizer, and
nvmm_gpa_map should just create a view from the guest towards the
virtualizer's address space. Under this scheme, it is legal to have two
GPAs that point to the same HVA.

Introduce nvmm_hva_map() and nvmm_hva_unmap(), that map/unamp the HVA into
a dedicated UOBJ. Change nvmm_gpa_map() and nvmm_gpa_unmap() to just
perform an enter into the desired UOBJ.

With this change in place, all the mapping-related problems in Qemu+NVMM
are fixed.
2018-12-15 13:39:43 +00:00
jmcneill
d48bf86715 Add missing call to arm_fdt_cpu_mpstart, fixes SMP on Tegra X1 2018-12-15 13:17:12 +00:00
msaitoh
38ad04ccb5 Make IODATA WN-G150UMW work:
- Increase delay to prevent "could not send firmware command". The value
  is taken from FreeBSD.
-Increase delay to prevent "timeout waiting for firmware readiness". The
  vaule is taken from Linux.
2018-12-15 10:30:58 +00:00
rin
b4a1602346 Improve wording in comments: replace "chain" with "queue" for
sequence of mbuf's connected by m_nextpkt, in order to avoid
confusion with those connected by m_next.

No binary changes.
2018-12-15 07:38:58 +00:00
rin
94661a73af Replace panic with rate-limited LOG_ERR message when we encounter
invalid ether frame with non-zero csum flags.

Requested by thorpej.
2018-12-15 07:29:44 +00:00
msaitoh
04e3e20e59 Print and clear the wakeup status only when the WUS register != 0. 2018-12-15 05:40:10 +00:00
msaitoh
94d88f2c0b Clearing PCI_PMCSR_PME_STS(W1C) bit is required to stop asserting PME#.
This change would prevent unexpected rebooting from shutdown -p or
unexpected resuming from suspend.
2018-12-15 05:38:45 +00:00
macallan
87e783a939 Make this config resemble an Iyonix as they actually shipped:
- add more onboard and standard devices ( dsrtc, ehci, etc. )
- remove lots of unused and commented out drivers
- add some useful filesystems like procfs etc.
2018-12-14 23:01:53 +00:00
macallan
b6291719e5 add options DSRTC_YEAR_START_2K for machines which use 2000 and not 1970
as base to count years from, like Iyonix.
While there apply the offset when writing to the clock as well.
2018-12-14 22:05:36 +00:00
jakllsch
44af1da713 add cardbus malo(4) to x86 GENERIC and ALL kernels 2018-12-14 22:00:26 +00:00
jakllsch
93c9f12875 add cardbus attachment for malo(4), from OpenBSD 2018-12-14 21:49:22 +00:00
jakllsch
f7fb09d874 fix whitespace 2018-12-14 21:27:03 +00:00
jakllsch
0887ec2344 use callout_destroy in malo_detach, not callout_stop 2018-12-14 21:23:43 +00:00
jakllsch
8ccb436522 always use correct function to free our copy of the microcode 2018-12-14 20:44:36 +00:00
skrll
055a5e8063 Provide TEGRA210 supplies. 2018-12-14 18:17:36 +00:00
tnn
ee6e92d9fa regen 2018-12-14 14:04:13 +00:00
tnn
e3b79cc250 add D-Link LTE products 2018-12-14 13:56:59 +00:00
skrll
782d3d4738 Support SATA on TEGRA210
Thanks to jmcneill for help with this.
2018-12-14 12:29:22 +00:00
martin
cb38e6c4e3 Need <netinet6/ip6_var.h> for ip6_statinc() prototype. 2018-12-14 12:27:22 +00:00
msaitoh
01e3781fa8 - Fix availability detection of WoL on some chips. This change has no effect
other than dmesg because WM_F_WOL is currently not used to change the behavior:
  - For ICH/PCH, check the capability not from NVM but from the WUC register.
    Check the value before clearing the register.
  - 82580 and newer have per-port NVM block, so read the area correctly.
    Note that 82580, I350 and I354 may have PCI function 2 and 3.
  - Some devices can't detect WoL capability neither from NVM nor from WUC.
    Use PCI device ID and the function number.
- Print the WUS (WakeUp Status) register bits when resume.
2018-12-14 09:47:40 +00:00
nakayama
8bcff0c69b Remove comment about removed lmc*. 2018-12-14 09:21:32 +00:00
msaitoh
e4a61aa443 Print CLSEM workaround bit correctly. 2018-12-14 06:28:09 +00:00
rin
1995914906 Panic rather than silently dropping packets when TX offload options are
enabled for unsupported frame types.
2018-12-13 20:54:50 +00:00
rin
ae786153d6 Also take care of non-DIAGNOSTIC case. 2018-12-13 20:44:33 +00:00
jakllsch
83286ae20c Fix fwdma_free() for when bus_dmamap_unload() clobbers the dmamap.
Prevents KASSERTs on detaches of sbp(4) and fwohci(4) on amd64.

We should pass the dmamem segs around seperately, not in loaded dmamap...
2018-12-13 16:38:26 +00:00
maxv
34cf54c065 Don't forget to advance the RIP after an XSETBV emulation. 2018-12-13 16:28:10 +00:00
fox
3501b082eb regen 2018-12-13 16:23:34 +00:00
fox
836ce18f07 Add Logitech Gamepad F310 and Logitech Dual Action Gamepad 2018-12-13 16:20:20 +00:00
cherry
7eebc91ec1 Allow x86 builds to have the opportunity to not have pre-emption
enabled by default. This can be effected by having a:

"options	NO_PREEMPTION"

line in the kernel configuration file.

While it was tempting to tie __HAVE_PREEMPTION to MULTIPROCESSOR,
as is currently assumed in sys/kern/kern_stub.c ,

having MULTIPROCESSOR without __HAVE_PREEMPTION
and not having either are valid configuration options which users
could have choice of. We thus err on the side of configurability.
2018-12-13 16:16:51 +00:00
rin
9f1db18674 Fix (bridge && !inet6) build. 2018-12-13 12:13:33 +00:00
ryo
d2dfaf9c13 add support PT_STEP 2018-12-13 10:44:25 +00:00
roy
f609a819ed inet6: discard any received NA with a LL address we own
This matches ARP behaviour.
2018-12-13 10:27:51 +00:00
msaitoh
460c3d0c38 Fix a wrong access to I217_PROXY_CTRL which was added in inbmphreg.h rev. 1.13
and if_wm.c rev. 1.603.
2018-12-13 05:22:44 +00:00
jakllsch
2bd6662aa4 Calculate uchcom(4) dividers differently; usually the same, but sometimes better. 2018-12-13 01:40:02 +00:00
jakllsch
68d75cc760 Fix uchcom(4) line parameter settings.
Enables support for line modes other than 8-bit/no-parity/1-stop on
modern chips, and should also work on older chips.
2018-12-13 00:36:30 +00:00
is
867d63b145 Added support for AMD family 16h cpu sensors - (just like 10h-14h).
(Tested on netbsd-8.0 release.)
2018-12-12 23:35:04 +00:00
jakllsch
8db0f4b3be remove unneeded variables in uchcom_softc 2018-12-12 23:26:00 +00:00
jakllsch
360a788366 omit irrelevant #includes 2018-12-12 23:21:36 +00:00
ryo
909c712e78 need space 2018-12-12 18:11:00 +00:00
ryo
3bdeb3fa32 - need to save/restore interrupt mask when entering/exiting to/from cpu_switchto_softint().
- when call dosoftints from cpu_idle, interrupts should be disabled.

rarely, lwp stack had been exhausted when high interrupts.
reported by alnsn@. thanks.
2018-12-12 11:14:51 +00:00
skrll
ea54a09a90 Trailing whitespace 2018-12-12 09:55:34 +00:00
msaitoh
23901b54b6 Add some code for suspend/resume:
- Rename wm_smbustopci() to wm_init_phy_workarounds_pchlan(). It will also
  called when resume.
- Call wm_phy_resetisblocked() after PHY reset in
  wm_init_phy_workarounds_pchlan() to wait for the PHY to quiesce to an
  accessible state.
- Add new wm_resume_workarounds_pchlan() function and use it in wm_resume().
  This workaround is only for PCH2 and newer.
- Don't call wm_disable_aspm() neither in wm_attach() nor in wm_resume()
  but in wm_reset().
- Do some initialization in wm_resume() when IFF_UP is NOT set.
- Don't continue when it failed to acquire semaphore in wm_ulp_disable().
- Add comment.
2018-12-12 08:49:33 +00:00
maxv
7bc6869364 Retire the LMC driver, and its associated lmcconfig tool. LMC has been
mentioned repeatedly as a non-MP-safe driver that is hard to maintain,
and no one is taking care of it.

LMC was removed from OpenBSD three years ago, and from FreeBSD a few
months ago.
2018-12-12 07:04:05 +00:00
maxv
1a87c65fae Remove references to "lmc" in the kernel configurations. 2018-12-12 06:29:36 +00:00
rin
7f120f6563 Simplify logic in ip{,6}_output().
Now, we have M_CSUM_TSOv[46] bit in ifp->if_csum_flags_tx when
TSO[46] is enabled for the interface. So we can simply check
whether TSO[46] is required in a packet but missing in the
interface by (sw_csum & M_CSUM_TSOv[46]).

Note that this is a very rare case where TSO[46] is suddenly
turned off during a packet passing b/w TCP and IP.

part of PR kern/53562
OK msaitoh
2018-12-12 01:53:52 +00:00
rin
f7201ab71a Add TX/RX offload capabilities to shmif(4). They are emulated in
software by ether_sw_offload_[tr]x().

For rump kernels, if_capabilities for shmemif(4) can be specified
by environmental variable RUMP_SHMIF_CAPENABLE:

 setenv RUMP_SHMIF_CAPENABLE 0x7ff80 (all offload)
 setenv RUMP_SHMIF_CAPENABLE 0x6aa80 (all TX)
 setenv RUMP_SHMIF_CAPENABLE 0x15500 (all RX)

part of PR kern/53562
OK msaitoh
2018-12-12 01:51:32 +00:00
rin
73240bb1c3 PR kern/53562
Handle TX offload in software when a packet is sent via
bridge_output(). We can send it as is in the following
exceptional cases:

For unicast:

(1) When the destination interface is the same as source.

(2) When the destination supports all TX offload options
    specified in a packet.

For multicast/broadcast:

(3) When all the members of the bridge support the specified
    TX offload options.

For (3), add sc_csum_flags_tx flag to bridge softc, which is
logical AND b/w capabilities of TX offload options in member
interface (ifp->if_csum_flags_tx). The flag is updated when a
member is (i) added to or (ii) removed from a bridge, or (iii)
if_csum_flags_tx flag of a member interface is manipulated via
ifconfig(8).

Turn on M_CSUM_TSOv[46] bit in ifp->if_csum_flags_tx flag when
TSO[46] is enabled for that interface.

OK msaitoh thorpej
2018-12-12 01:46:47 +00:00