| Age | Commit message (Collapse) | Author |
|
While here, check for errors from bus_generic_detach and move it to
the start of detach if necessary.
Differential Revision: https://reviews.freebsd.org/D47969
|
|
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D47675
|
|
Use the appropriate function to flush correctly all entries. The old
code does not remove the element from the hash table, only from the
active queue.
Reviewed by: Peter Lei, rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D46433
|
|
Sponsored by: Netflix
|
|
Change 4787572d0580 made if_alloc_domain() never fail, then also do the
wrappers if_alloc(), if_alloc_dev(), and if_gethandle().
No functional change intended.
Reviewed by: kp, imp, glebius, stevek
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D45740
|
|
We've removed kernel option EXT_RESOURCES almost two years ago.
While it was ok to have some code under a common 'extres' subdirectory
at first, we now have a lot of consumer of it and we made it mandatory
so no need to have it under a cryptic name.
Reviewed by: mhorne
Sponsored by: Beckhoff Automation GmbH & Co. KG
Differential Revision: https://reviews.freebsd.org/D43191
|
|
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
|
|
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
|
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
|
|
Sponsored by: Rubicon Communications, LLC ("Netgate")
|
|
Reviewed by: mw
Sponsored by: Juniper Networks, Inc.
Differential Revision: https://reviews.freebsd.org/D37825
|
|
With addition of clkgen devices to the Armada38x we no longer
need to rely on get_tclk() to get the device frequency.
Leave it as a fallback, just in case.
Reviewed by: manu
Obtained from: Semihalf
Differential Revision: https://reviews.freebsd.org/D36465
|
|
The IFF_DRV_RUNNING flag is used to see if the interface needs
to be temporarily brought down during MTU change sequence.
The problem here is that this flag is cleared in mvneta_stop_locked,
resulting in the reinitialization logic never being executed after
MTU has been changed.
Fix that by saving the flag value before the interface is brought down.
Reported by: Jérôme Tomczyk <jerome.tomczyk@stormshield.eu>
Approved by: mw(mentor)
Obtained from: Semihalf
Sponsored by: Stormshield
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
|
- s/maintance/maintenance/
MFC after: 3 days
|
|
|
|
Sponsored by: Netflix
|
|
- s/immediatly/immediately/
MFC after: 3 days
|
|
- s/hander/handler/
MFC after: 3 days
|
|
Fixed-link mode requires different handling than the in-band
managed connection. Update interrupt, link-up/down and
autonegotiation settings for the former.
Reviewed by: mw
MFC after: 1 week
Obtained from: Stormshield
Differential Revision: https://reviews.freebsd.org/D34394
|
|
So #ifdef the clk.h include aarch64. Otherwise the right kernel options
aren't always present.
Sponsored by: Netflix
|
|
The error message is useful for diagnosing mvneta_attach() failures.
MFC after: 1 week
|
|
Make neta use frequency obtained from clock, instead of
hardcoded one. Use default frequency in case of clock
device failure. Remove unnecessary function calls
to obtain frequency and use cached one instead.
Reviewed by: manu
Obtained from: Semihalf
Differential revision: https://reviews.freebsd.org/D32336
|
|
|
|
Fix MVNETA encap property.
|
|
mvneta_find_ethernet_prop_switch() is file-local static to
if_mvneta_fdt.c. Normally we would not need a function declararion
but in case MVNETA_DEBUG is set it becomes public. Move the
function declaration from if_mvneta.c to if_mvneta_fdt.c to avoid
a warning during each compile.
|
|
Split some missing routines.
Obtained from: Semihalf
|
|
Fix device detach and attach routine. Add required Makefile
to build as a module. Remove entry from GENERIC, since now
it can be loaded automatically.
Tested on EspressoBin.
Obtained from: Semihalf
Reviewed by: manu
Differential revision: https://reviews.freebsd.org/D31581
|
|
This reverts commit bcf5c7a8b1dcdcd5f27c1aa694f66208dc07a0dd.
|
|
Fix device detach and attach routine. Add required Makefile
to build as a module. Remove entry from GENERIC, since now
it can be loaded automatically.
Tested on EspressoBin.
Obtained from: Semihalf
Reviewed by: manu
Differential revision: https://reviews.freebsd.org/D31581
|
|
This reverts commit 41b0190cc404e21cb8b430602eabfedc20107471.
|
|
Fix device detach and attach routine. Add required Makefile
to build as a module. Remove entry from GENERIC, since now
it can be loaded automatically.
Tested on EspressoBin.
Obtained from: Semihalf
Reviewed by: manu
Differential revision: https://reviews.freebsd.org/D31581
|
|
After MTU is updated we might start using allocating RX buffers from different pool. (MJUM9BYTES vs MCLBYTES)
Because of that we need to update the RX buffer size in hardware.
Previously it was done only when the interface was up, which is incorrect since MTU can be changed at any time.
Differential revision: https://reviews.freebsd.org/D31724
Sponsored by: Stormshield
Obtained from: Semihalf
MFC after: 2 weeks
Reviewed by: wma
|
|
Reported by: Andrei Martin <andrei.cos.martin@gmail.com>
MFC with: caf552a60719
|
|
It appears we must read MIB values as 2 4-byte words, lower address
first. A single 8-byte MIB read returns the value with the lower 4
bytes copied into the upper 4 bytes, resulting in bogus byte counter
values.
Reviewed by: mw
MFC after: 2 weeks
Sponsored by: Rubicon Communications, LLC (Netgate)
Differential Revision: https://reviews.freebsd.org/D27870
|
|
The mvneta device requires MVNETA_TX_CMD_L4_CHECKSUM_NONE bit to be set in the tx descriptor is checksum not required. However, mvneta_tx_set_csumflag() is not setting this flag currently, causing the hardware to randomly corrupt IP header during transmission.
This affects injected IPv4 packets that skips kernel IP stack processing (e.g. DHCP), as well as all IPv6 packets, since the driver currently does not offload csum for IPv6.
The fix is to remove all the early return paths from mvneta_tx_set_csumflag() which do not set the MVNETA_TX_CMD_L4_CHECKSUM_NONE flag.
PR: 248306
Submitted by: Mike Cui <cuicui@gmail.com>
Reported by: Mike Cui <cuicui@gmail.com>
Notes:
svn path=/head/; revision=363759
|
|
r357614 added CTLFLAG_NEEDGIANT to make it easier to find nodes that are
still not MPSAFE (or already are but aren’t properly marked).
Use it in preparation for a general review of all nodes.
This is non-functional change that adds annotations to SYSCTL_NODE and
SYSCTL_PROC nodes using one of the soon-to-be-required flags.
Mark all obvious cases as MPSAFE. All entries that haven't been marked
as MPSAFE before are by default marked as NEEDGIANT
Approved by: kib (mentor, blanket)
Commented by: kib, gallatin, melifaro
Differential Revision: https://reviews.freebsd.org/D23718
Notes:
svn path=/head/; revision=358333
|
|
This patch introduces processing of the frames
up to 9kB by the mvneta driver. Some versions of
this NIC limit TX checksum offloading, depending
on the frame size, so add appropriate handling
of this feature.
Submitted by: Kornel Duleba
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D23225
Notes:
svn path=/head/; revision=357676
|
|
This patch fixes deinitialization sequence of the mvneta
driver by adding missing bus_dma_tag_destroy call.
Submitted by: Kornel Duleba <mindal@semihalf.com>
Obtained from: Semihalf
MFC after: 1 week
Sponsored by: Stormshield
Notes:
svn path=/head/; revision=357675
|
|
In the latest Linux kernel revisions the DSA (Distributed
Switch Architecture) device tree binding was changed.
Instead of the top level dsa@ node, the switch and its
ports is represented as a child node of the mdio bus.
With that other modifications were added, such as
relation with the ethernet port of the SoC. Adjust
e6000sw etherswitch and mvneta drivers to that.
Tested on Armada 3720 EspressoBin and Armada 388 Clearfog Pro boards.
Submitted by: Bert JW Regeer <xistence@0x58.com>
Reviewed by: manu
Differential Revision: https://reviews.freebsd.org/D19036
Notes:
svn path=/head/; revision=345432
|
|
Tested on SG-3100 (ARMADA38X) and Espresso.bin (A37x0). Fixes the network
on espresso.bin.
Sponsored by: Rubicon Communications, LLC (Netgate)
Notes:
svn path=/head/; revision=337811
|
|
OF_getprop_alloc takes element size argument and returns number of
elements in the property. There are valid use cases for such behavior
but mostly API consumers pass 1 as element size to get string
properties. What API users would expect from OF_getprop_alloc is to be
a combination of malloc + OF_getprop with the same semantic of return
value. This patch modifies API signature to match these expectations.
For the valid use cases with element size != 1 and to reduce
modification scope new OF_getprop_alloc_multi function has been
introduced that behaves the same way OF_getprop_alloc behaved prior to
this patch.
Reviewed by: ian, manu
Differential Revision: https://reviews.freebsd.org/D14850
Notes:
svn path=/head/; revision=332310
|
|
Defining a variable with the description and then only use it in the
SYSCTL declaration led to an unused variable warning. In the SYSCTL the
passed value is discarded using __DESCR.
Notes:
svn path=/head/; revision=324089
|
|
Compiling mvneta driver with gcc unveiled two issues, that
required fixing.
Reported by: andrew
Obtained from: Semihalf
Notes:
svn path=/head/; revision=323983
|
|
This patch enables using NETA driver on Marvell Armada 3700 SoC
by introducing new compatible string, modifying clock source
obtaining and also excluding unnecessary parts.
The driver is added as a build option for arm64 platforms as well.
Submitted by: Patryk Duda <pdk@semihalf.com>
Obtained from: Semihalf
Sponsored by: Semihalf
Differential Revision: https://reviews.freebsd.org/D12258
Notes:
svn path=/head/; revision=323362
|
|
Now the virtual address of received buffer is taken from a software ring.
Thanks to this, we can use the NETA driver on 64 bits architecture and
avoid 32-bit buf_cookie descriptor field limitation.
Submitted by: Patryk Duda <pdk@semihalf.com>
Obtained from: Semihalf
Sponsored by: Semihalf
Differential Revision: https://reviews.freebsd.org/D12257
Notes:
svn path=/head/; revision=323361
|
|
speeds properly.
While here remove a couple of stray white spaces.
Sponsored by: Rubicon Communications, LLC (Netgate)
Notes:
svn path=/head/; revision=320158
|