/Zephyr-latest/samples/net/vlan/ |
D | README.rst | 1 .. zephyr:code-sample:: vlan 10 The VLAN sample application for Zephyr will setup two virtual LAN networks. 11 The application sample enables net-shell and allows users to view VLAN settings. 14 :zephyr_file:`samples/net/vlan`. 24 A good way to run this VLAN application is with QEMU as described in 25 :ref:`networking_with_eth_qemu`. You can use :file:`zeth-vlan.conf` configuration 30 ./net-setup.sh -c zeth-vlan.conf 32 Note that VLAN is only supported for boards that have an ethernet port or 35 Follow these steps to build the VLAN sample application: 38 :zephyr-app: samples/net/vlan [all …]
|
D | sample.yaml | 5 - vlan 7 description: Test VLAN functionality 8 name: VLAN sample app 10 sample.net.vlan:
|
D | prj.conf | 28 # Ethernet is needed for VLAN 44 # Second VLAN supported network interface will have these settings 49 # VLAN tag for the second interface 52 # Settings for the third VLAN supported network interface 57 # VLAN tag for the second interface 63 # VLAN settings.
|
D | Kconfig | 1 # Private config options for VLAN sample app 6 mainmenu "Networking VLAN sample application" 24 int "VLAN tag for second interface" 29 Set VLAN (virtual LAN) tag (id) that is used in the sample 48 int "VLAN tag for third interface" 53 Set VLAN (virtual LAN) tag (id) that is used in the sample
|
D | vlan-setup-linux.sh | 17 # Setup virtual lan (VLAN) in Linux side that would work with this sample. 21 echo "This is the network interface where the VLAN will be running." 33 VLAN_NAME_PREFIX="vlan" 46 ip link add link ${IFACE} name ${VLAN_NAME_PREFIX}.100 type vlan id 100 47 ip link add link ${IFACE} name ${VLAN_NAME_PREFIX}.200 type vlan id 200 68 # ip link del link eth0 dev vlan.100 69 # ip link del link eth0 dev vlan.200 73 # ip neigh flush dev vlan.100 74 # ip neigh flush dev vlan.200
|
/Zephyr-latest/doc/connectivity/networking/api/ |
D | vlan.rst | 3 Virtual LAN (VLAN) Support 13 `Virtual LAN <https://wikipedia.org/wiki/Virtual_LAN>`_ (VLAN) is a 18 In Zephyr, each individual VLAN is modeled as a virtual network interface. 21 created for each VLAN, and this virtual network interface connects to the 26 VLAN support must be enabled at compile time by setting option 29 one network interface without VLAN support, and two with VLAN support, the 32 Even if VLAN is enabled in a :file:`prj.conf` file, the VLAN needs to be 33 activated at runtime by the application. The VLAN API provides a 35 to give the network interface and desired VLAN tag as a parameter to that 36 function. The VLAN tagging for a given network interface can be disabled by a [all …]
|
D | ethernet_mgmt.rst | 17 * raise ``VLAN enabled`` or ``VLAN disabled`` management events 24 Currently the VLAN events are generated by the Ethernet L2 layer when a 25 specific VLAN tag is either enabled or disabled.
|
/Zephyr-latest/include/zephyr/net/ |
D | ethernet_vlan.h | 2 * @brief VLAN specific definitions. 17 * @brief VLAN definitions and helpers 31 /** Unspecified VLAN tag value */ 35 * @brief Get VLAN identifier from TCI. 37 * @param tci VLAN tag control information. 39 * @return VLAN identifier. 49 * @param tci VLAN tag control information. 61 * @param tci VLAN tag control information. 71 * @brief Set VLAN identifier to TCI. 73 * @param tci VLAN tag control information. [all …]
|
/Zephyr-latest/samples/net/gptp/ |
D | Kconfig | 7 # gPTP protocol will run in the non-VLAN interface and then there 8 # will be two VLAN interface for other use. This is just an example 9 # how to do this kind of setup. See also VLAN sample application 10 # for vlan-setup-linux.sh script that can be used to setup the 11 # VLAN IP addressing in Linux side (if that is desired). 28 int "VLAN tag for second interface" 33 Set VLAN (virtual LAN) tag (id) that is used in the sample 47 int "VLAN tag for third interface" 52 Set VLAN (virtual LAN) tag (id) that is used in the sample
|
/Zephyr-latest/subsys/net/l2/ethernet/ |
D | vlan.c | 29 #define MAX_VLAN_NAME_LEN MIN(sizeof("VLAN-<#####>"), \ 162 /* If the interface is NULL, then get the VLAN that has the tag */ in get_vlan() 192 /* If the interface is virtual, then it should be the VLAN one. in get_vlan() 256 snprintk(name, sizeof(name), "VLAN-%d", ctx->tag); in enable_vlan_iface() 259 snprintk(name, sizeof(name), "VLAN to %d", in enable_vlan_iface() 279 snprintk(name, sizeof(name), "VLAN-<free>"); in disable_vlan_iface() 387 struct vlan_context *vlan; in net_eth_vlan_enable() local 399 NET_DBG("Interface %d does not support VLAN", in net_eth_vlan_enable() 412 vlan = get_vlan(iface, tag); in net_eth_vlan_enable() 413 if (vlan != NULL) { in net_eth_vlan_enable() [all …]
|
/Zephyr-latest/samples/net/vlan/src/ |
D | main.c | 39 static int setup_iface(struct net_if *iface, struct net_if *vlan, in setup_iface() argument 50 LOG_ERR("Cannot enable VLAN for tag %d (%d)", vlan_tag, ret); in setup_iface() 59 ifaddr = net_if_ipv6_addr_add(vlan, &addr6, in setup_iface() 63 ipv6_addr, vlan); in setup_iface() 71 if (!net_if_ipv6_prefix_add(vlan, &netaddr6, in setup_iface() 77 vlan); in setup_iface() 88 ifaddr = net_if_ipv4_addr_add(vlan, &addr4, in setup_iface() 92 ipv4_addr, vlan); in setup_iface() 104 net_if_ipv4_set_netmask_by_addr(vlan, &addr4, &nm); in setup_iface() 108 LOG_DBG("Interface %p VLAN tag %d setup done.", vlan, vlan_tag); in setup_iface() [all …]
|
/Zephyr-latest/subsys/net/lib/shell/ |
D | vlan.c | 32 PR_WARNING("Cannot delete VLAN tag %d from " in iface_vlan_del_cb() 42 PR("VLAN tag %d removed from interface %d (%p)\n", vlan_tag, in iface_vlan_del_cb() 86 PR_INFO("Set %s to enable %s support.\n", "CONFIG_NET_VLAN", "VLAN"); in cmd_net_vlan() 102 /* vlan add <tag> <interface index> */ in cmd_net_vlan_add() 104 PR_WARNING("VLAN tag missing.\n"); in cmd_net_vlan_add() 144 PR_WARNING("Cannot set VLAN tag (%d)\n", ret); in cmd_net_vlan_add() 151 PR("VLAN tag %d set to interface %d (%p)\n", tag, in cmd_net_vlan_add() 160 PR_INFO("Set %s to enable %s support.\n", "CONFIG_NET_VLAN", "VLAN"); in cmd_net_vlan_add() 174 /* vlan del <tag> */ in cmd_net_vlan_del() 176 PR_WARNING("VLAN tag missing.\n"); in cmd_net_vlan_del() [all …]
|
/Zephyr-latest/samples/net/sockets/echo_server/ |
D | overlay-vlan.conf | 3 # Allow useful interface assigned to VLAN interface 6 # We have one non-vlan interface and two VLAN interfaces 24 # VLAN tag for the second interface 32 # VLAN tag for the second interface
|
/Zephyr-latest/samples/net/sockets/echo_server/src/ |
D | vlan.c | 45 static int setup_iface(struct net_if *iface, struct net_if *vlan, in setup_iface() argument 56 LOG_ERR("Cannot enable VLAN for tag %d (%d)", vlan_tag, ret); in setup_iface() 65 ifaddr = net_if_ipv6_addr_add(vlan, &addr6, in setup_iface() 69 ipv6_addr, vlan); in setup_iface() 80 ifaddr = net_if_ipv4_addr_add(vlan, &addr4, in setup_iface() 84 ipv4_addr, vlan); in setup_iface() 96 net_if_ipv4_set_netmask_by_addr(vlan, &addr4, &nm); in setup_iface() 100 LOG_DBG("Interface %p VLAN tag %d setup done.", vlan, vlan_tag); in setup_iface() 115 * create IP address for this test. But first the VLAN needs to be in init_vlan()
|
/Zephyr-latest/samples/net/sockets/txtime/ |
D | overlay-vlan.conf | 3 # We have one non-vlan interface and two VLAN interfaces 18 # VLAN tag for the second interface 25 # VLAN tag for the second interface
|
/Zephyr-latest/tests/net/vlan/src/ |
D | main.c | 69 /* VLAN Interface 3 addresses */ 152 "Invalid VLAN tag (%d vs %d) in TX pkt", in eth_tx() 157 net_eth_vlan_get_vid(ntohs(hdr->vlan.tci)), in eth_tx() 158 "Invalid VLAN tag in ethernet header"); in eth_tx() 377 "Too many VLAN interfaces"); in iface_cb() 401 /* One extra eth interface without vlan support */ in test_vlan_setup() 419 iface1 = eth_interfaces[1]; /* This has VLAN enabled */ in test_address_setup() 421 iface3 = vlan_interfaces[0]; /* and this is the virtual VLAN interface */ in test_address_setup() 495 "invalid VLAN tag unspec"); in ZTEST() 497 "invalid VLAN priority"); in ZTEST() [all …]
|
/Zephyr-latest/tests/net/vlan/ |
D | testcase.yaml | 6 - vlan 8 net.vlan.separate_net_buf: 11 net.vlan.header_reserved:
|
/Zephyr-latest/samples/net/sockets/echo_client/ |
D | overlay-vlan.conf | 3 # We have one non-vlan interface and two VLAN interfaces 19 # VLAN tag for the second interface 26 # VLAN tag for the second interface
|
D | Kconfig | 19 int "VLAN tag for second interface" 24 Set VLAN (virtual LAN) tag (id) that is used in the sample 38 int "VLAN tag for third interface" 43 Set VLAN (virtual LAN) tag (id) that is used in the sample
|
/Zephyr-latest/samples/net/lldp/ |
D | Kconfig | 25 int "VLAN tag for second interface" 30 Set VLAN (virtual LAN) tag (id) that is used in the sample 44 int "VLAN tag for third interface" 49 Set VLAN (virtual LAN) tag (id) that is used in the sample
|
D | README.rst | 41 If you need VLAN support in your network, then the 42 :zephyr_file:`samples/net/vlan/vlan-setup-linux.sh` provides a script that can be
|
/Zephyr-latest/samples/net/mdns_responder/ |
D | overlay-vlan.conf | 3 # We have one non-vlan interface and two VLAN interfaces 19 # VLAN tag for the second interface 27 # VLAN tag for the second interface
|
D | Kconfig | 24 int "VLAN tag for second interface" 29 Set VLAN (virtual LAN) tag (id) that is used in the sample 48 int "VLAN tag for third interface" 53 Set VLAN (virtual LAN) tag (id) that is used in the sample
|
/Zephyr-latest/samples/net/sockets/txtime/src/ |
D | vlan.c | 51 LOG_DBG("VLAN interface not set"); in setup_iface() 57 LOG_ERR("Cannot enable VLAN for tag %d (%d)", vlan_tag, ret); in setup_iface() 90 LOG_DBG("Interface %p VLAN tag %d setup done.", iface, vlan_tag); in setup_iface() 114 LOG_DBG("Interface %p does not support %s", iface, "VLAN"); in init_vlan() 134 /* Bring up the VLAN interface automatically */ in init_vlan()
|
/Zephyr-latest/drivers/ethernet/ |
D | Kconfig.xmc4xxx | 40 bool "Hardware filter VLAN frames" 44 Hardware filter VLAN frames in hardware. Only ethernet frames with 46 The filtering can only be done on one vlan tag. If vlan_setup() is
|