diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2015-12-17 18:07:09 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2015-12-17 18:07:09 +0000 |
commit | 6a6533213d78dea4407fe6933ad489796b582599 (patch) | |
tree | 1e37b82b21a52c000d5d6de0494c168bd69d4307 /scripts | |
parent | e5fbe28e5424d26fc2c25d0a7ecb927d3c80d5e8 (diff) | |
parent | 29cd81ffe3679bec9a062505e5b0d9a12f3558a8 (diff) | |
download | qemu-6a6533213d78dea4407fe6933ad489796b582599.zip qemu-6a6533213d78dea4407fe6933ad489796b582599.tar.gz qemu-6a6533213d78dea4407fe6933ad489796b582599.tar.bz2 |
Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging
* KVM: synic support, split irqchip support
* memory: cleanups, optimizations, ioeventfd emulation
* SCSI: small fixes, vmw_pvscsi compatibility improvements
* qemu_log cleanups
* Coverity model improvements
# gpg: Signature made Thu 17 Dec 2015 16:35:21 GMT using RSA key ID 78C7AE83
# gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org>"
# gpg: aka "Paolo Bonzini <pbonzini@redhat.com>"
* remotes/bonzini/tags/for-upstream: (45 commits)
coverity: Model g_memdup()
coverity: Model g_poll()
scsi: always call notifier on async cancellation
scsi: use scsi_req_cancel_async when purging requests
target-i386: kvm: clear unusable segments' flags in migration
rcu: optimize rcu_read_lock
memory: try to inline constant-length reads
memory: inline a few small accessors
memory: extract first iteration of address_space_read and address_space_write
memory: split address_space_read and address_space_write
memory: avoid unnecessary object_ref/unref
memory: reorder MemoryRegion fields
exec: make qemu_ram_ptr_length more similar to qemu_get_ram_ptr
exec: always call qemu_get_ram_ptr within rcu_read_lock
linux-user: convert DEBUG_SIGNAL logging to tracepoints
linux-user: avoid "naked" qemu_log
user: introduce "-d page"
xtensa: avoid "naked" qemu_log
tricore: avoid "naked" qemu_log
ppc: cleanup logging
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/coverity-model.c | 26 | ||||
-rwxr-xr-x | scripts/update-linux-headers.sh | 3 |
2 files changed, 29 insertions, 0 deletions
diff --git a/scripts/coverity-model.c b/scripts/coverity-model.c index 617f67d..ee5bf9d 100644 --- a/scripts/coverity-model.c +++ b/scripts/coverity-model.c @@ -236,6 +236,23 @@ void *g_try_realloc(void *ptr, size_t size) return g_try_realloc_n(ptr, 1, size); } +/* Other memory allocation functions */ + +void *g_memdup(const void *ptr, unsigned size) +{ + unsigned char *dup; + unsigned i; + + if (!ptr) { + return NULL; + } + + dup = g_malloc(size); + for (i = 0; i < size; i++) + dup[i] = ((unsigned char *)ptr)[i]; + return dup; +} + /* * GLib string allocation functions */ @@ -325,6 +342,15 @@ char *g_strconcat(const char *s, ...) /* Other glib functions */ +typedef struct pollfd GPollFD; + +int poll(); + +int g_poll (GPollFD *fds, unsigned nfds, int timeout) +{ + return poll(fds, nfds, timeout); +} + typedef struct _GIOChannel GIOChannel; GIOChannel *g_io_channel_unix_new(int fd) { diff --git a/scripts/update-linux-headers.sh b/scripts/update-linux-headers.sh index 096d090..ff5b0c7 100755 --- a/scripts/update-linux-headers.sh +++ b/scripts/update-linux-headers.sh @@ -36,6 +36,7 @@ cp_portable() { -e 'linux/types' \ -e 'stdint' \ -e 'linux/if_ether' \ + -e 'input-event-codes' \ -e 'sys/' \ > /dev/null then @@ -48,6 +49,7 @@ cp_portable() { -e 's/__s\([0-9][0-9]*\)/int\1_t/g' \ -e 's/__le\([0-9][0-9]*\)/uint\1_t/g' \ -e 's/__be\([0-9][0-9]*\)/uint\1_t/g' \ + -e 's/"\(input-event-codes\.h\)"/"standard-headers\/linux\/\1"/' \ -e 's/<linux\/\([^>]*\)>/"standard-headers\/linux\/\1"/' \ -e 's/__bitwise__//' \ -e 's/__attribute__((packed))/QEMU_PACKED/' \ @@ -128,6 +130,7 @@ EOF rm -rf "$output/include/standard-headers/linux" mkdir -p "$output/include/standard-headers/linux" for i in "$tmpdir"/include/linux/*virtio*.h "$tmpdir/include/linux/input.h" \ + "$tmpdir/include/linux/input-event-codes.h" \ "$tmpdir/include/linux/pci_regs.h"; do cp_portable "$i" "$output/include/standard-headers/linux" done |