Public bug reported: /home/dcb/qemu/trunk/qemu/hw/i386/intel_iommu.c:902:5: error: logical ‘and’ applied to non-boolean constant [-Werror=logical-op] pvtd_as = s->address_spaces[VTD_SID_TO_BUS(source_id)]; ^
$ fgrep VTD_SID_TO_BUS `find . -name \*.h -print` ./include/hw/i386/intel_iommu.h:#define VTD_SID_TO_BUS(sid) (((sid) >> 8) && 0xff) $ Sounds to me like #define VTD_SID_TO_BUS(sid) (((sid) >> 8) & 0xff) would be better. ** Affects: qemu Importance: Undecided Status: New -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1382477 Title: hw/i386/intel_iommu.c:902: wrong logical operator ? Status in QEMU: New Bug description: /home/dcb/qemu/trunk/qemu/hw/i386/intel_iommu.c:902:5: error: logical ‘and’ applied to non-boolean constant [-Werror=logical-op] pvtd_as = s->address_spaces[VTD_SID_TO_BUS(source_id)]; ^ $ fgrep VTD_SID_TO_BUS `find . -name \*.h -print` ./include/hw/i386/intel_iommu.h:#define VTD_SID_TO_BUS(sid) (((sid) >> 8) && 0xff) $ Sounds to me like #define VTD_SID_TO_BUS(sid) (((sid) >> 8) & 0xff) would be better. To manage notifications about this bug go to: https://bugs.launchpad.net/qemu/+bug/1382477/+subscriptions