]>
Commit | Line | Data |
---|---|---|
fca9ca1b CLG |
1 | /* |
2 | * Aspeed Machines | |
3 | * | |
4 | * Copyright 2018 IBM Corp. | |
5 | * | |
6 | * This code is licensed under the GPL version 2 or later. See | |
7 | * the COPYING file in the top-level directory. | |
8 | */ | |
9 | #ifndef ARM_ASPEED_H | |
10 | #define ARM_ASPEED_H | |
11 | ||
12 | #include "hw/boards.h" | |
db1015e9 | 13 | #include "qom/object.h" |
fca9ca1b | 14 | |
612b219a | 15 | typedef struct AspeedMachineState AspeedMachineState; |
fca9ca1b | 16 | |
fca9ca1b | 17 | #define TYPE_ASPEED_MACHINE MACHINE_TYPE_NAME("aspeed") |
db1015e9 | 18 | typedef struct AspeedMachineClass AspeedMachineClass; |
8110fa1d EH |
19 | DECLARE_OBJ_CHECKERS(AspeedMachineState, AspeedMachineClass, |
20 | ASPEED_MACHINE, TYPE_ASPEED_MACHINE) | |
fca9ca1b | 21 | |
d3bad7e7 CLG |
22 | #define ASPEED_MAC0_ON (1 << 0) |
23 | #define ASPEED_MAC1_ON (1 << 1) | |
24 | #define ASPEED_MAC2_ON (1 << 2) | |
25 | #define ASPEED_MAC3_ON (1 << 3) | |
26 | ||
fca9ca1b | 27 | |
db1015e9 | 28 | struct AspeedMachineClass { |
fca9ca1b | 29 | MachineClass parent_obj; |
baa4732b CLG |
30 | |
31 | const char *name; | |
32 | const char *desc; | |
33 | const char *soc_name; | |
34 | uint32_t hw_strap1; | |
35 | uint32_t hw_strap2; | |
36 | const char *fmc_model; | |
37 | const char *spi_model; | |
38 | uint32_t num_cs; | |
d3bad7e7 | 39 | uint32_t macs_mask; |
612b219a | 40 | void (*i2c_init)(AspeedMachineState *bmc); |
5d63d0c7 | 41 | uint32_t uart_default; |
db1015e9 | 42 | }; |
fca9ca1b CLG |
43 | |
44 | ||
45 | #endif |