Searched refs:ifindex (Results 26 - 50 of 433) sorted by relevance

1234567891011>>

/linux-master/tools/testing/selftests/bpf/progs/
H A Dtest_skb_ctx.c31 if (skb->ifindex != 1)
H A Dtype_cast.c18 int ifindex, ingress_ifindex; variable
30 ifindex = dev->ifindex;
H A Dtest_global_func6.c25 return skb->ifindex * val;
H A Dtest_global_func5.c25 return skb->ifindex * val;
/linux-master/net/dsa/
H A Dnetlink.c24 u32 ifindex = nla_get_u32(data[IFLA_DSA_CONDUIT]); local
27 conduit = __dev_get_by_index(dev_net(dev), ifindex);
49 if (nla_put_u32(skb, IFLA_DSA_CONDUIT, conduit->ifindex))
/linux-master/drivers/net/ethernet/mellanox/mlx5/core/en/tc/
H A Dint_port.c13 int ifindex; member in struct:mlx5e_tc_int_port
106 int ifindex,
115 if (int_port->ifindex == ifindex && int_port->type == type) {
125 int ifindex, enum mlx5e_tc_int_port_type type,
128 u32 mapped_key[2] = {type, ifindex};
151 int ifindex,
174 err = mlx5e_int_port_metadata_alloc(priv, ifindex, type, &match_metadata);
176 mlx5_core_warn(esw->dev, "Cannot add a new internal port, metadata allocation failed for ifindex %d",
177 ifindex);
105 mlx5e_int_port_lookup(struct mlx5e_tc_int_port_priv *priv, int ifindex, enum mlx5e_tc_int_port_type type) argument
124 mlx5e_int_port_metadata_alloc(struct mlx5e_tc_int_port_priv *priv, int ifindex, enum mlx5e_tc_int_port_type type, u32 *id) argument
150 mlx5e_int_port_add(struct mlx5e_tc_int_port_priv *priv, int ifindex, enum mlx5e_tc_int_port_type type) argument
264 mlx5e_tc_int_port_get(struct mlx5e_tc_int_port_priv *priv, int ifindex, enum mlx5e_tc_int_port_type type) argument
416 int ifindex; local
[all...]
/linux-master/tools/lib/bpf/
H A Dnetlink.c40 int ifindex; member in struct:xdp_id_md
47 int ifindex; member in struct:xdp_features_md
286 static int __bpf_set_link_xdp_fd_replace(int ifindex, int fd, int old_fd, argument
298 req.ifinfo.ifi_index = ifindex;
322 int bpf_xdp_attach(int ifindex, int prog_fd, __u32 flags, const struct bpf_xdp_attach_opts *opts) argument
335 err = __bpf_set_link_xdp_fd_replace(ifindex, prog_fd, old_prog_fd, flags);
339 int bpf_xdp_detach(int ifindex, __u32 flags, const struct bpf_xdp_attach_opts *opts) argument
341 return bpf_xdp_attach(ifindex, -1, flags, opts);
367 if (xdp_id->ifindex && xdp_id->ifindex !
412 __u32 ifindex; local
431 bpf_xdp_query(int ifindex, int xdp_flags, struct bpf_xdp_query_opts *opts) argument
506 bpf_xdp_query_id(int ifindex, int flags, __u32 *prog_id) argument
721 int ret, ifindex, attach_point, prog_fd; local
797 int ret, ifindex, attach_point, prog_fd; local
868 int ret, ifindex, attach_point, prog_fd; local
[all...]
/linux-master/tools/testing/selftests/bpf/
H A Dxdp_synproxy.c19 static unsigned int ifindex; variable
34 .ifindex = ifindex,
49 err = bpf_xdp_attach(ifindex, -1, 0, NULL);
57 err = bpf_xdp_attach(ifindex, -1, XDP_FLAGS_REPLACE, &opts);
91 static void parse_options(int argc, char *argv[], unsigned int *ifindex, __u32 *prog_id, argument
114 *ifindex = 0;
133 *ifindex = if_nametoindex(optarg);
134 if (*ifindex == 0)
182 if (*ifindex !
188 syncookie_attach(const char *argv0, unsigned int ifindex, bool tc) argument
[all...]
H A Dxdping.c26 static int ifindex; variable
31 bpf_xdp_detach(ifindex, xdp_flags, NULL);
119 ifindex = if_nametoindex(ifname);
120 if (!ifindex) {
202 if (bpf_xdp_attach(ifindex, prog_fd, xdp_flags, NULL) < 0) {
/linux-master/samples/bpf/
H A Dxdp_sample.bpf.c100 return xdp_redirect_collect_stat(dev->ifindex, err);
108 return xdp_redirect_collect_stat(dev->ifindex, err);
116 return xdp_redirect_collect_stat(dev->ifindex, err);
124 return xdp_redirect_collect_stat(dev->ifindex, err);
188 if (!IN_SET(from_match, dev->ifindex))
190 if (!IN_SET(to_match, dev->ifindex))
213 idx_in = from_dev->ifindex;
214 idx_out = to_dev->ifindex;
245 idx_in = from_dev->ifindex;
246 idx_out = to_dev->ifindex;
[all...]
H A Dxdp_tx_iptunnel_user.c24 static int ifindex = -1; variable
33 if (ifindex > -1) {
34 if (bpf_xdp_query_id(ifindex, xdp_flags, &curr_prog_id)) {
39 bpf_xdp_detach(ifindex, xdp_flags, NULL);
86 printf(" -i <ifname|ifindex> Interface\n");
181 ifindex = if_nametoindex(optarg);
182 if (!ifindex)
183 ifindex = atoi(optarg);
253 if (!ifindex) {
293 if (bpf_xdp_attach(ifindex, prog_f
[all...]
H A Dtcbpf1_kern.c72 return bpf_redirect(skb->ifindex + 1, 0);
77 return bpf_redirect(skb->ifindex + 1, 1);
82 bpf_clone_redirect(skb, skb->ifindex + 1, 0);
88 bpf_clone_redirect(skb, skb->ifindex + 1, 1);
H A Dtest_lwt_bpf.c41 printk("cb %d ingress_ifindex %d ifindex %d", skb->cb[0],
42 skb->ingress_ifindex, skb->ifindex);
163 int ret, ifindex = DST_IFINDEX; local
181 return bpf_redirect(ifindex, 0);
193 int ret, ifindex = DST_IFINDEX; local
197 printk("redirected to %d", ifindex);
231 int ifindex = DST_IFINDEX; local
233 printk("redirected to %d", ifindex);
234 return bpf_redirect(ifindex, 0);
/linux-master/drivers/net/netdevsim/
H A Dhwstats.c57 int ifindex)
62 if (hwsdev->netdev->ifindex == ifindex)
121 hwsdev = nsim_dev_hwslist_find_hwsdev(hwsdev_list, dev->ifindex);
163 hwsdev = nsim_dev_hwslist_find_hwsdev(hwsdev_list, dev->ifindex);
216 int ifindex,
232 hwsdev = nsim_dev_hwslist_find_hwsdev(hwsdev_list, ifindex);
236 netdev = dev_get_by_index(net, ifindex);
272 int ifindex,
281 hwsdev = nsim_dev_hwslist_find_hwsdev(hwsdev_list, ifindex);
56 nsim_dev_hwslist_find_hwsdev(struct list_head *hwsdev_list, int ifindex) argument
215 nsim_dev_hwstats_enable_ifindex(struct nsim_dev_hwstats *hwstats, int ifindex, enum netdev_offload_xstats_type type, struct list_head *hwsdev_list) argument
271 nsim_dev_hwstats_disable_ifindex(struct nsim_dev_hwstats *hwstats, int ifindex, enum netdev_offload_xstats_type type, struct list_head *hwsdev_list) argument
304 nsim_dev_hwstats_fail_ifindex(struct nsim_dev_hwstats *hwstats, int ifindex, enum netdev_offload_xstats_type type, struct list_head *hwsdev_list) argument
347 int ifindex; local
[all...]
/linux-master/net/can/
H A Dbcm.c106 int ifindex; member in struct:bcm_op
130 int ifindex; member in struct:bcm_sock
187 static char *bcm_proc_getifname(struct net *net, char *result, int ifindex) argument
191 if (!ifindex)
195 dev = dev_get_by_index_rcu(net, ifindex);
217 seq_printf(m, " / bound %s", bcm_proc_getifname(net, ifname, bo->ifindex));
229 bcm_proc_getifname(net, ifname, op->ifindex));
258 bcm_proc_getifname(net, ifname, op->ifindex));
292 if (!op->ifindex)
295 dev = dev_get_by_index(sock_net(op->sk), op->ifindex);
756 bcm_find_op(struct list_head *ops, struct bcm_msg_head *mh, int ifindex) argument
807 bcm_delete_rx_op(struct list_head *ops, struct bcm_msg_head *mh, int ifindex) argument
858 bcm_delete_tx_op(struct list_head *ops, struct bcm_msg_head *mh, int ifindex) argument
878 bcm_read_op(struct list_head *ops, struct bcm_msg_head *msg_head, int ifindex) argument
901 bcm_tx_setup(struct bcm_msg_head *msg_head, struct msghdr *msg, int ifindex, struct sock *sk) argument
1080 bcm_rx_setup(struct bcm_msg_head *msg_head, struct msghdr *msg, int ifindex, struct sock *sk) argument
1291 bcm_tx_send(struct msghdr *msg, int ifindex, struct sock *sk, int cfsiz) argument
1340 int ifindex = bo->ifindex; /* default ifindex for this bcm_op */ local
[all...]
/linux-master/net/core/
H A Dnetdev-genl.c18 unsigned long ifindex; member in struct:netdev_nl_dump_ctx
56 if (nla_put_u32(rsp, NETDEV_A_DEV_IFINDEX, netdev->ifindex) ||
109 u32 ifindex; local
115 ifindex = nla_get_u32(info->attrs[NETDEV_A_DEV_IFINDEX]);
123 netdev = __dev_get_by_index(genl_info_net(info), ifindex);
149 for_each_netdev_dump(net, netdev, ctx->ifindex) {
179 if (nla_put_u32(rsp, NETDEV_A_NAPI_IFINDEX, napi->dev->ifindex))
265 u32 ifindex = 0; local
269 ifindex = nla_get_u32(info->attrs[NETDEV_A_NAPI_IFINDEX]);
272 if (ifindex) {
364 u32 q_id, q_type, ifindex; local
437 u32 ifindex = 0; local
[all...]
/linux-master/drivers/staging/gdm724x/
H A Dnetlink_k.c35 int ifindex; local
55 memcpy(&ifindex, ND_NLMSG_IFIDX(nlh), ND_IFINDEX_LEN);
59 dev = dev_get_by_index(&init_net, ifindex);
64 pr_err("nl cb - dev (%d) not found\n", ifindex);
/linux-master/tools/bpf/bpftool/
H A Dnet.c33 int ifindex; member in struct:ip_devname_ifindex
58 int ifindex; member in struct:bpf_filter_t
222 static int netlink_get_class(int sock, unsigned int nl_pid, int ifindex, argument
233 .t.tcm_ifindex = ifindex,
261 static int netlink_get_qdisc(int sock, unsigned int nl_pid, int ifindex, argument
272 .t.tcm_ifindex = ifindex,
300 static int netlink_get_filter(int sock, unsigned int nl_pid, int ifindex, int handle, argument
311 .t.tcm_ifindex = ifindex,
378 netinfo->devices[netinfo->used_len].ifindex = ifinfo->ifi_index;
429 filter_info->devname, filter_info->ifindex);
615 int ifindex; local
633 do_attach_detach_xdp(int progfd, enum net_attach_type attach_type, int ifindex, bool overwrite) argument
653 int progfd, ifindex, err = 0; local
707 int progfd, ifindex, err = 0; local
[all...]
/linux-master/include/uapi/linux/
H A Dxdp_diag.h52 __u32 ifindex; member in struct:xdp_diag_info
68 __u32 ifindex; member in struct:xdp_diag_umem
/linux-master/include/net/caif/
H A Dcaif_dev.h33 * @ifindex: kernel index of the interface.
44 int ifindex; member in struct:caif_connect_request
55 * @ifindex: Link layer interface index used for this connection.
69 struct cflayer *client_layer, int *ifindex,
/linux-master/drivers/net/can/dev/
H A Dskb.c222 can_skb_prv(skb)->ifindex = dev->ifindex;
245 can_skb_prv(skb)->ifindex = dev->ifindex;
272 can_skb_prv(skb)->ifindex = dev->ifindex;
314 can_skb_prv(skb)->ifindex = dev->ifindex;
/linux-master/include/trace/events/
H A Dqdisc.h26 __field( int, ifindex )
38 __entry->ifindex = txq->dev ? txq->dev->ifindex : 0;
44 TP_printk("dequeue ifindex=%d qdisc handle=0x%X parent=0x%X txq_state=0x%lX packets=%d skbaddr=%p",
45 __entry->ifindex, __entry->handle, __entry->parent,
59 __field(int, ifindex)
68 __entry->ifindex = txq->dev ? txq->dev->ifindex : 0;
73 TP_printk("enqueue ifindex=%d qdisc handle=0x%X parent=0x%X skbaddr=%p",
74 __entry->ifindex, __entr
[all...]
/linux-master/tools/testing/selftests/bpf/prog_tests/
H A Dxdp_devmap_attach.c17 .ifindex = IFINDEX_LO,
55 val.ifindex = 1;
64 val.ifindex = 1;
79 "Load of XDP program accessing egress ifindex without attach type")) {
89 .ifindex = IFINDEX_LO,
118 val.ifindex = 1;
/linux-master/tools/net/ynl/samples/
H A Dpage-pool.c29 static struct stat *find_ifc(struct stats_array *a, unsigned int ifindex) argument
34 if (a->s[i].ifc == ifindex)
43 a->s[i].ifc = ifindex;
81 struct stat *s = find_ifc(&a, pp->ifindex);
94 struct stat *s = find_ifc(&a, pp->info.ifindex);
/linux-master/net/netfilter/
H A Dnf_nat_masquerade.c17 int ifindex; member in struct:masq_dev_work
62 nat->masq_index = out->ifindex;
102 int ifindex,
124 w->ifindex = ifindex;
146 return nat->masq_index == w->ifindex;
162 nf_nat_masq_schedule(net, NULL, dev->ifindex,
208 nf_nat_masq_schedule(dev_net(idev->dev), &addr, dev->ifindex,
260 nat->masq_index = out->ifindex;
295 nf_nat_masq_schedule(dev_net(dev), &addr, dev->ifindex, inet_cm
101 nf_nat_masq_schedule(struct net *net, union nf_inet_addr *addr, int ifindex, int (*iter)(struct nf_conn *i, void *data), gfp_t gfp_flags) argument
[all...]

Completed in 279 milliseconds

1234567891011>>