Skip to content

Commit 7931a29

Browse files
committed
libxdp: Add comments for struct xsk_umem_opts
Signed-off-by: Muyang Tian <[email protected]>
1 parent 5726ebe commit 7931a29

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

headers/xdp/xsk.h

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,20 @@ struct xsk_umem_config {
204204
__u32 tx_metadata_len;
205205
};
206206

207+
/* The following fields are required, and must be set at once:
208+
*
209+
* @umem_area, @fill, @comp
210+
*
211+
* The following fields are optional:
212+
*
213+
* @fd, @size, @usr_config
214+
* If @fd is unset, a new sockfd will be created.
215+
* If @size is unset, @umem_area must be page-aligned.
216+
* If @usr_config is unset, all fields in @usr_config will be set to
217+
* default value (see `xsk_set_umem_config()`).
218+
*
219+
* Except for the fields mentioned above, none field can be set.
220+
*/
207221
struct xsk_umem_opts {
208222
size_t sz;
209223
int fd;

0 commit comments

Comments
 (0)