File tree Expand file tree Collapse file tree 4 files changed +20
-0
lines changed Expand file tree Collapse file tree 4 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -105,6 +105,11 @@ int init_vlan(void)
105105 struct ud user_data ;
106106 int ret ;
107107
108+ if (CONFIG_NET_VLAN_COUNT == 0 ) {
109+ LOG_DBG ("No VLAN interfaces defined." );
110+ return 0 ;
111+ }
112+
108113 iface = net_if_get_first_by_type (& NET_L2_GET_NAME (ETHERNET ));
109114 if (!iface ) {
110115 LOG_ERR ("No ethernet interfaces found." );
Original file line number Diff line number Diff line change @@ -85,6 +85,11 @@ int init_vlan(void)
8585 struct ud ud ;
8686 int ret ;
8787
88+ if (CONFIG_NET_VLAN_COUNT == 0 ) {
89+ LOG_DBG ("No VLAN interfaces defined." );
90+ return 0 ;
91+ }
92+
8893 iface = net_if_get_first_by_type (& NET_L2_GET_NAME (ETHERNET ));
8994 if (!iface ) {
9095 LOG_ERR ("No ethernet interfaces found." );
Original file line number Diff line number Diff line change @@ -107,6 +107,11 @@ int init_vlan(void)
107107 struct ud ud ;
108108 int ret ;
109109
110+ if (CONFIG_NET_VLAN_COUNT == 0 ) {
111+ LOG_DBG ("No VLAN interfaces defined." );
112+ return 0 ;
113+ }
114+
110115 memset (& ud , 0 , sizeof (ud ));
111116
112117 net_if_foreach (iface_cb , & ud );
Original file line number Diff line number Diff line change @@ -99,6 +99,11 @@ int init_vlan(void)
9999 struct ud ud ;
100100 int ret ;
101101
102+ if (CONFIG_NET_VLAN_COUNT == 0 ) {
103+ LOG_DBG ("No VLAN interfaces defined." );
104+ return 0 ;
105+ }
106+
102107 iface = net_if_get_first_by_type (& NET_L2_GET_NAME (ETHERNET ));
103108 if (!iface ) {
104109 LOG_ERR ("No ethernet interfaces found." );
You can’t perform that action at this time.
0 commit comments