Page MenuHomeFreeBSD

D6345.id16278.diff
No OneTemporary

D6345.id16278.diff

Index: sys/conf/files.arm64
===================================================================
--- sys/conf/files.arm64
+++ sys/conf/files.arm64
@@ -81,7 +81,7 @@
dev/vnic/thunder_bgx.c optional vnic pci
dev/vnic/thunder_mdio_fdt.c optional vnic fdt
dev/vnic/thunder_mdio.c optional vnic
-dev/vnic/lmac_if.m optional vnic
+dev/vnic/lmac_if.m optional inet | inet6 | vnic
kern/kern_clocksource.c standard
kern/subr_devmap.c standard
libkern/bcmp.c standard
Index: sys/dev/vnic/mrml_bridge.c
===================================================================
--- sys/dev/vnic/mrml_bridge.c
+++ sys/dev/vnic/mrml_bridge.c
@@ -85,6 +85,7 @@
EARLY_DRIVER_MODULE(mrmlbus, pcib, mrmlbus_fdt_driver, mrmlbus_fdt_devclass, 0, 0,
BUS_PASS_BUS + BUS_PASS_ORDER_MIDDLE);
+MODULE_VERSION(mrmlbus, 1);
static int mrmlb_ofw_fill_ranges(phandle_t, struct simplebus_softc *);
static int mrmlb_ofw_bus_attach(device_t);
Index: sys/dev/vnic/nic_main.c
===================================================================
--- sys/dev/vnic/nic_main.c
+++ sys/dev/vnic/nic_main.c
@@ -137,18 +137,19 @@
DEVMETHOD_END,
};
-static driver_t nicpf_driver = {
+static driver_t vnicpf_driver = {
"vnicpf",
nicpf_methods,
sizeof(struct nicpf),
};
-static devclass_t nicpf_devclass;
+static devclass_t vnicpf_devclass;
-DRIVER_MODULE(nicpf, pci, nicpf_driver, nicpf_devclass, 0, 0);
-MODULE_DEPEND(nicpf, pci, 1, 1, 1);
-MODULE_DEPEND(nicpf, ether, 1, 1, 1);
-MODULE_DEPEND(nicpf, thunder_bgx, 1, 1, 1);
+DRIVER_MODULE(vnicpf, pci, vnicpf_driver, vnicpf_devclass, 0, 0);
+MODULE_VERSION(vnicpf, 1);
+MODULE_DEPEND(vnicpf, pci, 1, 1, 1);
+MODULE_DEPEND(vnicpf, ether, 1, 1, 1);
+MODULE_DEPEND(vnicpf, thunder_bgx, 1, 1, 1);
static int nicpf_alloc_res(struct nicpf *);
static void nicpf_free_res(struct nicpf *);
Index: sys/dev/vnic/nicvf_main.c
===================================================================
--- sys/dev/vnic/nicvf_main.c
+++ sys/dev/vnic/nicvf_main.c
@@ -129,10 +129,11 @@
static devclass_t nicvf_devclass;
-DRIVER_MODULE(nicvf, pci, nicvf_driver, nicvf_devclass, 0, 0);
-MODULE_DEPEND(nicvf, pci, 1, 1, 1);
-MODULE_DEPEND(nicvf, ether, 1, 1, 1);
-MODULE_DEPEND(nicvf, vnic_pf, 1, 1, 1);
+DRIVER_MODULE(vnicvf, pci, nicvf_driver, nicvf_devclass, 0, 0);
+MODULE_VERSION(vnicvf, 1);
+MODULE_DEPEND(vnicvf, pci, 1, 1, 1);
+MODULE_DEPEND(vnicvf, ether, 1, 1, 1);
+MODULE_DEPEND(vnicvf, vnicpf, 1, 1, 1);
static int nicvf_allocate_misc_interrupt(struct nicvf *);
static int nicvf_enable_misc_interrupt(struct nicvf *);
Index: sys/dev/vnic/thunder_bgx.c
===================================================================
--- sys/dev/vnic/thunder_bgx.c
+++ sys/dev/vnic/thunder_bgx.c
@@ -109,9 +109,10 @@
static devclass_t thunder_bgx_devclass;
DRIVER_MODULE(thunder_bgx, pci, thunder_bgx_driver, thunder_bgx_devclass, 0, 0);
+MODULE_VERSION(thunder_bgx, 1);
MODULE_DEPEND(thunder_bgx, pci, 1, 1, 1);
MODULE_DEPEND(thunder_bgx, ether, 1, 1, 1);
-MODULE_DEPEND(thunder_bgx, octeon_mdio, 1, 1, 1);
+MODULE_DEPEND(thunder_bgx, thunder_mdio, 1, 1, 1);
static int
thunder_bgx_probe(device_t dev)
Index: sys/dev/vnic/thunder_mdio.c
===================================================================
--- sys/dev/vnic/thunder_mdio.c
+++ sys/dev/vnic/thunder_mdio.c
@@ -122,8 +122,10 @@
sizeof(struct thunder_mdio_softc));
DRIVER_MODULE(miibus, thunder_mdio, miibus_driver, miibus_devclass, 0, 0);
+MODULE_VERSION(thunder_mdio, 1);
MODULE_DEPEND(thunder_mdio, ether, 1, 1, 1);
MODULE_DEPEND(thunder_mdio, miibus, 1, 1, 1);
+MODULE_DEPEND(thunder_mdio, mrmlbus, 1, 1, 1);
MALLOC_DEFINE(M_THUNDER_MDIO, "ThunderX MDIO",
"Cavium ThunderX MDIO dynamic memory");
Index: sys/modules/vnic/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/Makefile
@@ -0,0 +1,36 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+CFLAGS+= -DFDT
+
+SUBDIR = mrmlbus thunder_mdio thunder_bgx vnicpf vnicvf
+
+.include <bsd.subdir.mk>
Index: sys/modules/vnic/mrmlbus/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/mrmlbus/Makefile
@@ -0,0 +1,42 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+S= ${.CURDIR}/../../..
+
+.PATH: $S/dev/vnic
+
+KMOD= mrmlbus
+SRCS= device_if.h bus_if.h opt_platform.h pci_if.h ofw_bus_if.h miibus_if.h lmac_if.h
+SRCS+= mrml_bridge.c
+
+CFLAGS+= -DFDT
+
+.include <bsd.kmod.mk>
Index: sys/modules/vnic/thunder_bgx/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/thunder_bgx/Makefile
@@ -0,0 +1,42 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+S= ${.CURDIR}/../../..
+
+.PATH: $S/dev/vnic
+
+KMOD= thunder_bgx
+SRCS= thunder_bgx.c thunder_bgx_fdt.c
+SRCS+= opt_platform.h device_if.h bus_if.h pci_if.h lmac_if.h ofw_bus_if.h
+
+CFLAGS+= -DFDT
+
+.include <bsd.kmod.mk>
Index: sys/modules/vnic/thunder_mdio/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/thunder_mdio/Makefile
@@ -0,0 +1,42 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+S= ${.CURDIR}/../../..
+
+.PATH: $S/dev/vnic
+
+KMOD= thunder_mdio
+SRCS= opt_platform.h device_if.h bus_if.h pci_if.h ofw_bus_if.h miibus_if.h lmac_if.h
+SRCS+= thunder_mdio.c thunder_mdio_fdt.c
+
+CFLAGS+= -DFDT
+
+.include <bsd.kmod.mk>
Index: sys/modules/vnic/vnicpf/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/vnicpf/Makefile
@@ -0,0 +1,42 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+S= ${.CURDIR}/../../..
+
+.PATH: $S/dev/vnic
+
+KMOD= vnicpf
+SRCS= pci_iov_if.h opt_platform.h device_if.h bus_if.h pci_if.h ofw_bus_if.h miibus_if.h lmac_if.h
+SRCS+= nic_main.c
+
+CFLAGS+= -DFDT -DPCI_IOV
+
+.include <bsd.kmod.mk>
Index: sys/modules/vnic/vnicvf/Makefile
===================================================================
--- /dev/null
+++ sys/modules/vnic/vnicvf/Makefile
@@ -0,0 +1,42 @@
+# Copyright (c) 2016 Cavium
+# All rights reserved.
+#
+# This software was developed by Semihalf.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+
+SYSDIR?=${.CURDIR}/../../..
+.include "${SYSDIR}/conf/kern.opts.mk"
+
+S= ${.CURDIR}/../../..
+
+.PATH: $S/dev/vnic
+
+KMOD= vnicvf
+SRCS= nicvf_main.c nicvf_queues.c
+SRCS+= opt_platform.h ofw_bus_if.h lmac_if.h miibus_if.h pci_if.h bus_if.h device_if.h opt_inet.h opt_inet6.h
+
+CFLAGS+= -DFDT -DPCI_IOV
+
+.include <bsd.kmod.mk>

File Metadata

Mime Type
text/plain
Expires
Mon, Feb 9, 7:34 AM (1 h, 59 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28553916
Default Alt Text
D6345.id16278.diff (14 KB)

Event Timeline