Home
last modified time | relevance | path

Searched refs:in_dev (Results 1 – 25 of 36) sorted by relevance

12

/linux/include/linux/
H A Dinetdevice.h61 static inline int ipv4_devconf_get(const struct in_device *in_dev, int index) in ipv4_devconf_get() argument
64 return READ_ONCE(in_dev->cnf.data[index]); in ipv4_devconf_get()
67 static inline void ipv4_devconf_set(struct in_device *in_dev, int index, in ipv4_devconf_set() argument
71 set_bit(index, in_dev->cnf.state); in ipv4_devconf_set()
72 WRITE_ONCE(in_dev->cnf.data[index], val); in ipv4_devconf_set()
75 static inline void ipv4_devconf_setall(struct in_device *in_dev) in ipv4_devconf_setall() argument
77 bitmap_fill(in_dev->cnf.state, IPV4_DEVCONF_MAX); in ipv4_devconf_setall()
80 #define IN_DEV_CONF_GET(in_dev, attr) \ argument
81 ipv4_devconf_get((in_dev), IPV4_DEVCONF_ ## attr)
82 #define IN_DEV_CONF_SET(in_dev, attr, val) \ argument
[all …]
H A Digmp.h287 extern void __ip_mc_dec_group(struct in_device *in_dev, __be32 addr, gfp_t gfp);
288 static inline void ip_mc_dec_group(struct in_device *in_dev, __be32 addr) in ip_mc_dec_group() argument
290 return __ip_mc_dec_group(in_dev, addr, GFP_KERNEL); in ip_mc_dec_group()
292 extern void __ip_mc_inc_group(struct in_device *in_dev, __be32 addr,
294 extern void ip_mc_inc_group(struct in_device *in_dev, __be32 addr);
/linux/net/ipv4/
H A Digmp.c125 static bool IGMP_V1_SEEN(const struct in_device *in_dev) in IGMP_V1_SEEN() argument
129 if (IPV4_DEVCONF_ALL_RO(dev_net(in_dev->dev), FORCE_IGMP_VERSION) == 1) in IGMP_V1_SEEN()
131 if (IN_DEV_CONF_GET((in_dev), FORCE_IGMP_VERSION) == 1) in IGMP_V1_SEEN()
133 seen = READ_ONCE(in_dev->mr_v1_seen); in IGMP_V1_SEEN()
137 static bool IGMP_V2_SEEN(const struct in_device *in_dev) in IGMP_V2_SEEN() argument
141 if (IPV4_DEVCONF_ALL_RO(dev_net(in_dev->dev), FORCE_IGMP_VERSION) == 2) in IGMP_V2_SEEN()
143 if (IN_DEV_CONF_GET((in_dev), FORCE_IGMP_VERSION) == 2) in IGMP_V2_SEEN()
145 seen = READ_ONCE(in_dev->mr_v2_seen); in IGMP_V2_SEEN()
149 static int unsolicited_report_interval(struct in_device *in_dev) in unsolicited_report_interval() argument
153 if (IGMP_V1_SEEN(in_dev) || IGMP_V2_SEEN(in_dev)) in unsolicited_report_interval()
[all …]
H A Ddevinet.c190 static void inet_del_ifa(struct in_device *in_dev,
208 static struct in_ifaddr *inet_alloc_ifa(struct in_device *in_dev) in inet_alloc_ifa() argument
216 in_dev_hold(in_dev); in inet_alloc_ifa()
217 ifa->ifa_dev = in_dev; in inet_alloc_ifa()
268 struct in_device *in_dev; in inetdev_init() local
273 in_dev = kzalloc_obj(*in_dev); in inetdev_init()
274 if (!in_dev) in inetdev_init()
276 memcpy(&in_dev->cnf, dev_net(dev)->ipv4.devconf_dflt, in inetdev_init()
277 sizeof(in_dev->cnf)); in inetdev_init()
278 in_dev->cnf.sysctl = NULL; in inetdev_init()
[all …]
H A Darp.c227 struct in_device *in_dev; in arp_constructor() local
236 in_dev = __in_dev_get_rcu(dev); in arp_constructor()
237 if (!in_dev) { in arp_constructor()
244 parms = in_dev->arp_parms; in arp_constructor()
340 struct in_device *in_dev; in arp_solicit() local
344 in_dev = __in_dev_get_rcu(dev); in arp_solicit()
345 if (!in_dev) { in arp_solicit()
349 switch (IN_DEV_ARP_ANNOUNCE(in_dev)) { in arp_solicit()
363 if (inet_addr_onlink(in_dev, target, saddr)) in arp_solicit()
396 static int arp_ignore(struct in_device *in_dev, __be32 sip, __be32 tip) in arp_ignore() argument
[all …]
H A Droute.c779 struct in_device *in_dev; in __ip_do_redirect() local
798 in_dev = __in_dev_get_rcu(dev); in __ip_do_redirect()
799 if (!in_dev) in __ip_do_redirect()
803 if (new_gw == old_gw || !IN_DEV_RX_REDIRECTS(in_dev) || in __ip_do_redirect()
808 if (!IN_DEV_SHARED_MEDIA(in_dev)) { in __ip_do_redirect()
809 if (!inet_addr_onlink(in_dev, new_gw, old_gw)) in __ip_do_redirect()
811 if (IN_DEV_SEC_REDIRECTS(in_dev) && ip_fib_check_default(new_gw, dev)) in __ip_do_redirect()
844 if (IN_DEV_LOG_MARTIANS(in_dev)) { in __ip_do_redirect()
905 struct in_device *in_dev; in ip_rt_send_redirect() local
914 in_dev = __in_dev_get_rcu(dev); in ip_rt_send_redirect()
[all …]
H A Dfib_frontend.c295 struct in_device *in_dev; in fib_compute_spec_dst() local
306 in_dev = __in_dev_get_rcu(dev); in fib_compute_spec_dst()
312 bool vmark = in_dev && IN_DEV_SRC_VMARK(in_dev); in fib_compute_spec_dst()
575 struct in_device *in_dev; in rtentry_to_fib_config() local
577 in_dev = __in_dev_get_rtnl_net(dev); in rtentry_to_fib_config()
578 if (!in_dev) in rtentry_to_fib_config()
583 in_dev_for_each_ifa_rtnl_net(net, ifa, in_dev) { in rtentry_to_fib_config()
1154 struct in_device *in_dev = ifa->ifa_dev; in fib_add_ifaddr() local
1155 struct net_device *dev = in_dev->dev; in fib_add_ifaddr()
1162 prim = inet_ifa_byprefix(in_dev, prefix, mask); in fib_add_ifaddr()
[all …]
H A Dicmp.c662 struct in_device *in_dev; in icmp_ext_iio_addr4_find() local
665 in_dev = __in_dev_get_rcu(dev); in icmp_ext_iio_addr4_find()
666 if (!in_dev) in icmp_ext_iio_addr4_find()
672 in_dev_for_each_ifa_rcu(ifa, in_dev) { in icmp_ext_iio_addr4_find()
1300 struct in_device *in_dev; in icmp_build_probe() local
1385 in_dev = __in_dev_get_rcu(dev); in icmp_build_probe()
1386 if (in_dev && rcu_access_pointer(in_dev->ifa_list)) in icmp_build_probe()
H A Dipmr.c464 struct in_device *in_dev; in ipmr_init_vif_indev() local
468 in_dev = __in_dev_get_rtnl(dev); in ipmr_init_vif_indev()
469 if (!in_dev) in ipmr_init_vif_indev()
471 ipv4_devconf_setall(in_dev); in ipmr_init_vif_indev()
472 neigh_parms_data_state_setall(in_dev->arp_parms); in ipmr_init_vif_indev()
473 IPV4_DEVCONF(in_dev->cnf, RP_FILTER) = 0; in ipmr_init_vif_indev()
693 struct in_device *in_dev; in vif_delete() local
727 in_dev = __in_dev_get_rtnl(dev); in vif_delete()
728 if (in_dev) { in vif_delete()
729 IPV4_DEVCONF(in_dev->cnf, MC_FORWARDING)--; in vif_delete()
[all …]
H A Dfib_semantics.c1268 struct in_device *in_dev; in fib_check_nh_nongw() local
1280 in_dev = inetdev_by_index(net, nh->fib_nh_oif); in fib_check_nh_nongw()
1281 if (!in_dev) in fib_check_nh_nongw()
1284 if (!(in_dev->dev->flags & IFF_UP)) { in fib_check_nh_nongw()
1289 nh->fib_nh_dev = in_dev->dev; in fib_check_nh_nongw()
H A Dip_gre.c975 struct in_device *in_dev; in ipgre_close() local
976 in_dev = inetdev_by_index(t->net, t->mlink); in ipgre_close()
977 if (in_dev) in ipgre_close()
978 ip_mc_dec_group(in_dev, t->parms.iph.daddr); in ipgre_close()
/linux/drivers/input/touchscreen/
H A Dbu21029_ts.c157 struct input_dev *in_dev; member
169 s32 max_pressure = input_abs_get_max(bu21029->in_dev, ABS_PRESSURE); in bu21029_touch_report()
200 touchscreen_report_pos(bu21029->in_dev, &bu21029->prop, in bu21029_touch_report()
202 input_report_abs(bu21029->in_dev, ABS_PRESSURE, in bu21029_touch_report()
204 input_report_key(bu21029->in_dev, BTN_TOUCH, 1); in bu21029_touch_report()
205 input_sync(bu21029->in_dev); in bu21029_touch_report()
215 input_report_abs(bu21029->in_dev, ABS_PRESSURE, 0); in bu21029_touch_release()
216 input_report_key(bu21029->in_dev, BTN_TOUCH, 0); in bu21029_touch_release()
217 input_sync(bu21029->in_dev); in bu21029_touch_release()
339 struct input_dev *in_dev; in bu21029_probe() local
[all …]
H A Dbu21013_ts.c159 struct input_dev *in_dev; member
188 struct input_dev *input = ts->in_dev; in bu21013_do_touch_report()
410 struct input_dev *in_dev; in bu21013_probe() local
436 in_dev = devm_input_allocate_device(dev); in bu21013_probe()
437 if (!in_dev) { in bu21013_probe()
441 ts->in_dev = in_dev; in bu21013_probe()
442 input_set_drvdata(in_dev, ts); in bu21013_probe()
445 in_dev->name = DRIVER_TP; in bu21013_probe()
446 in_dev->id.bustype = BUS_I2C; in bu21013_probe()
451 input_set_abs_params(in_dev, ABS_MT_POSITION_X, 0, max_x, 0, 0); in bu21013_probe()
[all …]
/linux/net/netfilter/
H A Dnf_conntrack_broadcast.c29 struct in_device *in_dev; in nf_conntrack_broadcast_help() local
45 in_dev = __in_dev_get_rcu(rt->dst.dev); in nf_conntrack_broadcast_help()
46 if (in_dev != NULL) { in nf_conntrack_broadcast_help()
49 in_dev_for_each_ifa_rcu(ifa, in_dev) { in nf_conntrack_broadcast_help()
/linux/drivers/net/wan/
H A Dhdlc_cisco.c147 struct in_device *in_dev; in cisco_rx() local
180 in_dev = __in_dev_get_rcu(dev); in cisco_rx()
184 if (in_dev != NULL) { in cisco_rx()
187 in_dev_for_each_ifa_rcu(ifa, in_dev) { in cisco_rx()
/linux/drivers/net/plip/
H A Dplip.c1013 const struct in_device *in_dev; in plip_rewrite_address() local
1016 in_dev = __in_dev_get_rcu(dev); in plip_rewrite_address()
1017 if (in_dev) { in plip_rewrite_address()
1019 const struct in_ifaddr *ifa = rcu_dereference(in_dev->ifa_list); in plip_rewrite_address()
1070 struct in_device *in_dev; in plip_open() local
1109 in_dev=__in_dev_get_rtnl(dev); in plip_open()
1110 if (in_dev) { in plip_open()
1114 const struct in_ifaddr *ifa = rtnl_dereference(in_dev->ifa_list); in plip_open()
/linux/net/bridge/
H A Dbr_arp_nd_proxy.c95 struct in_device *in_dev; in br_chk_addr_ip() local
98 in_dev = __in_dev_get_rcu(dev); in br_chk_addr_ip()
99 if (in_dev) in br_chk_addr_ip()
100 addr = inet_confirm_addr(dev_net(dev), in_dev, 0, ip, in br_chk_addr_ip()
/linux/include/net/
H A Dbonding.h656 struct in_device *in_dev; in bond_confirm_addr() local
660 in_dev = __in_dev_get_rcu(dev); in bond_confirm_addr()
662 if (in_dev) in bond_confirm_addr()
663 addr = inet_confirm_addr(dev_net(dev), in_dev, dst, local, in bond_confirm_addr()
/linux/net/batman-adv/
H A Dmulticast.c112 struct in_device *in_dev = __in_dev_get_rcu(dev); in batadv_mcast_mla_rtr_flags_meshif_get_ipv4() local
114 if (in_dev && IN_DEV_MFORWARD(in_dev)) in batadv_mcast_mla_rtr_flags_meshif_get_ipv4()
372 struct in_device *in_dev; in batadv_mcast_mla_meshif_get_ipv4() local
382 in_dev = __in_dev_get_rcu(dev); in batadv_mcast_mla_meshif_get_ipv4()
383 if (!in_dev) { in batadv_mcast_mla_meshif_get_ipv4()
388 for (pmc = rcu_dereference(in_dev->mc_list); pmc; in batadv_mcast_mla_meshif_get_ipv4()
/linux/drivers/infiniband/core/
H A Droce_gid_mgmt.c335 struct in_device *in_dev; in enum_netdev_ipv4_ips() local
348 in_dev = __in_dev_get_rcu(ndev); in enum_netdev_ipv4_ips()
349 if (!in_dev) { in enum_netdev_ipv4_ips()
354 in_dev_for_each_ifa_rcu(ifa, in_dev) { in enum_netdev_ipv4_ips()
/linux/drivers/net/ethernet/via/
H A Dvia-velocity.h1461 struct in_device *in_dev; in velocity_get_ip() local
1466 in_dev = __in_dev_get_rcu(vptr->netdev); in velocity_get_ip()
1467 if (in_dev != NULL) { in velocity_get_ip()
1468 ifa = rcu_dereference(in_dev->ifa_list); in velocity_get_ip()
/linux/net/smc/
H A Dsmc_clc.c515 struct in_device *in_dev = __in_dev_get_rcu(dev); in smc_clc_prfx_set4_rcu() local
518 if (!in_dev) in smc_clc_prfx_set4_rcu()
521 in_dev_for_each_ifa_rcu(ifa, in_dev) { in smc_clc_prfx_set4_rcu()
613 struct in_device *in_dev = __in_dev_get_rcu(dev); in smc_clc_prfx_match4_rcu() local
616 if (!in_dev) in smc_clc_prfx_match4_rcu()
618 in_dev_for_each_ifa_rcu(ifa, in_dev) { in smc_clc_prfx_match4_rcu()
H A Dsmc_ib.c242 struct in_device *in_dev = __in_dev_get_rcu(ndev); in smc_ib_determine_gid_rcu() local
247 if (!in_dev) in smc_ib_determine_gid_rcu()
249 in_dev_for_each_ifa_rcu(ifa, in_dev) { in smc_ib_determine_gid_rcu()
/linux/net/sctp/
H A Dprotocol.c77 struct in_device *in_dev; in sctp_v4_copy_addrlist() local
82 if ((in_dev = __in_dev_get_rcu(dev)) == NULL) { in sctp_v4_copy_addrlist()
87 in_dev_for_each_ifa_rcu(ifa, in_dev) { in sctp_v4_copy_addrlist()
/linux/drivers/net/
H A Dnetconsole.c455 struct in_device *in_dev; in netcons_take_ipv4() local
457 in_dev = __in_dev_get_rtnl(ndev); in netcons_take_ipv4()
458 if (!in_dev) { in netcons_take_ipv4()
464 ifa = rtnl_dereference(in_dev->ifa_list); in netcons_take_ipv4()

12