Lines Matching refs:netdev

84 	struct net_device *netdev = to_net_dev(dev);  in netdev_store()  local
85 struct net *net = dev_net(netdev); in netdev_store()
99 if (dev_isalive(netdev)) { in netdev_store()
100 if ((ret = (*set)(netdev, new)) == 0) in netdev_store()
185 struct net_device *netdev = to_net_dev(dev); in carrier_show() local
186 if (netif_running(netdev)) { in carrier_show()
187 return sprintf(buf, fmt_dec, !!netif_carrier_ok(netdev)); in carrier_show()
196 struct net_device *netdev = to_net_dev(dev); in speed_show() local
202 if (netif_running(netdev)) { in speed_show()
204 if (!__ethtool_get_settings(netdev, &cmd)) in speed_show()
215 struct net_device *netdev = to_net_dev(dev); in duplex_show() local
221 if (netif_running(netdev)) { in duplex_show()
223 if (!__ethtool_get_settings(netdev, &cmd)) { in duplex_show()
247 struct net_device *netdev = to_net_dev(dev); in dormant_show() local
249 if (netif_running(netdev)) in dormant_show()
250 return sprintf(buf, fmt_dec, !!netif_dormant(netdev)); in dormant_show()
269 const struct net_device *netdev = to_net_dev(dev); in operstate_show() local
273 operstate = netdev->operstate; in operstate_show()
274 if (!netif_running(netdev)) in operstate_show()
289 struct net_device *netdev = to_net_dev(dev); in carrier_changes_show() local
291 atomic_read(&netdev->carrier_changes)); in carrier_changes_show()
358 struct net_device *netdev = to_net_dev(dev); in ifalias_store() local
359 struct net *net = dev_net(netdev); in ifalias_store()
372 ret = dev_set_alias(netdev, buf, count); in ifalias_store()
381 const struct net_device *netdev = to_net_dev(dev); in ifalias_show() local
386 if (netdev->ifalias) in ifalias_show()
387 ret = sprintf(buf, "%s\n", netdev->ifalias); in ifalias_show()
410 struct net_device *netdev = to_net_dev(dev); in phys_port_id_show() local
416 if (dev_isalive(netdev)) { in phys_port_id_show()
419 ret = dev_get_phys_port_id(netdev, &ppid); in phys_port_id_show()
432 struct net_device *netdev = to_net_dev(dev); in phys_port_name_show() local
438 if (dev_isalive(netdev)) { in phys_port_name_show()
441 ret = dev_get_phys_port_name(netdev, name, sizeof(name)); in phys_port_name_show()
454 struct net_device *netdev = to_net_dev(dev); in phys_switch_id_show() local
460 if (dev_isalive(netdev)) { in phys_switch_id_show()
463 ret = netdev_switch_parent_id_get(netdev, &ppid); in phys_switch_id_show()