arm: at91: Change the Chip ID registers' addresses
PATCH 1/1 arm: at91: Change the Chip ID registers' addresses
Provide the specific addresses for the Chip ID and Chip ID Extension registers, instead of the offset, which make it use on other chips.
---
arch/arm/mach-at91/armv7/cpu.c | 7 ++++--- arch/arm/mach-at91/include/mach/at91_dbu.h | 4 ---- arch/arm/mach-at91/include/mach/sama5d3.h | 3 +++ arch/arm/mach-at91/include/mach/sama5d4.h | 3 +++ 4 files changed, 10 insertions(+), 7 deletions(-)
arch/arm/mach-at91/armv7/cpu.c +4 -3
@@ -12,7 +12,6 @@#include <common.h> #include <asm/io.h> #include <asm/arch/hardware.h> -#include <asm/arch/at91_dbu.h> #include <asm/arch/at91_pmc.h> #include <asm/arch/at91_pit.h> #include <asm/arch/at91_gpbr.h>
@@ -65,12 +64,14 @@ void enable_caches(void)dcache_enable (); } +#define ATMEL_CHIPID_CIDR_VERSION 0x1f +unsigned int get_chip_id (void ) { -return readl (ATMEL_BASE_DBGU +AT91_DBU_CIDR ) & ~AT91_DBU_CIDR_MASK ; +return readl (ATMEL_CHIPID_CIDR ) & ~ATMEL_CHIPID_CIDR_VERSION ; }unsigned int get_extension_chip_id (void ) { -return readl (ATMEL_BASE_DBGU +AT91_DBU_EXID ); +return readl (ATMEL_CHIPID_EXID ); }
arch/arm/mach-at91/include/mach/at91_dbu.h +0 -4
@@ -35,8 +35,4 @@ typedef struct at91_dbu {#define AT91_DBU_CID_ARCH_9xx 0x01900000#define AT91_DBU_CID_ARCH_9XExx 0x02900000 -#define AT91_DBU_CIDR_MASK 0x1f -#define AT91_DBU_CIDR 0x40 -#define AT91_DBU_EXID 0x44 -#endif
arch/arm/mach-at91/include/mach/sama5d3.h +3 -0
@@ -158,6 +158,9 @@#define ATMEL_BASE_RTC 0xfffffeb0/* Reserved: 0xfffffee0 - 0xffffffff */ +#define ATMEL_CHIPID_CIDR 0xffffee40 +#define ATMEL_CHIPID_EXID 0xffffee44 +/* * Internal Memory. */
arch/arm/mach-at91/include/mach/sama5d4.h +3 -0
@@ -144,6 +144,9 @@#define ATMEL_BASE_PIOE 0xfc06d000#define ATMEL_BASE_AIC 0xfc06e000 +#define ATMEL_CHIPID_CIDR 0xfc069040 +#define ATMEL_CHIPID_EXID 0xfc069044 +/* * Internal Memory. */
Signature · 1 line
1.7.9.5
PATCH 1/1 arm: at91: Change the Chip ID registers' addresses
Quoted 4 lines · Wenyou Yang
Provide the specific addresses for the Chip ID and Chip ID Extension registers, instead of the offset, which make it use on other chips.
Signed-off-by Wenyou Yang <[email protected]>
Quoted 7 lines
---
arch/arm/mach-at91/armv7/cpu.c | 7 ++++--- arch/arm/mach-at91/include/mach/at91_dbu.h | 4 ---- arch/arm/mach-at91/include/mach/sama5d3.h | 3 +++ arch/arm/mach-at91/include/mach/sama5d4.h | 3 +++ 4 files changed, 10 insertions(+), 7 deletions(-)
Yang
PATCH 1/1 arm: at91: Change the Chip ID registers' addresses
Quoted 10 lines
-----Original Message-----
From: Andreas Bie?mann [mailto:andreas.devel at googlemail.com]
Sent: 2015?10?24? 5:11
To: Yang, Wenyou; U-Boot Mailing List
Subject: Re: [PATCH] arm: at91: Change the Chip ID registers' addresses
Quoted 7 lines
Quoted 4 lines · Wenyou Yang
Provide the specific addresses for the Chip ID and Chip ID Extension registers, instead of the offset, which make it use on other chips.
Signed-off-by Wenyou Yang <[email protected]>Reviewed-by Andreas Bie?mann <[email protected]>
Thanks
Best Regards,
Wenyou Yang
Quoted 7 lines
Quoted 7 lines
---
arch/arm/mach-at91/armv7/cpu.c | 7 ++++--- arch/arm/mach-at91/include/mach/at91_dbu.h | 4 ---- arch/arm/mach-at91/include/mach/sama5d3.h | 3 +++ arch/arm/mach-at91/include/mach/sama5d4.h | 3 +++ 4 files changed, 10 insertions(+), 7 deletions(-)
Dear Wenyou Yang,
Quoted 5 lines · Wenyou Yang
Provide the specific addresses for the Chip ID and Chip ID Extension registers, instead of the offset, which make it use on other chips.
Signed-off-by Wenyou Yang <[email protected]>Reviewed-by Andreas Bie?mann <[email protected]>
Quoted 7 lines
---
arch/arm/mach-at91/armv7/cpu.c | 7 ++++--- arch/arm/mach-at91/include/mach/at91_dbu.h | 4 ---- arch/arm/mach-at91/include/mach/sama5d3.h | 3 +++ arch/arm/mach-at91/include/mach/sama5d4.h | 3 +++ 4 files changed, 10 insertions(+), 7 deletions(-)
applied to u-boot-atmel/master, thanks!
Best regards,
Andreas Bie?mann