hw/misc: fix Aspeed SCU hw-strap2 property
PATCH 1/2 hw/misc: fix Aspeed SCU hw-strap2 property
These strap registers are complex enough, let's not mix them.
--- hw/misc/aspeed_scu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/misc/aspeed_scu.c +1 -1
@@ -254,7 +254,7 @@ static const VMStateDescription vmstate_aspeed_scu = {static Property aspeed_scu_properties[] = {DEFINE_PROP_UINT32 ("silicon-rev" , AspeedSCUState, silicon_rev,0 ),DEFINE_PROP_UINT32 ("hw-strap1" , AspeedSCUState, hw_strap1,0 ), -DEFINE_PROP_UINT32 ("hw-strap2" , AspeedSCUState, hw_strap1,0 ), +DEFINE_PROP_UINT32 ("hw-strap2" , AspeedSCUState, hw_strap2,0 ),DEFINE_PROP_END_OF_LIST (), };
Signature · 1 line
2.1.4
PATCH 2/2 hw/misc: use macros to define hw-strap1 register on Aspeed SOC
This gives some explanation behind the magic number 0x120CE416.
--- hw/arm/palmetto-bmc.c | 16 ++++++++- include/hw/misc/aspeed_scu.h | 78 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 93 insertions(+), 1 deletion(-)
hw/arm/palmetto-bmc.c +15 -1
@@ -22,6 +22,19 @@#include "sysemu/blockdev.h" #include "hw/block/flash.h" +#define PALMETTO_BMC_HW_STRAP1 ( \ + SCU_HW_STRAP_DRAM_SIZE(DRAM_SIZE_256MB) | \ + SCU_HW_STRAP_DRAM_CONFIG(2 /* DDR3 with CL=6, CWL=5 */) | \ +SCU_HW_STRAP_ACPI_DIS | \ + SCU_HW_STRAP_SET_CLK_SOURCE(CLK_48M_IN) | \ + SCU_HW_STRAP_VGA_CLASS_CODE | \ + SCU_HW_STRAP_LPC_RESET_PIN | \ + SCU_HW_STRAP_SPI_MODE(SCU_HW_STRAP_SPI_M_S_EN) | \ + SCU_HW_STRAP_SET_CPU_AHB_RATIO(CPU_AHB_RATIO_2_1) | \ + SCU_HW_STRAP_SPI_WIDTH | \ + SCU_HW_STRAP_VGA_SIZE_SET(VGA_16M_DRAM) | \ + SCU_HW_STRAP_BOOT_MODE(SPI_BOOT)) +static struct arm_boot_info palmetto_bmc_binfo = { .loader_start =AST2400_SDRAM_BASE , .board_id =0 ,
@@ -77,7 +90,8 @@ static void palmetto_bmc_init(MachineState *machine) &bmc->ram);object_property_add_const_link (OBJECT (&bmc->soc),"ram" ,OBJECT (&bmc->ram), &error_abort); -object_property_set_int (OBJECT (&bmc->soc),0x120CE416 ,"hw-strap1" , +object_property_set_int (OBJECT (&bmc->soc),PALMETTO_BMC_HW_STRAP1 , +"hw-strap1" , &error_abort);object_property_set_bool (OBJECT (&bmc->soc), true,"realized" , &error_abort);
include/hw/misc/aspeed_scu.h +78 -0
82 lines not on this page · raw message
Signature · 1 line
2.1.4
Quoted 3 lines · Cédric Le Goater
These strap registers are complex enough, let's not mix them.
Signed-off-by Cédric Le Goater <[email protected]>
Was there a cover letter for this patchset? I can't find it in my email...
thanks
-- PMM
Quoted 7 lines · Peter Maydell
Quoted 3 lines · Cédric Le Goater
These strap registers are complex enough, let's not mix them.
Signed-off-by Cédric Le Goater <[email protected]>Was there a cover letter for this patchset? I can't find it in my email...
Ah :/ No, I didn't send one as the patches were small and self contained. Should we each time ?
Thanks,
C.
Quoted 11 lines · Cédric Le Goater
Quoted 7 lines · Peter Maydell
Quoted 3 lines · Cédric Le Goater
These strap registers are complex enough, let's not mix them.
Signed-off-by Cédric Le Goater <[email protected]>Was there a cover letter for this patchset? I can't find it in my email...
Ah :/ No, I didn't send one as the patches were small and self contained. Should we each time ?
Let me rework that if possible. I need to add a few things.
Thanks,
C.
Quoted 11 lines · Cédric Le Goater
Quoted 7 lines · Peter Maydell
Quoted 3 lines · Cédric Le Goater
These strap registers are complex enough, let's not mix them.
Signed-off-by Cédric Le Goater <[email protected]>Was there a cover letter for this patchset? I can't find it in my email...
Ah :/ No, I didn't send one as the patches were small and self contained. Should we each time ?
The basic rule is that single standalone patches don't need a cover letter; a series with more than one patch should have a cover letter. Some of our automated tooling gets confused otherwise (also I like to be able to have a single email to mark for attention in my mail client). These confused me a bit because they had the series indicators in the subject (1/2, 2/2) but no cover.
thanks
-- PMM
Quoted 13 lines · Peter Maydell
Quoted 11 lines · Cédric Le Goater
Quoted 7 lines · Peter Maydell
Quoted 3 lines · Cédric Le Goater
These strap registers are complex enough, let's not mix them.
Signed-off-by Cédric Le Goater <[email protected]>Was there a cover letter for this patchset? I can't find it in my email...
Ah :/ No, I didn't send one as the patches were small and self contained. Should we each time ?
Quoted 7 lines
The basic rule is that single standalone patches don't need a cover letter; a series with more than one patch should have a cover letter. Some of our automated tooling gets confused otherwise (also I like to be able to have a single email to mark for attention in my mail client). These confused me a bit because they had the series indicators in the subject (1/2, 2/2) but no cover.
Yes, the email threading was a bit confusing in my mail client also. Sorry about that.
I will resend with a cover letter. I need to add where the macros are coming from.
Thanks,
C.