Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

virtio_config: reorder functions

This simply reorders functions in virtio_config
so width access wrapper helpers are all together.
Drops an extra empty line while we are at it.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

authored by

Michael S. Tsirkin and committed by
Rusty Russell
caa0e2d0 271c8651

+7 -8
+7 -8
include/linux/virtio_config.h
··· 298 298 } \ 299 299 } while(0) 300 300 301 - static inline u8 virtio_cread8(struct virtio_device *vdev, unsigned int offset) 302 - { 303 - u8 ret; 304 - vdev->config->get(vdev, offset, &ret, sizeof(ret)); 305 - return ret; 306 - } 307 - 308 301 /* Read @count fields, @bytes each. */ 309 302 static inline void __virtio_cread_many(struct virtio_device *vdev, 310 303 unsigned int offset, ··· 319 326 } while (gen != old); 320 327 } 321 328 322 - 323 329 static inline void virtio_cread_bytes(struct virtio_device *vdev, 324 330 unsigned int offset, 325 331 void *buf, size_t len) 326 332 { 327 333 __virtio_cread_many(vdev, offset, buf, len, 1); 334 + } 335 + 336 + static inline u8 virtio_cread8(struct virtio_device *vdev, unsigned int offset) 337 + { 338 + u8 ret; 339 + vdev->config->get(vdev, offset, &ret, sizeof(ret)); 340 + return ret; 328 341 } 329 342 330 343 static inline void virtio_cwrite8(struct virtio_device *vdev,