| 1 | |
| 2 |
|
| 3 | #include <linux/delay.h>
|
| 4 | #include <linux/ktime.h>
|
| 5 | #include <linux/timekeeping.h>
|
| 6 |
|
| 7 | __rust_helper void rust_helper_fsleep(unsigned long usecs)
|
| 8 | {
|
| 9 | fsleep(usecs);
|
| 10 | }
|
| 11 |
|
| 12 | __rust_helper ktime_t rust_helper_ktime_get_real(void)
|
| 13 | {
|
| 14 | return ktime_get_real();
|
| 15 | }
|
| 16 |
|
| 17 | __rust_helper ktime_t rust_helper_ktime_get_boottime(void)
|
| 18 | {
|
| 19 | return ktime_get_boottime();
|
| 20 | }
|
| 21 |
|
| 22 | __rust_helper ktime_t rust_helper_ktime_get_clocktai(void)
|
| 23 | {
|
| 24 | return ktime_get_clocktai();
|
| 25 | }
|
| 26 |
|
| 27 | __rust_helper s64 rust_helper_ktime_to_us(const ktime_t kt)
|
| 28 | {
|
| 29 | return ktime_to_us(kt);
|
| 30 | }
|
| 31 |
|
| 32 | __rust_helper s64 rust_helper_ktime_to_ms(const ktime_t kt)
|
| 33 | {
|
| 34 | return ktime_to_ms(kt);
|
| 35 | }
|
| 36 |
|
| 37 | __rust_helper void rust_helper_udelay(unsigned long usec)
|
| 38 | {
|
| 39 | udelay(usec);
|
| 40 | }
|