mirror of
https://github.com/Motorhead1991/qemu.git
synced 2026-01-05 22:17:40 -07:00
Rename target_phys_addr_t to hwaddr
target_phys_addr_t is unwieldly, violates the C standard (_t suffixes are
reserved) and its purpose doesn't match the name (most target_phys_addr_t
addresses are not target specific). Replace it with a finger-friendly,
standards conformant hwaddr.
Outstanding patchsets can be fixed up with the command
git rebase -i --exec 'find -name "*.[ch]"
| xargs s/target_phys_addr_t/hwaddr/g' origin
Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
50d2b4d93f
commit
a8170e5e97
383 changed files with 2240 additions and 2240 deletions
28
hw/virtio.h
28
hw/virtio.h
|
|
@ -69,7 +69,7 @@
|
|||
|
||||
struct VirtQueue;
|
||||
|
||||
static inline target_phys_addr_t vring_align(target_phys_addr_t addr,
|
||||
static inline hwaddr vring_align(hwaddr addr,
|
||||
unsigned long align)
|
||||
{
|
||||
return (addr + align - 1) & ~(align - 1);
|
||||
|
|
@ -84,8 +84,8 @@ typedef struct VirtQueueElement
|
|||
unsigned int index;
|
||||
unsigned int out_num;
|
||||
unsigned int in_num;
|
||||
target_phys_addr_t in_addr[VIRTQUEUE_MAX_SIZE];
|
||||
target_phys_addr_t out_addr[VIRTQUEUE_MAX_SIZE];
|
||||
hwaddr in_addr[VIRTQUEUE_MAX_SIZE];
|
||||
hwaddr out_addr[VIRTQUEUE_MAX_SIZE];
|
||||
struct iovec in_sg[VIRTQUEUE_MAX_SIZE];
|
||||
struct iovec out_sg[VIRTQUEUE_MAX_SIZE];
|
||||
} VirtQueueElement;
|
||||
|
|
@ -144,7 +144,7 @@ void virtqueue_flush(VirtQueue *vq, unsigned int count);
|
|||
void virtqueue_fill(VirtQueue *vq, const VirtQueueElement *elem,
|
||||
unsigned int len, unsigned int idx);
|
||||
|
||||
void virtqueue_map_sg(struct iovec *sg, target_phys_addr_t *addr,
|
||||
void virtqueue_map_sg(struct iovec *sg, hwaddr *addr,
|
||||
size_t num_sg, int is_write);
|
||||
int virtqueue_pop(VirtQueue *vq, VirtQueueElement *elem);
|
||||
int virtqueue_avail_bytes(VirtQueue *vq, unsigned int in_bytes,
|
||||
|
|
@ -178,8 +178,8 @@ uint32_t virtio_config_readl(VirtIODevice *vdev, uint32_t addr);
|
|||
void virtio_config_writeb(VirtIODevice *vdev, uint32_t addr, uint32_t data);
|
||||
void virtio_config_writew(VirtIODevice *vdev, uint32_t addr, uint32_t data);
|
||||
void virtio_config_writel(VirtIODevice *vdev, uint32_t addr, uint32_t data);
|
||||
void virtio_queue_set_addr(VirtIODevice *vdev, int n, target_phys_addr_t addr);
|
||||
target_phys_addr_t virtio_queue_get_addr(VirtIODevice *vdev, int n);
|
||||
void virtio_queue_set_addr(VirtIODevice *vdev, int n, hwaddr addr);
|
||||
hwaddr virtio_queue_get_addr(VirtIODevice *vdev, int n);
|
||||
int virtio_queue_get_num(VirtIODevice *vdev, int n);
|
||||
void virtio_queue_notify(VirtIODevice *vdev, int n);
|
||||
uint16_t virtio_queue_vector(VirtIODevice *vdev, int n);
|
||||
|
|
@ -220,14 +220,14 @@ void virtio_scsi_exit(VirtIODevice *vdev);
|
|||
DEFINE_PROP_BIT("event_idx", _state, _field, \
|
||||
VIRTIO_RING_F_EVENT_IDX, true)
|
||||
|
||||
target_phys_addr_t virtio_queue_get_desc_addr(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_avail_addr(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_used_addr(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_ring_addr(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_desc_size(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_avail_size(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_used_size(VirtIODevice *vdev, int n);
|
||||
target_phys_addr_t virtio_queue_get_ring_size(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_desc_addr(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_avail_addr(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_used_addr(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_ring_addr(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_desc_size(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_avail_size(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_used_size(VirtIODevice *vdev, int n);
|
||||
hwaddr virtio_queue_get_ring_size(VirtIODevice *vdev, int n);
|
||||
uint16_t virtio_queue_get_last_avail_idx(VirtIODevice *vdev, int n);
|
||||
void virtio_queue_set_last_avail_idx(VirtIODevice *vdev, int n, uint16_t idx);
|
||||
VirtQueue *virtio_get_queue(VirtIODevice *vdev, int n);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue