[PATCH 2/2] arm: aspeed: Remove SPI1 strapping hacks

Xo Wang xow at google.com
Sat Nov 5 03:31:25 AEDT 2016


On Thu, Nov 3, 2016 at 9:39 PM, Andrew Jeffery <andrew at aj.id.au> wrote:
> On Fri, 2016-11-04 at 14:00 +1030, Joel Stanley wrote:
>> Now that we have device tree and pinmux support for setting the
>> strapping we can remove these from the board file.
>>
>> Signed-off-by: Joel Stanley <joel at jms.id.au>
>
> Reviewed-by: Andrew Jeffery <andrew at aj.id.au>

Reviewed-by: Xo Wang <xow at google.com>

>
>> ---
>>  arch/arm/mach-aspeed/aspeed.c | 13 +------------
>>  1 file changed, 1 insertion(+), 12 deletions(-)
>>
>> diff --git a/arch/arm/mach-aspeed/aspeed.c b/arch/arm/mach-aspeed/aspeed.c
>> index ebb2224dcd13..2100e54ffbc2 100644
>> --- a/arch/arm/mach-aspeed/aspeed.c
>> +++ b/arch/arm/mach-aspeed/aspeed.c
>> @@ -160,13 +160,8 @@ static void __init do_ast2500evb_setup(void)
>>
>>       do_ast2500_common_setup();
>>
>> -     reg = readl(AST_IO(AST_BASE_SCU | 0x70));
>> -
>>       /* Set strap to RGMII for dedicated PHY networking */
>> -     reg |= BIT(6) | BIT(7);
>> -     /* Enable SPI Master and SPI Slave to AHB Bridge */
>> -     reg |= BIT(13);
>> -     writel(reg, AST_IO(AST_BASE_SCU | 0x70));
>> +     writel(BIT(6) | BIT(7), AST_IO(AST_BASE_SCU | 0x70));
>>  }
>>
>>  static void __init do_witherspoon_setup(void)
>> @@ -190,12 +185,6 @@ static void __init do_zaius_setup(void)
>>               /* D3 in GPIOA/B/C/D direction and data registers */
>>               unsigned long phy_reset_mask = BIT(27);
>>
>> -             /* Set strap[13:12] to 01, Enable SPI master */
>> -             /* Set bits in writes to SCU7C are cleared from SCU70 */
>> -             writel(BIT(13), AST_IO(AST_BASE_SCU | 0x7C));
>> -             /* SCU70 is set-only, so no read-modify-write needed */
>> -             writel(BIT(12), AST_IO(AST_BASE_SCU | 0x70));
>> -
>>               /* Disable GPIO I, G/AB pulldowns due to weak driving buffers */
>>               reg = readl(AST_IO(AST_BASE_SCU | 0x8C));
>>               writel(reg | BIT(24) | BIT(22), AST_IO(AST_BASE_SCU | 0x8C));


More information about the openbmc mailing list