Home
last modified time | relevance | path

Searched refs:ifr (Results 1 – 15 of 15) sorted by relevance

/net/core/
Ddev.c2801 struct ifreq ifr; in dev_ifname() local
2807 if (copy_from_user(&ifr, arg, sizeof(struct ifreq))) in dev_ifname()
2811 dev = __dev_get_by_index(net, ifr.ifr_ifindex); in dev_ifname()
2817 strcpy(ifr.ifr_name, dev->name); in dev_ifname()
2820 if (copy_to_user(arg, &ifr, sizeof(struct ifreq))) in dev_ifname()
3795 static int dev_ifsioc_locked(struct net *net, struct ifreq *ifr, unsigned int cmd) in dev_ifsioc_locked() argument
3798 struct net_device *dev = __dev_get_by_name(net, ifr->ifr_name); in dev_ifsioc_locked()
3805 ifr->ifr_flags = dev_get_flags(dev); in dev_ifsioc_locked()
3810 ifr->ifr_metric = 0; in dev_ifsioc_locked()
3814 ifr->ifr_mtu = dev->mtu; in dev_ifsioc_locked()
[all …]
Dethtool.c869 int dev_ethtool(struct net *net, struct ifreq *ifr) in dev_ethtool() argument
871 struct net_device *dev = __dev_get_by_name(net, ifr->ifr_name); in dev_ethtool()
872 void __user *useraddr = ifr->ifr_data; in dev_ethtool()
/net/ipv4/
Ddevinet.c584 struct ifreq ifr; in devinet_ioctl() local
586 struct sockaddr_in *sin = (struct sockaddr_in *)&ifr.ifr_addr; in devinet_ioctl()
599 if (copy_from_user(&ifr, arg, sizeof(struct ifreq))) in devinet_ioctl()
601 ifr.ifr_name[IFNAMSIZ - 1] = 0; in devinet_ioctl()
606 colon = strchr(ifr.ifr_name, ':'); in devinet_ioctl()
610 dev_load(net, ifr.ifr_name); in devinet_ioctl()
651 if ((dev = __dev_get_by_name(net, ifr.ifr_name)) == NULL) in devinet_ioctl()
666 if (!strcmp(ifr.ifr_name, ifa->ifa_label) && in devinet_ioctl()
679 if (!strcmp(ifr.ifr_name, ifa->ifa_label)) in devinet_ioctl()
712 if (!(ifr.ifr_flags & IFF_UP)) in devinet_ioctl()
[all …]
Dipip.c573 ipip_tunnel_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) in ipip_tunnel_ioctl() argument
585 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) { in ipip_tunnel_ioctl()
594 if (copy_to_user(ifr->ifr_ifru.ifru_data, &p, sizeof(p))) in ipip_tunnel_ioctl()
605 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipip_tunnel_ioctl()
652 if (copy_to_user(ifr->ifr_ifru.ifru_data, &t->parms, sizeof(p))) in ipip_tunnel_ioctl()
665 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipip_tunnel_ioctl()
Dipmr.c128 struct ifreq ifr; in ipmr_del_tunnel() local
138 ifr.ifr_ifru.ifru_data = (__force void __user *)&p; in ipmr_del_tunnel()
144 ops->ndo_do_ioctl(dev, &ifr, SIOCDELTUNNEL); in ipmr_del_tunnel()
160 struct ifreq ifr; in ipmr_new_tunnel() local
171 ifr.ifr_ifru.ifru_data = (__force void __user *)&p; in ipmr_new_tunnel()
177 err = ops->ndo_do_ioctl(dev, &ifr, SIOCADDTUNNEL); in ipmr_new_tunnel()
Dip_gre.c906 ipgre_tunnel_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) in ipgre_tunnel_ioctl() argument
918 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) { in ipgre_tunnel_ioctl()
927 if (copy_to_user(ifr->ifr_ifru.ifru_data, &p, sizeof(p))) in ipgre_tunnel_ioctl()
938 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipgre_tunnel_ioctl()
1000 if (copy_to_user(ifr->ifr_ifru.ifru_data, &t->parms, sizeof(p))) in ipgre_tunnel_ioctl()
1013 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipgre_tunnel_ioctl()
/net/wireless/
Dwext.c1016 static int wireless_process_ioctl(struct net *net, struct ifreq *ifr, in wireless_process_ioctl() argument
1022 struct iwreq *iwr = (struct iwreq *) ifr; in wireless_process_ioctl()
1030 if ((dev = __dev_get_by_name(net, ifr->ifr_name)) == NULL) in wireless_process_ioctl()
1059 return dev->netdev_ops->ndo_do_ioctl(dev, ifr, cmd); in wireless_process_ioctl()
1076 static int wext_ioctl_dispatch(struct net *net, struct ifreq *ifr, in wext_ioctl_dispatch() argument
1086 dev_load(net, ifr->ifr_name); in wext_ioctl_dispatch()
1088 ret = wireless_process_ioctl(net, ifr, cmd, info, standard, private); in wext_ioctl_dispatch()
1094 int wext_handle_ioctl(struct net *net, struct ifreq *ifr, unsigned int cmd, in wext_handle_ioctl() argument
1100 ret = wext_ioctl_dispatch(net, ifr, cmd, &info, in wext_handle_ioctl()
1105 copy_to_user(arg, ifr, sizeof(struct iwreq))) in wext_handle_ioctl()
/net/ipv6/
Dsit.c770 ipip6_tunnel_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) in ipip6_tunnel_ioctl() argument
783 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) { in ipip6_tunnel_ioctl()
792 if (copy_to_user(ifr->ifr_ifru.ifru_data, &p, sizeof(p))) in ipip6_tunnel_ioctl()
803 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipip6_tunnel_ioctl()
849 if (copy_to_user(ifr->ifr_ifru.ifru_data, &t->parms, sizeof(p))) in ipip6_tunnel_ioctl()
862 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof(p))) in ipip6_tunnel_ioctl()
883 err = ipip6_tunnel_get_prl(t, ifr->ifr_ifru.ifru_data); in ipip6_tunnel_ioctl()
896 if (copy_from_user(&prl, ifr->ifr_ifru.ifru_data, sizeof(prl))) in ipip6_tunnel_ioctl()
Dip6_tunnel.c1204 ip6_tnl_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) in ip6_tnl_ioctl() argument
1215 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof (p))) { in ip6_tnl_ioctl()
1224 if (copy_to_user(ifr->ifr_ifru.ifru_data, &p, sizeof (p))) { in ip6_tnl_ioctl()
1234 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof (p))) in ip6_tnl_ioctl()
1257 if (copy_to_user(ifr->ifr_ifru.ifru_data, &t->parms, sizeof (p))) in ip6_tnl_ioctl()
1270 if (copy_from_user(&p, ifr->ifr_ifru.ifru_data, sizeof (p))) in ip6_tnl_ioctl()
Daddrconf.c2038 struct ifreq ifr; in addrconf_set_dstaddr() local
2052 ifr.ifr_ifru.ifru_data = (__force void __user *)&p; in addrconf_set_dstaddr()
2058 err = ops->ndo_do_ioctl(dev, &ifr, SIOCADDTUNNEL); in addrconf_set_dstaddr()
/net/ipx/
Daf_ipx.c1146 struct ifreq ifr; in ipxitf_ioctl() local
1155 if (copy_from_user(&ifr, arg, sizeof(ifr))) in ipxitf_ioctl()
1157 sipx = (struct sockaddr_ipx *)&ifr.ifr_addr; in ipxitf_ioctl()
1162 memcpy(f.ipx_device, ifr.ifr_name, in ipxitf_ioctl()
1180 if (copy_from_user(&ifr, arg, sizeof(ifr))) in ipxitf_ioctl()
1182 sipx = (struct sockaddr_ipx *)&ifr.ifr_addr; in ipxitf_ioctl()
1183 dev = __dev_get_by_name(&init_net, ifr.ifr_name); in ipxitf_ioctl()
1198 if (copy_to_user(arg, &ifr, sizeof(ifr))) in ipxitf_ioctl()
/net/decnet/
Ddn_dev.c482 struct ifreq *ifr = (struct ifreq *)buffer; in dn_dev_ioctl() local
483 struct sockaddr_dn *sdn = (struct sockaddr_dn *)&ifr->ifr_addr; in dn_dev_ioctl()
489 if (copy_from_user(ifr, arg, DN_IFREQ_SIZE)) in dn_dev_ioctl()
491 ifr->ifr_name[IFNAMSIZ-1] = 0; in dn_dev_ioctl()
493 dev_load(&init_net, ifr->ifr_name); in dn_dev_ioctl()
510 if ((dev = __dev_get_by_name(&init_net, ifr->ifr_name)) == NULL) { in dn_dev_ioctl()
517 if (strcmp(ifr->ifr_name, ifa->ifa_label) == 0) in dn_dev_ioctl()
553 if (copy_to_user(arg, ifr, DN_IFREQ_SIZE)) in dn_dev_ioctl()
/net/econet/
Daf_econet.c650 struct ifreq ifr; in ec_dev_ioctl() local
660 if (copy_from_user(&ifr, arg, sizeof(struct ifreq))) in ec_dev_ioctl()
663 if ((dev = dev_get_by_name(&init_net, ifr.ifr_name)) == NULL) in ec_dev_ioctl()
666 sec = (struct sockaddr_ec *)&ifr.ifr_addr; in ec_dev_ioctl()
702 if (copy_to_user(arg, &ifr, sizeof(struct ifreq))) in ec_dev_ioctl()
/net/dsa/
Dslave.c155 static int dsa_slave_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) in dsa_slave_ioctl() argument
158 struct mii_ioctl_data *mii_data = if_mii(ifr); in dsa_slave_ioctl()
/net/8021q/
Dvlan_dev.c524 static int vlan_dev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) in vlan_dev_ioctl() argument
532 ifrr.ifr_ifru = ifr->ifr_ifru; in vlan_dev_ioctl()
544 ifr->ifr_ifru = ifrr.ifr_ifru; in vlan_dev_ioctl()