Commit f6e136e4 authored by Anthony Liguori's avatar Anthony Liguori
Browse files

Merge remote-tracking branch 'mjt/trivial-patches-next' into staging



# By Dong Xu Wang (2) and others
# Via Michael Tokarev
* mjt/trivial-patches-next:
  osdep.h: include sys/types.h for ssize_t definition
  remove double semicolons
  clean unnecessary code: don't check g_strdup arg for NULL
  docs: mention AddressSpaces in docs/memory.txt
  audio: update documentation after removing --audio-card-list option
  m25p80.c: Sync Flash chip list with Linux
  bsd-user: OS-agnostic 64-bit SYSCTL types

Message-id: 518F61B9.9050803@msgid.tls.msk.ru
Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
parents 879367ef 98b2d199
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -609,7 +609,7 @@ static int nbd_co_discard(BlockDriverState *bs, int64_t sector_num,
        return 0;
    }
    request.type = NBD_CMD_TRIM;
    request.from = sector_num * 512;;
    request.from = sector_num * 512;
    request.len = nb_sectors * 512;

    nbd_coroutine_start(s, &request);
+4 −3
Original line number Diff line number Diff line
@@ -211,10 +211,11 @@ static int sysctl_oldcvt(void *holdp, size_t holdlen, uint32_t kind)
        *(uint64_t *)holdp = tswap64(*(unsigned long *)holdp);
        break;
#endif
#if !defined(__FreeBSD_version) || __FreeBSD_version < 900031
    case CTLTYPE_QUAD:
#else
#ifdef CTLTYPE_U64
    case CTLTYPE_S64:
    case CTLTYPE_U64:
#else
    case CTLTYPE_QUAD:
#endif
        *(uint64_t *)holdp = tswap64(*(uint64_t *)holdp);
        break;
+7 −4
Original line number Diff line number Diff line
@@ -15,10 +15,13 @@ The memory model provides support for
 - setting up coalesced memory for kvm
 - setting up ioeventfd regions for kvm

Memory is modelled as a tree (really acyclic graph) of MemoryRegion objects.
The root of the tree is memory as seen from the CPU's viewpoint (the system
bus).  Nodes in the tree represent other buses, memory controllers, and
memory regions that have been rerouted.  Leaves are RAM and MMIO regions.
Memory is modelled as an acyclic graph of MemoryRegion objects.  Sinks
(leaves) are RAM and MMIO regions, while other nodes represent
buses, memory controllers, and memory regions that have been rerouted.

In addition to MemoryRegion objects, the memory API provides AddressSpace
objects for every root and possibly for intermediate MemoryRegions too.
These represent memory as seen from the CPU or a device's viewpoint.

Types of regions
----------------
+2 −2
Original line number Diff line number Diff line
@@ -248,7 +248,7 @@ static int send_fd(int sockfd, int fd)
static int send_status(int sockfd, struct iovec *iovec, int status)
{
    ProxyHeader header;
    int retval, msg_size;;
    int retval, msg_size;

    if (status < 0) {
        header.type = T_ERROR;
@@ -381,7 +381,7 @@ static int send_response(int sock, struct iovec *iovec, int size)
    proxy_marshal(iovec, 0, "dd", header.type, header.size);
    retval = socket_write(sock, iovec->iov_base, header.size + PROXY_HDR_SZ);
    if (retval < 0) {
        return retval;;
        return retval;
    }
    return 0;
}
+1 −1
Original line number Diff line number Diff line
@@ -878,7 +878,7 @@ static int local_remove(FsContext *ctx, const char *path)
         * Now remove the name from parent directory
         * .virtfs_metadata directory
         */
        err = remove(local_mapped_attr_path(ctx, path, buffer));;
        err = remove(local_mapped_attr_path(ctx, path, buffer));
        if (err < 0 && errno != ENOENT) {
            /*
             * We didn't had the .virtfs_metadata file. May be file created
Loading