diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2014-06-03 14:37:43 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2014-06-03 14:37:43 +0100 |
commit | e00fcfeab3d452cba3d0a08991a39ab15df66424 (patch) | |
tree | 443d02c8e6f51f9b6edff482d16ca116519bb030 /include | |
parent | 278073ba293d2b78641505f9c40e6f37c4a2f024 (diff) | |
parent | 5e70018b00dbe59a96b80933a0dd308ee1ec4488 (diff) | |
download | qemu-e00fcfeab3d452cba3d0a08991a39ab15df66424.zip qemu-e00fcfeab3d452cba3d0a08991a39ab15df66424.tar.gz qemu-e00fcfeab3d452cba3d0a08991a39ab15df66424.tar.bz2 |
Merge remote-tracking branch 'remotes/awilliam/tags/vfio-pci-for-qemu-20140602.0' into staging
VFIO patches: realtek NIC quirk + SPAPR IOMMU AddressSpace support
# gpg: Signature made Mon 02 Jun 2014 22:44:42 BST using RSA key ID 3BB08B22
# gpg: Can't check signature: public key not found
* remotes/awilliam/tags/vfio-pci-for-qemu-20140602.0:
vfio: Add guest side IOMMU support
vfio: Create VFIOAddressSpace objects as needed
vfio: Introduce VFIO address spaces
vfio: Rework to have error paths
vfio: Fix 128 bit handling
int128: Add int128_exts64()
memory: Sanity check that no listeners remain on a destroyed AddressSpace
vfio-pci: Quirk RTL8168 NIC
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/qemu/int128.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/qemu/int128.h b/include/qemu/int128.h index f597031..fb782aa 100644 --- a/include/qemu/int128.h +++ b/include/qemu/int128.h @@ -38,6 +38,11 @@ static inline Int128 int128_2_64(void) return (Int128) { 0, 1 }; } +static inline Int128 int128_exts64(int64_t a) +{ + return (Int128) { .lo = a, .hi = (a < 0) ? -1 : 0 }; +} + static inline Int128 int128_and(Int128 a, Int128 b) { return (Int128) { a.lo & b.lo, a.hi & b.hi }; |