[Qemu-devel] [PATCH RFC v6 03/20] virtio: feature bit manipulation helpers

David Gibson
2015-01-22T01:25:47Z

On Thu, Dec 11, 2014 at 02:25:05PM +0100, Cornelia Huck
wrote:
> Add virtio_{add,clear}_feature helper functions for manipulating a
> feature bits variable. This has some benefits over open coding:
> - add check that the bit is in a sane range
> - make it obvious at a glance what is going on
> - have a central point to change when we want to extend feature bits
>
> Convert existing code manipulating features to use the new helpers.
>
> Signed-off-by: Cornelia Huck <cornelia.huck at de.ibm.com>

Reviewed-by: David Gibson <david at gibson.dropbear.id.au>

--
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL:
<http://lists.linuxfoundation.org/pipermail/virtualization/attachments/20150122/759d305d/attachment-0001.sig>