On 17/08/15 02:48, Cornelia Huck wrote: > Commit ef546f1275f6563e8934dd5e338d29d9f9909ca6 ("virtio: add > feature checking helpers") introduced a helper __virtio_has_feature. > We don't want to use reserved identifiers, though, so let's > rename __virtio_has_feature to virtio_has_feature and virtio_has_feature > to virtio_vdev_has_feature. > > Signed-off-by: Cornelia Huck <cornelia.h...@de.ibm.com> > --- > hw/block/virtio-blk.c | 7 ++++--- > hw/char/virtio-serial-bus.c | 2 +- > hw/net/vhost_net.c | 2 +- > hw/net/virtio-net.c | 31 ++++++++++++++++--------------- > hw/scsi/virtio-scsi.c | 8 ++++---- > hw/virtio/dataplane/vring.c | 10 +++++----- > hw/virtio/vhost.c | 4 ++-- > hw/virtio/virtio-balloon.c | 2 +- > hw/virtio/virtio.c | 14 +++++++------- > include/hw/virtio/virtio-access.h | 2 +- > include/hw/virtio/virtio.h | 11 ++++++----- > 11 files changed, 48 insertions(+), 45 deletions(-) ... > diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c > index 8d28e45..f72eebf 100644 > --- a/hw/net/virtio-net.c > +++ b/hw/net/virtio-net.c > @@ -86,8 +86,8 @@ static void virtio_net_set_config(VirtIODevice *vdev, const > uint8_t *config) > > memcpy(&netcfg, config, n->config_size); > > - if (!virtio_has_feature(vdev, VIRTIO_NET_F_CTRL_MAC_ADDR) && > - !virtio_has_feature(vdev, VIRTIO_F_VERSION_1) && > + if (!virtio_vdev_has_feature(vdev, VIRTIO_NET_F_CTRL_MAC_ADDR) && > + !virtio_vdev_has_feature(vdev, VIRTIO_F_VERSION_1) && > memcmp(netcfg.mac, n->mac, ETH_ALEN)) { > memcpy(n->mac, netcfg.mac, ETH_ALEN); > qemu_format_nic_info_str(qemu_get_queue(n->nic), n->mac); > @@ -304,7 +304,7 @@ static RxFilterInfo > *virtio_net_query_rxfilter(NetClientState *nc) > info->multicast_table = str_list; > info->vlan_table = get_vlan_table(n); > > - if (!virtio_has_feature(vdev, VIRTIO_NET_F_CTRL_VLAN)) { > + if (!virtio_vdev_has_feature(vdev, VIRTIO_NET_F_CTRL_VLAN)) { > info->vlan = RX_STATE_ALL; > } else if (!info->vlan_table) { > info->vlan = RX_STATE_NONE; > @@ -529,13 +529,13 @@ static void virtio_net_set_features(VirtIODevice *vdev, > uint64_t features) > int i; > > virtio_net_set_multiqueue(n, > - __virtio_has_feature(features, > VIRTIO_NET_F_MQ)); > + virtio_has_feature(features, VIRTIO_NET_F_MQ));
Could this fit now into one line? Anyway, patch still looks fine to me, so: Reviewed-by: Thomas Huth <th...@redhat.com>