target-arm queue:
* support variable (runtime-determined) page sizes, for a
nearly-20% speedup of TCG for ARMv7 and v8 CPUs with 4K pages
* ptimer: add tests, support more flexible behaviour around
what happens on the "zero" tick, use ptimer for a9gtimer
* virt: ACPI: Add IORT Structure definition
* i2c: Fix SMBus read transactions to avoid double events
* timer: stm32f2xx_timer: add check for prescaler value
* QOMify musicpal, pxa2xx_gpio, strongarm, pl110
* target-arm: Implement new HLT trap for semihosting
* i2c: Add asserts for second smbus i2c_start_transfer()
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
iQIcBAABCAAGBQJYDkPBAAoJEDwlJe0UNgzeUgYP/1coSoKGgxsKkLp8KRZSinoP
k8J/GQCvPi7Ha1ntonPQ2vSrs11EdGlNaQWQo8Iq1KVnWx0K+fJJfhtqNXnzk7gN
6xOhR+c3vZhCCoPkTJgY5yMF7LsMwOgYLmuk5hzxGHb7IRteHCaUCG5mCQBOOK39
kIuXu0UlYo/cPYcXLZkHpRIQAHWWwXvfthAWHoYvdVFMmBUnneFZgPlFOYCAG7X6
L9sEbpH5ZG2ttUXTYGtrBw1WfkVrKY9rwG2xZqu3yqQfGMDQFwHP1Q4pB7Z+SpoE
H6mI7DBUnvHjcscg/H6/LUmMfJ3pL8qS7NtGz1AP9ArU2/Zk+MO7YJEcRBiYwtXY
Z/LbYTyU7Ellrd5t2hAe1zxDiGh3TcRRCVuFZdyRhisyloKbq+/WmAcsTkuO5NRd
p1hHBoPvwYEhEHXcoeq5uOGtwxrr4dl736wQ4vEhNyzbCfpcytEePjbxNdE44iVM
VTcmsI0S6aAZxDv8a07dPn4BlFVXt/nzuhXFFDnealjVqOD5Pe4aG9oFTgHsJkdR
bt1Z3gmjH6jCmUTTaMVqY696u8NoRxJdk7OMBLMHYmKuLzGJ70pqy2kinYOZXqxW
yLziS++qTlZwzHqVxDNsnLiRoRn2Jo1kb/hoBIkvJ+TgoxqfDQjGBvVQLHHjbu/Z
FKOCN6lnBNL41R4JigR7
=nDCf
-----END PGP SIGNATURE-----
Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20161024' into staging
target-arm queue:
* support variable (runtime-determined) page sizes, for a
nearly-20% speedup of TCG for ARMv7 and v8 CPUs with 4K pages
* ptimer: add tests, support more flexible behaviour around
what happens on the "zero" tick, use ptimer for a9gtimer
* virt: ACPI: Add IORT Structure definition
* i2c: Fix SMBus read transactions to avoid double events
* timer: stm32f2xx_timer: add check for prescaler value
* QOMify musicpal, pxa2xx_gpio, strongarm, pl110
* target-arm: Implement new HLT trap for semihosting
* i2c: Add asserts for second smbus i2c_start_transfer()
# gpg: Signature made Mon 24 Oct 2016 18:24:17 BST
# gpg: using RSA key 0x3C2525ED14360CDE
# gpg: Good signature from "Peter Maydell <peter.maydell@linaro.org>"
# gpg: aka "Peter Maydell <pmaydell@gmail.com>"
# gpg: aka "Peter Maydell <pmaydell@chiark.greenend.org.uk>"
# Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83 15CF 3C25 25ED 1436 0CDE
* remotes/pmaydell/tags/pull-target-arm-20161024: (32 commits)
i2c: Add asserts for second smbus i2c_start_transfer()
target-arm: Implement new HLT trap for semihosting
hw/display: QOM'ify pl110.c
hw/arm: QOM'ify strongarm.c
hw/arm: QOM'ify pxa2xx_gpio.c
hw/arm: QOM'ify musicpal.c
timer: stm32f2xx_timer: add check for prescaler value
i2c: Fix SMBus read transactions to avoid double events
timer: a9gtimer: remove loop to auto-increment comparator
ARM: Virt: ACPI: Build an IORT table with RC and ITS nodes
ACPI: Add IORT Structure definition
tests: Add tests for the ARM MPTimer
arm_mptimer: Convert to use ptimer
tests: ptimer: Replace 10000 with 1
tests: ptimer: Change the copyright comment
tests: ptimer: Add tests for "no counter round down" policy
hw/ptimer: Add "no counter round down" policy
tests: ptimer: Add tests for "no immediate reload" policy
hw/ptimer: Add "no immediate reload" policy
tests: ptimer: Add tests for "no immediate trigger" policy
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
fe4c04071f
33 changed files with 2138 additions and 304 deletions
|
|
@ -189,6 +189,15 @@ void address_space_stq(AddressSpace *as, hwaddr addr, uint64_t val,
|
|||
|
||||
/* page related stuff */
|
||||
|
||||
#ifdef TARGET_PAGE_BITS_VARY
|
||||
extern bool target_page_bits_decided;
|
||||
extern int target_page_bits;
|
||||
#define TARGET_PAGE_BITS ({ assert(target_page_bits_decided); \
|
||||
target_page_bits; })
|
||||
#else
|
||||
#define TARGET_PAGE_BITS_MIN TARGET_PAGE_BITS
|
||||
#endif
|
||||
|
||||
#define TARGET_PAGE_SIZE (1 << TARGET_PAGE_BITS)
|
||||
#define TARGET_PAGE_MASK ~(TARGET_PAGE_SIZE - 1)
|
||||
#define TARGET_PAGE_ALIGN(addr) (((addr) + TARGET_PAGE_SIZE - 1) & TARGET_PAGE_MASK)
|
||||
|
|
|
|||
|
|
@ -609,4 +609,72 @@ typedef struct AcpiDmarHardwareUnit AcpiDmarHardwareUnit;
|
|||
/* Masks for Flags field above */
|
||||
#define ACPI_DMAR_INCLUDE_PCI_ALL 1
|
||||
|
||||
/*
|
||||
* Input Output Remapping Table (IORT)
|
||||
* Conforms to "IO Remapping Table System Software on ARM Platforms",
|
||||
* Document number: ARM DEN 0049B, October 2015
|
||||
*/
|
||||
|
||||
struct AcpiIortTable {
|
||||
ACPI_TABLE_HEADER_DEF /* ACPI common table header */
|
||||
uint32_t node_count;
|
||||
uint32_t node_offset;
|
||||
uint32_t reserved;
|
||||
} QEMU_PACKED;
|
||||
typedef struct AcpiIortTable AcpiIortTable;
|
||||
|
||||
/*
|
||||
* IORT node types
|
||||
*/
|
||||
|
||||
#define ACPI_IORT_NODE_HEADER_DEF /* Node format common fields */ \
|
||||
uint8_t type; \
|
||||
uint16_t length; \
|
||||
uint8_t revision; \
|
||||
uint32_t reserved; \
|
||||
uint32_t mapping_count; \
|
||||
uint32_t mapping_offset;
|
||||
|
||||
/* Values for node Type above */
|
||||
enum {
|
||||
ACPI_IORT_NODE_ITS_GROUP = 0x00,
|
||||
ACPI_IORT_NODE_NAMED_COMPONENT = 0x01,
|
||||
ACPI_IORT_NODE_PCI_ROOT_COMPLEX = 0x02,
|
||||
ACPI_IORT_NODE_SMMU = 0x03,
|
||||
ACPI_IORT_NODE_SMMU_V3 = 0x04
|
||||
};
|
||||
|
||||
struct AcpiIortIdMapping {
|
||||
uint32_t input_base;
|
||||
uint32_t id_count;
|
||||
uint32_t output_base;
|
||||
uint32_t output_reference;
|
||||
uint32_t flags;
|
||||
} QEMU_PACKED;
|
||||
typedef struct AcpiIortIdMapping AcpiIortIdMapping;
|
||||
|
||||
struct AcpiIortMemoryAccess {
|
||||
uint32_t cache_coherency;
|
||||
uint8_t hints;
|
||||
uint16_t reserved;
|
||||
uint8_t memory_flags;
|
||||
} QEMU_PACKED;
|
||||
typedef struct AcpiIortMemoryAccess AcpiIortMemoryAccess;
|
||||
|
||||
struct AcpiIortItsGroup {
|
||||
ACPI_IORT_NODE_HEADER_DEF
|
||||
uint32_t its_count;
|
||||
uint32_t identifiers[0];
|
||||
} QEMU_PACKED;
|
||||
typedef struct AcpiIortItsGroup AcpiIortItsGroup;
|
||||
|
||||
struct AcpiIortRC {
|
||||
ACPI_IORT_NODE_HEADER_DEF
|
||||
AcpiIortMemoryAccess memory_properties;
|
||||
uint32_t ats_attribute;
|
||||
uint32_t pci_segment_number;
|
||||
AcpiIortIdMapping id_mapping_array[0];
|
||||
} QEMU_PACKED;
|
||||
typedef struct AcpiIortRC AcpiIortRC;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -86,6 +86,12 @@ typedef struct {
|
|||
* Returns a @HotpluggableCPUList, which describes CPUs objects which
|
||||
* could be added with -device/device_add.
|
||||
* Caller is responsible for freeing returned list.
|
||||
* @minimum_page_bits:
|
||||
* If non-zero, the board promises never to create a CPU with a page size
|
||||
* smaller than this, so QEMU can use a more efficient larger page
|
||||
* size than the target architecture's minimum. (Attempting to create
|
||||
* such a CPU will fail.) Note that changing this is a migration
|
||||
* compatibility break for the machine.
|
||||
*/
|
||||
struct MachineClass {
|
||||
/*< private >*/
|
||||
|
|
@ -124,6 +130,7 @@ struct MachineClass {
|
|||
ram_addr_t default_ram_size;
|
||||
bool option_rom_has_mr;
|
||||
bool rom_file_has_mr;
|
||||
int minimum_page_bits;
|
||||
|
||||
HotplugHandler *(*get_hotplug_handler)(MachineState *machine,
|
||||
DeviceState *dev);
|
||||
|
|
|
|||
|
|
@ -35,6 +35,26 @@
|
|||
*/
|
||||
#define PTIMER_POLICY_DEFAULT 0
|
||||
|
||||
/* Periodic timer counter stays with "0" for a one period before wrapping
|
||||
* around. */
|
||||
#define PTIMER_POLICY_WRAP_AFTER_ONE_PERIOD (1 << 0)
|
||||
|
||||
/* Running periodic timer that has counter = limit = 0 would continuously
|
||||
* re-trigger every period. */
|
||||
#define PTIMER_POLICY_CONTINUOUS_TRIGGER (1 << 1)
|
||||
|
||||
/* Starting to run with/setting counter to "0" won't trigger immediately,
|
||||
* but after a one period for both oneshot and periodic modes. */
|
||||
#define PTIMER_POLICY_NO_IMMEDIATE_TRIGGER (1 << 2)
|
||||
|
||||
/* Starting to run with/setting counter to "0" won't re-load counter
|
||||
* immediately, but after a one period. */
|
||||
#define PTIMER_POLICY_NO_IMMEDIATE_RELOAD (1 << 3)
|
||||
|
||||
/* Make counter value of the running timer represent the actual value and
|
||||
* not the one less. */
|
||||
#define PTIMER_POLICY_NO_COUNTER_ROUND_DOWN (1 << 4)
|
||||
|
||||
/* ptimer.c */
|
||||
typedef struct ptimer_state ptimer_state;
|
||||
typedef void (*ptimer_cb)(void *opaque);
|
||||
|
|
|
|||
|
|
@ -27,12 +27,9 @@
|
|||
|
||||
/* State of a single timer or watchdog block */
|
||||
typedef struct {
|
||||
uint32_t count;
|
||||
uint32_t load;
|
||||
uint32_t control;
|
||||
uint32_t status;
|
||||
int64_t tick;
|
||||
QEMUTimer *timer;
|
||||
struct ptimer_state *timer;
|
||||
qemu_irq irq;
|
||||
MemoryRegion iomem;
|
||||
} TimerBlock;
|
||||
|
|
|
|||
|
|
@ -81,6 +81,18 @@ bool tcg_enabled(void);
|
|||
|
||||
void cpu_exec_init_all(void);
|
||||
|
||||
/**
|
||||
* set_preferred_target_page_bits:
|
||||
* @bits: number of bits needed to represent an address within the page
|
||||
*
|
||||
* Set the preferred target page size (the actual target page
|
||||
* size may be smaller than any given CPU's preference).
|
||||
* Returns true on success, false on failure (which can only happen
|
||||
* if this is called after the system has already finalized its
|
||||
* choice of page size and the requested page size is smaller than that).
|
||||
*/
|
||||
bool set_preferred_target_page_bits(int bits);
|
||||
|
||||
/**
|
||||
* Sends a (part of) iovec down a socket, yielding when the socket is full, or
|
||||
* Receives data into a (part of) iovec from a socket,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue