zone is a virtio 1.x feature so all fields are LE, they are handled as such, but have mistakenly been labeled __virtioXX in the header. This results in a bunch of sparse warnings. Use the __leXX tags to make sparse happy.
Showing the changes to include/uapi/linux (1 of 1 file). Show all
Unified · Split
| @@ -140,11 +140,11 @@ struct virtio_blk_config { · 139 unmodified lines | ||
| 140 | 140 | |
| 141 | 141 | /* Zoned block device characteristics (if VIRTIO_BLK_F_ZONED) */ |
| 142 | 142 | struct virtio_blk_zoned_characteristics { |
| 143 | − __virtio32 zone_sectors; | |
| 144 | − __virtio32 max_open_zones; | |
| 145 | − __virtio32 max_active_zones; | |
| 146 | − __virtio32 max_append_sectors; | |
| 147 | − __virtio32 write_granularity; | |
| 143 | + __le32 zone_sectors; | |
| 144 | + __le32 max_open_zones; | |
| 145 | + __le32 max_active_zones; | |
| 146 | + __le32 max_append_sectors; | |
| 147 | + __le32 write_granularity; | |
| 148 | 148 | __u8 model; |
| 149 | 149 | __u8 unused2[3]; |
| 150 | 150 | } zoned; |
| @@ -241,11 +241,11 @@ struct virtio_blk_outhdr { · 90 unmodified lines | ||
| 241 | 241 | */ |
| 242 | 242 | struct virtio_blk_zone_descriptor { |
| 243 | 243 | /* Zone capacity */ |
| 244 | − __virtio64 z_cap; | |
| 244 | + __le64 z_cap; | |
| 245 | 245 | /* The starting sector of the zone */ |
| 246 | − __virtio64 z_start; | |
| 246 | + __le64 z_start; | |
| 247 | 247 | /* Zone write pointer position in sectors */ |
| 248 | − __virtio64 z_wp; | |
| 248 | + __le64 z_wp; | |
| 249 | 249 | /* Zone type */ |
| 250 | 250 | __u8 z_type; |
| 251 | 251 | /* Zone state */ |
| @@ -254,7 +254,7 @@ struct virtio_blk_zone_descriptor { · 2 unmodified lines | ||
| 254 | 254 | }; |
| 255 | 255 | |
| 256 | 256 | struct virtio_blk_zone_report { |
| 257 | − __virtio64 nr_zones; | |
| 257 | + __le64 nr_zones; | |
| 258 | 258 | __u8 reserved[56]; |
| 259 | 259 | struct virtio_blk_zone_descriptor zones[]; |
| 260 | 260 | }; |