This is an automated email from the ASF dual-hosted git repository. GUIDINGLI pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
commit a61e2c2af9aedd91c1c7b234d14b1c98c1beaea7 Author: zhanghongyu <[email protected]> AuthorDate: Wed Sep 24 19:49:43 2025 +0800 vlan: vlan device inherit the mode of real net device A VLAN device is a logical device layered on top of a real network device. Inherit the operating mode (rxtype) from the real device when the VLAN device is created so the two stay consistent instead of the VLAN device defaulting to a different mode. Signed-off-by: zhanghongyu <[email protected]> --- drivers/net/vlan.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/vlan.c b/drivers/net/vlan.c index 52c720174d9..68450e14028 100644 --- a/drivers/net/vlan.c +++ b/drivers/net/vlan.c @@ -310,6 +310,8 @@ int vlan_register(FAR struct netdev_lowerhalf_s *real, uint16_t vid, ((prio << VLAN_PRIO_SHIFT) & VLAN_PRIO_MASK); vlan->real = real; vlan->dev.quota_ptr = real->quota_ptr; + vlan->dev.rxtype = real->rxtype; + vlan->dev.priority = real->priority; vlan->dev.ops = &g_vlan_ops; /* Set the VLAN device name, use a buffer to make compiler happy */
