Skip to content

Commit 09593c0

Browse files
alyssaisstsquad
authored andcommitted
virtio-bindings: regenerate with Linux 6.6
Still no changes to the bindgen output from newer bindgen. Signed-off-by: Alyssa Ross <hi@alyssa.is>
1 parent 1cae0a2 commit 09593c0

File tree

2 files changed

+98
-0
lines changed

2 files changed

+98
-0
lines changed

crates/virtio-bindings/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
## Added
44

55
- Exposed virtio_ids.h bindings as a public module.
6+
- Regnerate bindings with Linux 6.6.
67

78
# v0.2.2
89

crates/virtio-bindings/src/virtio_net/generated.rs

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ pub const VIRTIO_NET_F_CTRL_RX_EXTRA: u32 = 20;
5252
pub const VIRTIO_NET_F_GUEST_ANNOUNCE: u32 = 21;
5353
pub const VIRTIO_NET_F_MQ: u32 = 22;
5454
pub const VIRTIO_NET_F_CTRL_MAC_ADDR: u32 = 23;
55+
pub const VIRTIO_NET_F_VQ_NOTF_COAL: u32 = 52;
5556
pub const VIRTIO_NET_F_NOTF_COAL: u32 = 53;
5657
pub const VIRTIO_NET_F_GUEST_USO4: u32 = 54;
5758
pub const VIRTIO_NET_F_GUEST_USO6: u32 = 55;
@@ -121,6 +122,8 @@ pub const VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET: u32 = 0;
121122
pub const VIRTIO_NET_CTRL_NOTF_COAL: u32 = 6;
122123
pub const VIRTIO_NET_CTRL_NOTF_COAL_TX_SET: u32 = 0;
123124
pub const VIRTIO_NET_CTRL_NOTF_COAL_RX_SET: u32 = 1;
125+
pub const VIRTIO_NET_CTRL_NOTF_COAL_VQ_SET: u32 = 2;
126+
pub const VIRTIO_NET_CTRL_NOTF_COAL_VQ_GET: u32 = 3;
124127
pub type __u8 = ::std::os::raw::c_uchar;
125128
pub type __u16 = ::std::os::raw::c_ushort;
126129
pub type __u32 = ::std::os::raw::c_uint;
@@ -1094,3 +1097,97 @@ fn bindgen_test_layout_virtio_net_ctrl_coal_rx() {
10941097
)
10951098
);
10961099
}
1100+
#[repr(C)]
1101+
#[derive(Debug, Default, Copy, Clone, PartialEq)]
1102+
pub struct virtio_net_ctrl_coal {
1103+
pub max_packets: __le32,
1104+
pub max_usecs: __le32,
1105+
}
1106+
#[test]
1107+
fn bindgen_test_layout_virtio_net_ctrl_coal() {
1108+
const UNINIT: ::std::mem::MaybeUninit<virtio_net_ctrl_coal> = ::std::mem::MaybeUninit::uninit();
1109+
let ptr = UNINIT.as_ptr();
1110+
assert_eq!(
1111+
::std::mem::size_of::<virtio_net_ctrl_coal>(),
1112+
8usize,
1113+
concat!("Size of: ", stringify!(virtio_net_ctrl_coal))
1114+
);
1115+
assert_eq!(
1116+
::std::mem::align_of::<virtio_net_ctrl_coal>(),
1117+
4usize,
1118+
concat!("Alignment of ", stringify!(virtio_net_ctrl_coal))
1119+
);
1120+
assert_eq!(
1121+
unsafe { ::std::ptr::addr_of!((*ptr).max_packets) as usize - ptr as usize },
1122+
0usize,
1123+
concat!(
1124+
"Offset of field: ",
1125+
stringify!(virtio_net_ctrl_coal),
1126+
"::",
1127+
stringify!(max_packets)
1128+
)
1129+
);
1130+
assert_eq!(
1131+
unsafe { ::std::ptr::addr_of!((*ptr).max_usecs) as usize - ptr as usize },
1132+
4usize,
1133+
concat!(
1134+
"Offset of field: ",
1135+
stringify!(virtio_net_ctrl_coal),
1136+
"::",
1137+
stringify!(max_usecs)
1138+
)
1139+
);
1140+
}
1141+
#[repr(C)]
1142+
#[derive(Debug, Default, Copy, Clone, PartialEq)]
1143+
pub struct virtio_net_ctrl_coal_vq {
1144+
pub vqn: __le16,
1145+
pub reserved: __le16,
1146+
pub coal: virtio_net_ctrl_coal,
1147+
}
1148+
#[test]
1149+
fn bindgen_test_layout_virtio_net_ctrl_coal_vq() {
1150+
const UNINIT: ::std::mem::MaybeUninit<virtio_net_ctrl_coal_vq> =
1151+
::std::mem::MaybeUninit::uninit();
1152+
let ptr = UNINIT.as_ptr();
1153+
assert_eq!(
1154+
::std::mem::size_of::<virtio_net_ctrl_coal_vq>(),
1155+
12usize,
1156+
concat!("Size of: ", stringify!(virtio_net_ctrl_coal_vq))
1157+
);
1158+
assert_eq!(
1159+
::std::mem::align_of::<virtio_net_ctrl_coal_vq>(),
1160+
4usize,
1161+
concat!("Alignment of ", stringify!(virtio_net_ctrl_coal_vq))
1162+
);
1163+
assert_eq!(
1164+
unsafe { ::std::ptr::addr_of!((*ptr).vqn) as usize - ptr as usize },
1165+
0usize,
1166+
concat!(
1167+
"Offset of field: ",
1168+
stringify!(virtio_net_ctrl_coal_vq),
1169+
"::",
1170+
stringify!(vqn)
1171+
)
1172+
);
1173+
assert_eq!(
1174+
unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
1175+
2usize,
1176+
concat!(
1177+
"Offset of field: ",
1178+
stringify!(virtio_net_ctrl_coal_vq),
1179+
"::",
1180+
stringify!(reserved)
1181+
)
1182+
);
1183+
assert_eq!(
1184+
unsafe { ::std::ptr::addr_of!((*ptr).coal) as usize - ptr as usize },
1185+
4usize,
1186+
concat!(
1187+
"Offset of field: ",
1188+
stringify!(virtio_net_ctrl_coal_vq),
1189+
"::",
1190+
stringify!(coal)
1191+
)
1192+
);
1193+
}

0 commit comments

Comments
 (0)