ethdev: change promiscuous callbacks to return status
[dpdk.git] / drivers / net / nfb / nfb_rxmode.h
1 /* SPDX-License-Identifier: BSD-3-Clause
2  * Copyright(c) 2019 Cesnet
3  * Copyright(c) 2019 Netcope Technologies, a.s. <info@netcope.com>
4  * All rights reserved.
5  */
6
7 #ifndef _NFB_RXMODE_H_
8 #define _NFB_RXMODE_H_
9
10 #include <nfb/nfb.h>
11 #include <nfb/ndp.h>
12
13 #include <rte_ethdev.h>
14
15 /**
16  * Getter for promiscuous mode
17  * @param dev
18  *   Pointer to Ethernet device structure.
19  * @return 1 if enabled 0 otherwise
20  */
21 int
22 nfb_eth_promiscuous_get(struct rte_eth_dev *dev);
23
24 /**
25  * DPDK callback to enable promiscuous mode.
26  *
27  * @param dev
28  *   Pointer to Ethernet device structure.
29  *
30  * @return always 0
31  */
32 int
33 nfb_eth_promiscuous_enable(struct rte_eth_dev *dev);
34
35 /**
36  * DPDK callback to disable promiscuous mode.
37  *
38  * @param dev
39  *   Pointer to Ethernet device structure.
40  *
41  * @return always 0
42  */
43 int
44 nfb_eth_promiscuous_disable(struct rte_eth_dev *dev);
45
46 /**
47  * Getter for allmulticast mode
48  * @param dev
49  *   Pointer to Ethernet device structure.
50  * @return 1 if enabled 0 otherwise
51  */
52 int
53 nfb_eth_allmulticast_get(struct rte_eth_dev *dev);
54
55 /**
56  * DPDK callback to enable allmulticast mode.
57  *
58  * @param dev
59  *   Pointer to Ethernet device structure.
60  */
61 void
62 nfb_eth_allmulticast_enable(struct rte_eth_dev *dev);
63
64 /**
65  * DPDK callback to disable allmulticast mode.
66  *
67  * @param dev
68  *   Pointer to Ethernet device structure.
69  */
70 void
71 nfb_eth_allmulticast_disable(struct rte_eth_dev *dev);
72
73 #endif /* _NFB_RXMODE_H_ */