summaryrefslogtreecommitdiff
path: root/hw/block/xen_blkif.h
AgeCommit message (Collapse)AuthorFilesLines
2015-12-18xen/blkif: Avoid double access to src->nr_segmentsStefano Stabellini1-4/+8
src is stored in shared memory and src->nr_segments is dereferenced twice at the end of the function. If a compiler decides to compile this into two separate memory accesses then the size limitation could be bypassed. Fix it by removing the double access to src->nr_segments. This is part of XSA-155. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
2014-05-07xen_disk: add discard supportOlaf Hering1-0/+12
Implement discard support for xen_disk. It makes use of the existing discard code in qemu. The discard support is enabled unconditionally. The tool stack may provide a property "discard-enable" in the backend node to optionally disable discard support. This is helpful in case the backing file was intentionally created non-sparse to avoid fragmentation. Signed-off-by: Olaf Hering <olaf@aepfle.de> Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
2013-04-08hw: move private headers to hw/ subdirectories.Paolo Bonzini1-0/+103
Many headers are used only in a single directory. These can be kept in hw/. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>