Skip to content
Navigation Menu
Toggle navigation
Sign in
In this repository
All GitHub Enterprise
↵
Jump to
↵
No suggested jump to results
In this repository
All GitHub Enterprise
↵
Jump to
↵
In this organization
All GitHub Enterprise
↵
Jump to
↵
In this repository
All GitHub Enterprise
↵
Jump to
↵
Sign in
Reseting focus
You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
Dismiss alert
{{ message }}
mariux64
/
linux
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Issues
2
Pull requests
0
Actions
Projects
0
Wiki
Security
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security
Insights
Files
cf5c15d
Breadcrumbs
linux
/
drivers
/
net
/
ethernet
/
intel
/
ice
/
ice_xsk.h
Copy path
Blame
Blame
Latest commit
History
History
84 lines (72 loc) · 2.18 KB
Breadcrumbs
linux
/
drivers
/
net
/
ethernet
/
intel
/
ice
/
ice_xsk.h
Top
File metadata and controls
Code
Blame
84 lines (72 loc) · 2.18 KB
Raw
/* SPDX-License-Identifier: GPL-2.0 */ /* Copyright (c) 2019, Intel Corporation. */ #ifndef _ICE_XSK_H_ #define _ICE_XSK_H_ #include "ice_txrx.h" #define PKTS_PER_BATCH 8 #ifdef __clang__ #define loop_unrolled_for _Pragma("clang loop unroll_count(8)") for #elif __GNUC__ >= 8 #define loop_unrolled_for _Pragma("GCC unroll 8") for #else #define loop_unrolled_for for #endif struct ice_vsi; #ifdef CONFIG_XDP_SOCKETS int ice_xsk_pool_setup(struct ice_vsi *vsi, struct xsk_buff_pool *pool, u16 qid); int ice_clean_rx_irq_zc(struct ice_rx_ring *rx_ring, int budget); int ice_xsk_wakeup(struct net_device *netdev, u32 queue_id, u32 flags); bool ice_alloc_rx_bufs_zc(struct ice_rx_ring *rx_ring, u16 count); bool ice_xsk_any_rx_ring_ena(struct ice_vsi *vsi); void ice_xsk_clean_rx_ring(struct ice_rx_ring *rx_ring); void ice_xsk_clean_xdp_ring(struct ice_tx_ring *xdp_ring); bool ice_xmit_zc(struct ice_tx_ring *xdp_ring, u32 budget, int napi_budget); int ice_realloc_zc_buf(struct ice_vsi *vsi, bool zc); #else static inline bool ice_xmit_zc(struct ice_tx_ring __always_unused *xdp_ring, u32 __always_unused budget, int __always_unused napi_budget) { return false; } static inline int ice_xsk_pool_setup(struct ice_vsi __always_unused *vsi, struct xsk_buff_pool __always_unused *pool, u16 __always_unused qid) { return -EOPNOTSUPP; } static inline int ice_clean_rx_irq_zc(struct ice_rx_ring __always_unused *rx_ring, int __always_unused budget) { return 0; } static inline bool ice_alloc_rx_bufs_zc(struct ice_rx_ring __always_unused *rx_ring, u16 __always_unused count) { return false; } static inline bool ice_xsk_any_rx_ring_ena(struct ice_vsi __always_unused *vsi) { return false; } static inline int ice_xsk_wakeup(struct net_device __always_unused *netdev, u32 __always_unused queue_id, u32 __always_unused flags) { return -EOPNOTSUPP; } static inline void ice_xsk_clean_rx_ring(struct ice_rx_ring *rx_ring) { } static inline void ice_xsk_clean_xdp_ring(struct ice_tx_ring *xdp_ring) { } static inline int ice_realloc_zc_buf(struct ice_vsi __always_unused *vsi, bool __always_unused zc) { return 0; } #endif /* CONFIG_XDP_SOCKETS */ #endif /* !_ICE_XSK_H_ */
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
You can’t perform that action at this time.