[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: [OASIS Issue Tracker] (VIRTIO-36) balloon: align val in virtio_balloon_stat
[ https://tools.oasis-open.org/issues/browse/VIRTIO-36?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=37608#comment-37608 ] Rusty Russell commented on VIRTIO-36: ------------------------------------- Deferred as per minutes 2014-06-03 https://lists.oasis-open.org/archives/virtio/201406/msg00013.html > balloon: align val in virtio_balloon_stat > ----------------------------------------- > > Key: VIRTIO-36 > URL: https://tools.oasis-open.org/issues/browse/VIRTIO-36 > Project: OASIS Virtual I/O Device (VIRTIO) TC > Issue Type: Improvement > Reporter: Michael Tsirkin > > we have: > struct virtio_balloon_stat { > #define VIRTIO_BALLOON_S_SWAP_IN 0 > #define VIRTIO_BALLOON_S_SWAP_OUT 1 > #define VIRTIO_BALLOON_S_MAJFLT 2 > #define VIRTIO_BALLOON_S_MINFLT 3 > #define VIRTIO_BALLOON_S_MEMFREE 4 > #define VIRTIO_BALLOON_S_MEMTOT 5 > u16 tag; > u64 val; > } __attribute__((packed)); > val is 8 bytes but aligned at a 2 byte boundary. > this is ugly and unusual, and requires implementations > to use packed structures for access, which is error-prone. -- This message was sent by Atlassian JIRA (v6.2.2#6258)
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]