Commit 6ac08f2
committed
rust: io: resource: Add owned Resource initialiser
Some C functions like of_reserved_mem_region_to_resource_byname() expect
a pointer to a `struct resource` so provide ::zeroed() as initialiser
and ::as_raw() so other parts in the kernel crate can use functions
which expect such a pointer.
Signed-off-by: Janne Grunau <j@jannau.net>1 parent 0a1d754 commit 6ac08f2
1 file changed
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
92 | 104 | | |
93 | 105 | | |
94 | 106 | | |
| |||
0 commit comments