Skip to content

Commit e0373b7

Browse files
committed
linux: add devmem structs
For reference: https://elixir.bootlin.com/linux/v6.13.5/source/include/uapi/linux/uio.h#L23 Signed-off-by: Pedro Tammela <[email protected]>
1 parent e46ed1a commit e0373b7

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

libc-test/build.rs

+4
Original file line numberDiff line numberDiff line change
@@ -3893,6 +3893,10 @@ fn test_linux(target: &str) {
38933893
// FIXME(linux): Requires >= 6.9 kernel headers.
38943894
"epoll_params" => true,
38953895

3896+
// FIXME(linux): Requires >= 6.12 kernel headers.
3897+
"dmabuf_cmsg" |
3898+
"dmabuf_token" => true,
3899+
38963900
_ => false,
38973901
}
38983902
});

src/unix/linux_like/linux/mod.rs

+17
Original file line numberDiff line numberDiff line change
@@ -1320,6 +1320,23 @@ s! {
13201320
pub propagation: crate::__u64,
13211321
pub userns_fd: crate::__u64,
13221322
}
1323+
1324+
1325+
// linux/uio.h
1326+
1327+
pub struct dmabuf_cmsg {
1328+
pub frag_offset: crate::__u64,
1329+
pub frag_size: crate::__u32,
1330+
pub frag_token: crate::__u32,
1331+
pub dmabuf_id: crate::__u32,
1332+
pub flags: crate::__u32,
1333+
}
1334+
1335+
pub struct dmabuf_token {
1336+
pub token_start: crate::__u32,
1337+
pub token_count: crate::__u32,
1338+
}
1339+
13231340
}
13241341

13251342
cfg_if! {

0 commit comments

Comments
 (0)