Commit ad46db9add5bb5d8190f8d0eba4372f1fe6faa8a
1 parent
807d5170
Rename fls to qemu_fls
Fix compiler warning on OSX, reported by Andreas Faerber. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5982 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
3 changed files
with
3 additions
and
3 deletions
cutils.c
hw/virtio.c
... | ... | @@ -858,7 +858,7 @@ VirtIODevice *virtio_init_pci(PCIBus *bus, const char *name, |
858 | 858 | |
859 | 859 | size = 20 + config_size; |
860 | 860 | if (size & (size-1)) |
861 | - size = 1 << fls(size); | |
861 | + size = 1 << qemu_fls(size); | |
862 | 862 | |
863 | 863 | pci_register_io_region(pci_dev, 0, size, PCI_ADDRESS_SPACE_IO, |
864 | 864 | virtio_map); | ... | ... |
qemu-common.h
... | ... | @@ -104,7 +104,7 @@ char *pstrcat(char *buf, int buf_size, const char *s); |
104 | 104 | int strstart(const char *str, const char *val, const char **ptr); |
105 | 105 | int stristart(const char *str, const char *val, const char **ptr); |
106 | 106 | time_t mktimegm(struct tm *tm); |
107 | -int fls(int i); | |
107 | +int qemu_fls(int i); | |
108 | 108 | |
109 | 109 | #define qemu_isalnum(c) isalnum((unsigned char)(c)) |
110 | 110 | #define qemu_isalpha(c) isalpha((unsigned char)(c)) | ... | ... |