/openbmc/linux/drivers/net/ethernet/mediatek/ |
H A D | mtk_eth_soc.c | 1 // SPDX-License-Identifier: GPL-2.0-only 4 * Copyright (C) 2009-2016 John Crispin <blogic@openwrt.org> 5 * Copyright (C) 2009-2016 Felix Fietkau <nbd@openwrt.org> 6 * Copyright (C) 2013-2016 Michael Lee <igvtee@gmail.com> 24 #include <linux/pcs/pcs-mtk-lynxi.h> 34 static int mtk_msg_level = -1; 36 MODULE_PARM_DESC(msg_level, "Message level (-1=defaults,0=none,...,16=all)"); 282 void mtk_w32(struct mtk_eth *eth, u32 val, unsigned reg) in mtk_w32() argument 284 __raw_writel(val, eth->base + reg); in mtk_w32() 287 u32 mtk_r32(struct mtk_eth *eth, unsigned reg) in mtk_r32() argument [all …]
|
H A D | mtk_ppe_offload.c | 1 // SPDX-License-Identifier: GPL-2.0-only 17 struct ethhdr eth; member 55 mtk_flow_set_ipv4_addr(struct mtk_eth *eth, struct mtk_foe_entry *foe, in mtk_flow_set_ipv4_addr() argument 58 return mtk_foe_entry_set_ipv4_tuple(eth, foe, egress, in mtk_flow_set_ipv4_addr() 59 data->v4.src_addr, data->src_port, in mtk_flow_set_ipv4_addr() 60 data->v4.dst_addr, data->dst_port); in mtk_flow_set_ipv4_addr() 64 mtk_flow_set_ipv6_addr(struct mtk_eth *eth, struct mtk_foe_entry *foe, in mtk_flow_set_ipv6_addr() argument 67 return mtk_foe_entry_set_ipv6_tuple(eth, foe, in mtk_flow_set_ipv6_addr() 68 data->v6.src_addr.s6_addr32, data->src_port, in mtk_flow_set_ipv6_addr() 69 data->v6.dst_addr.s6_addr32, data->dst_port); in mtk_flow_set_ipv6_addr() [all …]
|
/openbmc/linux/net/ethernet/ |
H A D | eth.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 7 * Ethernet-type device handling. 9 * Version: @(#)eth.c 1.0.7 05/25/93 14 * Florian La Roche, <rzsfl@rz.uni-sb.de> 29 * Alan Cox : MAC layer pointers/new format. 34 * Andrew Morton : 26Feb01: kill ether_setup() - use netdev_boot_setup(). 46 #include <linux/nvmem-consumer.h> 67 * eth_header - create the Ethernet header 73 * @len: packet length (<= skb->len) 83 struct ethhdr *eth = skb_push(skb, ETH_HLEN); in eth_header() local [all …]
|
/openbmc/u-boot/drivers/net/ |
H A D | ravb.c | 1 // SPDX-License-Identifier: GPL-2.0+ 6 * Copyright (C) 2015-2017 Renesas Electronics Corporation 135 u32 start = addr & ~((uintptr_t)ARCH_DMA_MINALIGN - 1); in ravb_invalidate_dcache() 142 struct ravb_priv *eth = dev_get_priv(dev); in ravb_send() local 143 struct ravb_desc *desc = ð->tx_desc[eth->tx_desc_idx]; in ravb_send() 149 desc->ctrl = RAVB_DESC_DT_FSINGLE | RAVB_DESC_DS(len); in ravb_send() 150 desc->dptr = (uintptr_t)packet; in ravb_send() 154 if (!(readl(eth->iobase + RAVB_REG_TCCR) & TCCR_TSRQ0)) in ravb_send() 155 setbits_le32(eth->iobase + RAVB_REG_TCCR, TCCR_TSRQ0); in ravb_send() 161 if ((desc->ctrl & RAVB_DESC_DT_MASK) != RAVB_DESC_DT_FSINGLE) in ravb_send() [all …]
|
H A D | sh_eth.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * sh_eth.c - Driver for Renesas ethernet controller. 53 start &= ~(line_size - 1); \ 54 end = ((end + line_size - 1) & ~(line_size - 1)); \ 64 static int sh_eth_send_common(struct sh_eth_dev *eth, void *packet, int len) in sh_eth_send_common() argument 67 struct sh_eth_info *port_info = ð->port_info[eth->port]; in sh_eth_send_common() 71 ret = -EINVAL; in sh_eth_send_common() 79 ret = -EFAULT; in sh_eth_send_common() 85 port_info->tx_desc_cur->td2 = ADDR_TO_PHY(packet); in sh_eth_send_common() 86 port_info->tx_desc_cur->td1 = len << 16; in sh_eth_send_common() [all …]
|
H A D | bcm-sf2-eth.c | 1 // SPDX-License-Identifier: GPL-2.0+ 17 #include "bcm-sf2-eth.h" 20 #include "bcm-sf2-eth-gmac.h" 22 #error "bcm_sf2_eth: NEED to define a MAC!" 34 struct eth_info *eth = (struct eth_info *)(dev->priv); in bcm_sf2_eth_init() local 35 struct eth_dma *dma = &(eth->dma); in bcm_sf2_eth_init() 40 rc = eth->mac_init(dev); in bcm_sf2_eth_init() 42 pr_err("%s: Couldn't cofigure MAC!\n", __func__); in bcm_sf2_eth_init() 47 dma->disable_dma(dma, MAC_DMA_RX); in bcm_sf2_eth_init() 48 dma->disable_dma(dma, MAC_DMA_TX); in bcm_sf2_eth_init() [all …]
|
H A D | fec_mxc.c | 1 // SPDX-License-Identifier: GPL-2.0+ 25 #include <asm/arch/imx-regs.h> 26 #include <asm/mach-imx/sys_proto.h> 27 #include <asm-generic/gpio.h> 40 * The standard 32-byte DMA alignment does not work on mx6solox, which requires 41 * 64-byte alignment in the DMA RX FEC buffer. 43 * satisfies the alignment on other SoCs (32-bytes) 87 /* MII-interface related functions */ 88 static int fec_mdio_read(struct ethernet_regs *eth, uint8_t phyaddr, in fec_mdio_read() argument 100 writel(FEC_IEVENT_MII, ð->ievent); in fec_mdio_read() [all …]
|
/openbmc/linux/Documentation/devicetree/bindings/net/ |
H A D | qca,ar71xx.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: QCA AR71XX MAC 10 - $ref: ethernet-controller.yaml# 13 - Oleksij Rempel <o.rempel@pengutronix.de> 18 - items: 19 - enum: 20 - qca,ar7100-eth # Atheros AR7100 21 - qca,ar7240-eth # Atheros AR7240 [all …]
|
H A D | mediatek,net.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Lorenzo Bianconi <lorenzo@kernel.org> 11 - Felix Fietkau <nbd@nbd.name> 20 - mediatek,mt2701-eth 21 - mediatek,mt7623-eth 22 - mediatek,mt7621-eth 23 - mediatek,mt7622-eth 24 - mediatek,mt7629-eth [all …]
|
H A D | stm32-dwmac.yaml | 1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 4 --- 5 $id: http://devicetree.org/schemas/net/stm32-dwmac.yaml# 6 $schema: http://devicetree.org/meta-schemas/core.yaml# 11 - Alexandre Torgue <alexandre.torgue@foss.st.com> 12 - Christophe Roullier <christophe.roullier@foss.st.com> 23 - st,stm32-dwmac 24 - st,stm32mp1-dwmac 26 - compatible 29 - $ref: snps,dwmac.yaml# [all …]
|
/openbmc/linux/Documentation/networking/device_drivers/ethernet/freescale/dpaa2/ |
H A D | mac-phy-support.rst | 1 .. SPDX-License-Identifier: GPL-2.0 5 DPAA2 MAC / PHY support 11 -------- 13 The DPAA2 MAC / PHY support consists of a set of APIs that help DPAA2 network 14 drivers (dpaa2-eth, dpaa2-ethsw) interact with the PHY library. 17 --------------------------- 19 Among other DPAA2 objects, the fsl-mc bus exports DPNI objects (abstracting a 20 network interface) and DPMAC objects (abstracting a MAC). The dpaa2-eth driver 26 directly by the dpaa2-eth driver or by phylink. 28 .. code-block:: none [all …]
|
/openbmc/linux/tools/testing/selftests/bpf/ |
H A D | test_tc_tunnel.sh | 2 # SPDX-License-Identifier: GPL-2.0 4 # In-place tunneling 10 readonly ns_prefix="ns-$$-" 35 ip netns exec "${ns1}" ethtool -K veth1 tso off 37 ip -netns "${ns1}" link set veth1 up 38 ip -netns "${ns2}" link set veth2 up 40 ip -netns "${ns1}" -4 addr add "${ns1_v4}/24" dev veth1 41 ip -netns "${ns2}" -4 addr add "${ns2_v4}/24" dev veth2 42 ip -netns "${ns1}" -6 addr add "${ns1_v6}/64" dev veth1 nodad 43 ip -netns "${ns2}" -6 addr add "${ns2_v6}/64" dev veth2 nodad [all …]
|
/openbmc/linux/tools/testing/selftests/bpf/progs/ |
H A D | xdp_redirect_multi_kern.c | 1 // SPDX-License-Identifier: GPL-2.0 29 /* map to store egress interfaces mac addresses */ 40 void *data_end = (void *)(long)ctx->data_end; in xdp_redirect_map_multi_prog() 41 void *data = (void *)(long)ctx->data; in xdp_redirect_map_multi_prog() 42 int if_index = ctx->ingress_ifindex; in xdp_redirect_map_multi_prog() 43 struct ethhdr *eth = data; in xdp_redirect_map_multi_prog() local 47 nh_off = sizeof(*eth); in xdp_redirect_map_multi_prog() 51 h_proto = eth->h_proto; in xdp_redirect_map_multi_prog() 76 void *data_end = (void *)(long)ctx->data_end; in xdp_devmap_prog() 77 void *data = (void *)(long)ctx->data; in xdp_devmap_prog() [all …]
|
/openbmc/linux/drivers/net/ethernet/freescale/dpaa2/ |
H A D | Makefile | 1 # SPDX-License-Identifier: GPL-2.0 6 obj-$(CONFIG_FSL_DPAA2_ETH) += fsl-dpaa2-eth.o 7 obj-$(CONFIG_FSL_DPAA2_PTP_CLOCK) += fsl-dpaa2-ptp.o 8 obj-$(CONFIG_FSL_DPAA2_SWITCH) += fsl-dpaa2-switch.o 10 fsl-dpaa2-eth-objs := dpaa2-eth.o dpaa2-ethtool.o dpni.o dpaa2-mac.o dpmac.o dpaa2-eth-devlink.o dp… 11 fsl-dpaa2-eth-${CONFIG_FSL_DPAA2_ETH_DCB} += dpaa2-eth-dcb.o 12 fsl-dpaa2-eth-${CONFIG_DEBUG_FS} += dpaa2-eth-debugfs.o 13 fsl-dpaa2-ptp-objs := dpaa2-ptp.o dprtc.o 14 fsl-dpaa2-switch-objs := dpaa2-switch.o dpaa2-switch-ethtool.o dpsw.o dpaa2-switch-flower.o dpaa2-m… 17 CFLAGS_dpaa2-eth.o := -I$(src)
|
/openbmc/qemu/qapi/ |
H A D | rocker.json | 1 # -*- Mode: Python -*- 17 # @ports: number of front-panel ports 25 # @query-rocker: 35 # .. qmp-example:: 37 # -> { "execute": "query-rocker", "arguments": { "name": "sw1" } } 38 # <- { "return": {"name": "sw1", "ports": 2, "id": 1327446905938}} 40 { 'command': 'query-rocker', 79 # @link-up: physical link is UP on port 90 'data': { 'name': 'str', 'enabled': 'bool', 'link-up': 'bool', 95 # @query-rocker-ports: [all …]
|
/openbmc/linux/samples/bpf/ |
H A D | xdp_router_ipv4.bpf.c | 31 __be64 mac; member 38 __be64 mac; member 76 void *data_end = (void *)(long)ctx->data_end; in xdp_router_ipv4_prog() 77 void *data = (void *)(long)ctx->data; in xdp_router_ipv4_prog() 78 struct ethhdr *eth = data; in xdp_router_ipv4_prog() local 79 u64 nh_off = sizeof(*eth); in xdp_router_ipv4_prog() 86 NO_TEAR_INC(rec->processed); in xdp_router_ipv4_prog() 91 h_proto = eth->h_proto; in xdp_router_ipv4_prog() 101 h_proto = vhdr->h_vlan_encapsulated_proto; in xdp_router_ipv4_prog() 107 NO_TEAR_INC(rec->xdp_pass); in xdp_router_ipv4_prog() [all …]
|
/openbmc/u-boot/test/dm/ |
H A D | eth.c | 1 // SPDX-License-Identifier: GPL-2.0 15 #include <dm/device-internal.h> 16 #include <dm/uclass-internal.h> 17 #include <asm/eth.h> 26 env_set("ethact", "eth@10002000"); in dm_test_eth() 28 ut_asserteq_str("eth@10002000", env_get("ethact")); in dm_test_eth() 30 env_set("ethact", "eth@10003000"); in dm_test_eth() 32 ut_asserteq_str("eth@10003000", env_get("ethact")); in dm_test_eth() 34 env_set("ethact", "eth@10004000"); in dm_test_eth() 36 ut_asserteq_str("eth@10004000", env_get("ethact")); in dm_test_eth() [all …]
|
/openbmc/linux/Documentation/networking/ |
H A D | statistics.rst | 1 .. SPDX-License-Identifier: GPL-2.0 14 - standard interface statistics based on 16 - protocol-specific statistics; and 17 - driver-defined statistics available via ethtool. 20 ----------------------------- 25 $ ip -s -s link show dev ens4u1u1 38 Note that `-s` has been specified twice to see all members of 40 If `-s` is specified once the detailed errors won't be shown. 42 `ip` supports JSON formatting via the `-j` option. 44 Protocol-specific statistics [all …]
|
/openbmc/linux/arch/um/drivers/ |
H A D | net_kern.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * Copyright (C) 2001 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com) 28 #define DRIVER_NAME "uml-netdev" 56 err = -ENOMEM; in update_drop_skb() 80 skb = dev_alloc_skb(lp->max_packet); in uml_net_rx() 82 drop_skb->dev = dev; in uml_net_rx() 84 (*lp->read)(lp->fd, drop_skb, lp); in uml_net_rx() 85 dev->stats.rx_dropped++; in uml_net_rx() 89 skb->dev = dev; in uml_net_rx() 90 skb_put(skb, lp->max_packet); in uml_net_rx() [all …]
|
/openbmc/linux/arch/mips/cavium-octeon/ |
H A D | octeon-platform.c | 6 * Copyright (C) 2004-2017 Cavium, Inc. 18 #include <asm/octeon/cvmx-helper-board.h> 24 #include <asm/octeon/cvmx-uctlx-defs.h> 78 if (dev->of_node) { in octeon2_usb_clocks_start() 82 uctl_node = of_get_parent(dev->of_node); in octeon2_usb_clocks_start() 88 "refclk-frequency", &clock_rate); in octeon2_usb_clocks_start() 90 dev_err(dev, "No UCTL \"refclk-frequency\"\n"); in octeon2_usb_clocks_start() 95 "refclk-type", &clock_type); in octeon2_usb_clocks_start() 203 * Step 4: Program the power-on reset field in the UCTL in octeon2_usb_clocks_start() 204 * clock-reset-control register. in octeon2_usb_clocks_start() [all …]
|
/openbmc/linux/drivers/staging/gdm724x/ |
H A D | gdm_lte.c | 1 // SPDX-License-Identifier: GPL-2.0 64 if (dev->flags & IFF_UP) in gdm_lte_set_config() 65 return -EBUSY; in gdm_lte_set_config() 73 if (netif_queue_stopped(nic->netdev)) in tx_complete() 74 netif_wake_queue(nic->netdev); in tx_complete() 81 len = skb->len + ETH_HLEN; in gdm_lte_rx() 84 nic->stats.rx_dropped++; in gdm_lte_rx() 86 nic->stats.rx_packets++; in gdm_lte_rx() 87 nic->stats.rx_bytes += len; in gdm_lte_rx() 95 struct nic *nic = netdev_priv(skb_in->dev); in gdm_lte_emulate_arp() [all …]
|
/openbmc/u-boot/net/ |
H A D | eth-uclass.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * (C) Copyright 2001-2015 12 #include <dm/device-internal.h> 13 #include <dm/uclass-internal.h> 19 * struct eth_device_priv - private structure for each Ethernet device 21 * @state: The state of the Ethernet MAC driver (defined by enum eth_state_t) 28 * struct eth_uclass_priv - The structure attached to the uclass itself 36 /* eth_errno - This stores the most recent failure code from DM functions */ 45 return uc->priv; in eth_get_uclass_priv() 53 if (uc_priv->current) in eth_set_current_to_next() [all …]
|
/openbmc/openbmc/meta-ibm/recipes-phosphor/network/ |
H A D | phosphor-network_%.bbappend | 3 inherit obmc-phosphor-systemd 11 FAILOVER_TMPL = "ncsi-failover@.service" 12 LINKSPEED_TMPL = "ncsi-linkspeed@.service" 14 SRC_URI += " file://ncsi-netlink-ifindex" 15 SRC_URI += " file://ncsi-wait-and-set-speed" 16 SRC_URI:append:ibm-ac-server = " file://${FAILOVER_TMPL}" 19 SYSTEMD_SERVICE:${PN}:append:ibm-ac-server = " ${FAILOVER_TMPL}" 22 FAILOVER_TGTFMT = "ncsi-failover@{0}.service" 23 LINKSPEED_TGTFMT = "ncsi-linkspeed@{0}.service" 27 SYSTEMD_LINK:${PN}:append:ibm-ac-server = "${@compose_list(d, 'FAILOVER_FMT', 'OBMC_NETWORK_INTERFA… [all …]
|
/openbmc/linux/drivers/net/ethernet/ezchip/ |
H A D | nps_enet.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 59 /* Gbps Eth MAC Configuration 0 register masks and shifts */ 93 /* Gbps Eth MAC Configuration 1 register masks and shifts */ 103 /* Gbps Eth MAC Configuration 2 register masks and shifts */ 119 /* Gbps Eth MAC Configuration 3 register masks and shifts */ 141 /* GE MAC, PCS reset control register masks and shifts */ 154 * struct nps_enet_priv - Storage of ENET's private information. 155 * @regs_base: Base address of ENET memory-mapped control registers. 170 * nps_enet_reg_set - Sets ENET register with provided value. 178 iowrite32be(value, priv->regs_base + reg); in nps_enet_reg_set() [all …]
|
/openbmc/linux/arch/arm/boot/dts/mediatek/ |
H A D | mt7629-rfb.dts | 1 // SPDX-License-Identifier: GPL-2.0 7 /dts-v1/; 8 #include <dt-bindings/input/input.h> 13 compatible = "mediatek,mt7629-rfb", "mediatek,mt7629"; 20 stdout-path = "serial0:115200n8"; 23 gpio-keys { 24 compatible = "gpio-keys"; 26 button-reset { 32 button-wps { 44 reg_3p3v: regulator-3p3v { [all …]
|