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

virtio_config: remove virtio_config_val

The virtio_cread() functions should now be used.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

-27
-27
include/linux/virtio_config.h
··· 96 96 return test_bit(fbit, vdev->features); 97 97 } 98 98 99 - /** 100 - * virtio_config_val - look for a feature and get a virtio config entry. 101 - * @vdev: the virtio device 102 - * @fbit: the feature bit 103 - * @offset: the type to search for. 104 - * @v: a pointer to the value to fill in. 105 - * 106 - * The return value is -ENOENT if the feature doesn't exist. Otherwise 107 - * the config value is copied into whatever is pointed to by v. */ 108 - #define virtio_config_val(vdev, fbit, offset, v) \ 109 - virtio_config_buf((vdev), (fbit), (offset), (v), sizeof(*v)) 110 - 111 - #define virtio_config_val_len(vdev, fbit, offset, v, len) \ 112 - virtio_config_buf((vdev), (fbit), (offset), (v), (len)) 113 - 114 - static inline int virtio_config_buf(struct virtio_device *vdev, 115 - unsigned int fbit, 116 - unsigned int offset, 117 - void *buf, unsigned len) 118 - { 119 - if (!virtio_has_feature(vdev, fbit)) 120 - return -ENOENT; 121 - 122 - vdev->config->get(vdev, offset, buf, len); 123 - return 0; 124 - } 125 - 126 99 static inline 127 100 struct virtqueue *virtio_find_single_vq(struct virtio_device *vdev, 128 101 vq_callback_t *c, const char *n)