20 lines · c
1// SPDX-License-Identifier: GPL-2.02 3#include <linux/export.h>4#include <linux/refcount.h>5 6refcount_t rust_helper_REFCOUNT_INIT(int n)7{8 return (refcount_t)REFCOUNT_INIT(n);9}10 11void rust_helper_refcount_inc(refcount_t *r)12{13 refcount_inc(r);14}15 16bool rust_helper_refcount_dec_and_test(refcount_t *r)17{18 return refcount_dec_and_test(r);19}20