summaryrefslogtreecommitdiffstats
path: root/tests/libqos
diff options
context:
space:
mode:
authorJohn Snow <jsnow@redhat.com>2015-01-19 15:15:57 -0500
committerStefan Hajnoczi <stefanha@redhat.com>2015-02-16 14:40:55 +0000
commit8d5eeceddcb6464c7db3b4504c14766453db091e (patch)
tree6afd3fecd5d975dfd98b67f59caae65f3f9be1e6 /tests/libqos
parent6100ddb0f9776555b581455be4707f2077eee42f (diff)
downloadhqemu-8d5eeceddcb6464c7db3b4504c14766453db091e.zip
hqemu-8d5eeceddcb6464c7db3b4504c14766453db091e.tar.gz
qtest/ahci: finalize AHCIQState consolidation
Move barsize, ahci_fingerprint and capabilities registers into the AHCIQState object, removing global ahci-related state from the ahci-test.c file. More churn, less globals. Signed-off-by: John Snow <jsnow@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Message-id: 1421698563-6977-10-git-send-email-jsnow@redhat.com Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'tests/libqos')
-rw-r--r--tests/libqos/ahci.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/libqos/ahci.h b/tests/libqos/ahci.h
index e9e0206..8e92385 100644
--- a/tests/libqos/ahci.h
+++ b/tests/libqos/ahci.h
@@ -249,6 +249,10 @@ typedef struct AHCIQState {
QOSState *parent;
QPCIDevice *dev;
void *hba_base;
+ uint64_t barsize;
+ uint32_t fingerprint;
+ uint32_t cap;
+ uint32_t cap2;
} AHCIQState;
/**
@@ -340,11 +344,6 @@ typedef struct PRD {
uint32_t dbc; /* Data Byte Count (0-indexed) & Interrupt Flag (bit 2^31) */
} PRD;
-typedef struct HBACap {
- uint32_t cap;
- uint32_t cap2;
-} HBACap;
-
/*** Macro Utilities ***/
#define BITANY(data, mask) (((data) & (mask)) != 0)
#define BITSET(data, mask) (((data) & (mask)) == (mask))
OpenPOWER on IntegriCloud