xref: /linux/rust/helpers/list.c (revision 4a57e0913e8c7fff407e97909f4ae48caa84d612)
1 // SPDX-License-Identifier: GPL-2.0
2 
3 /*
4  * Helpers for C circular doubly linked list implementation.
5  */
6 
7 #include <linux/list.h>
8 
9 __rust_helper void rust_helper_INIT_LIST_HEAD(struct list_head *list)
10 {
11 	INIT_LIST_HEAD(list);
12 }
13 
14 __rust_helper void rust_helper_list_add_tail(struct list_head *new, struct list_head *head)
15 {
16 	list_add_tail(new, head);
17 }
18