On Thu, 11 Dec 2014 15:46:23 +0100 Thomas Huth <thuth@xxxxxxxxxxxxxxxxxx> wrote: > > +static inline bool __virtio_has_feature(uint32_t features, unsigned int fbit) > > +{ > > + assert(fbit < 32); > > + return !!(features & (1 << fbit)); > > +} > > + > > +static inline bool virtio_has_feature(VirtIODevice *vdev, unsigned int fbit) > > +{ > > + return __virtio_has_feature(vdev->guest_features, fbit); > > +} > > + > > I've got to say that I'm a little bit unhappy with the naming of the > functions - and in contrast to the Linux kernel code, I think it is > also quite uncommon in the QEMU sources to use function names with > double underscores at the beginning. > > Could you maybe rename the second function to "virtio_vdev_has_feature" > instead? And then remove the double underscores from the first function? Renamed the functions just like this. _______________________________________________ Virtualization mailing list Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx https://lists.linuxfoundation.org/mailman/listinfo/virtualization