-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[board] avaota-a1: set GICR_WAKER bit 2 for BL31 #104
Conversation
Move gicr_set_waker to jump to bl31, if change it in start.S you will not able back to USB FEL. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do not use 0x60014, add new define in reg-ncat.h
like
#define GIC_IROUTR(_n) (SUNXI_GIC600_BASE + 0x6000 + 8 * (_n))
#define GICR_LPI_BASE(n) (SUNXI_GIC600_BASE + 0x60000 + n*0x20000)
#define GICR_WAKER(m) (GICR_LPI_BASE(m) + 0x0014)
#define GICR_PWRR(m) (GICR_LPI_BASE(m) + 0x0024)
#define LEVEL_TRIGERRED (0)
#define EDGE_TRIGERRED (1)
#define GIC_IRQ_TYPE_CFG(_n) (SUNXI_GIC600_BASE + 0xc00 + 4 * (_n))
#define GIC_IRQ_MOD_CFG(_n) (SUNXI_GIC600_BASE + 0xd00 + 4 * (_n))
using gicr_set_waker
in
SyterKit/board/avaota-a1/extlinux_boot/main.c
Lines 821 to 825 in 58ebe11
clean_syterkit_data(); | |
jmp_to_arm64(CONFIG_BL31_LOAD_ADDR); | |
clean_syterkit_data();
gicr_set_waker();
jmp_to_arm64(CONFIG_BL31_LOAD_ADDR);
GICR_WAKER is GIC Redistributor Power Management Control Register, the second bit is Processor Sleep (WAKER_CA_BIT in BL31) BL31 require GICR_WAKER bit 2 to be 1, otherwise it crashes. ASSERT: drivers/arm/gic/v3/gicv3_helpers.c:28:(gicr_read_waker(gicr_base) & WAKER_CA_BIT) != 0U when boot from SD Card, GICR_WAKER is 0x6 when boot from USB Fel, GICR_WAKER is 0x0 simply setting this bit to 1 will make bl31 to work properly
all problems are fixed, thank! |
GICR_WAKER is GIC Redistributor Power Management Control Register, the second bit is Processor Sleep (WAKER_CA_BIT in BL31)
BL31 require GICR_WAKER bit 2 to be 1, otherwise it crashes.
ASSERT: drivers/arm/gic/v3/gicv3_helpers.c:28:(gicr_read_waker(gicr_base) & WAKER_CA_BIT) != 0U
when boot from SD Card, GICR_WAKER is 0x6
when boot from USB Fel, GICR_WAKER is 0x0
simply setting this bit to 1 will make bl31 to work properly