From 44262327aa288b111a41ce067bed235759db4c1c Mon Sep 17 00:00:00 2001 From: Ahmed Mansour Date: Fri, 15 Dec 2017 16:01:00 -0500 Subject: drivers/misc: Share qbman init between archs This patch adds changes necessary to move functionality present in PowerPC folders with ARM architectures that have DPAA1 QBMan hardware - Create new board/freescale/common/fsl_portals.c to house shared device tree fixups for DPAA1 devices with ARM and PowerPC cores - Add new header file to top includes directory to allow files in both architectures to grab the function prototypes - Port inhibit_portals() from PowerPC to ARM. This function is used in setup to disable interrupts on all QMan and BMan portals. It is needed because the interrupts are enabled by default for all portals including unused/uninitialised portals. When the kernel attempts to go to deep sleep the unused portals prevent it from doing so Signed-off-by: Ahmed Mansour Reviewed-by: York Sun --- board/freescale/p1023rdb/p1023rdb.c | 3 ++- board/keymile/kmp204x/kmp204x.c | 2 +- board/varisys/cyrus/cyrus.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) (limited to 'board') diff --git a/board/freescale/p1023rdb/p1023rdb.c b/board/freescale/p1023rdb/p1023rdb.c index ccda824..a23a5d5 100644 --- a/board/freescale/p1023rdb/p1023rdb.c +++ b/board/freescale/p1023rdb/p1023rdb.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include #include @@ -81,7 +82,7 @@ int board_early_init_r(void) MAS3_SW|MAS3_SR, MAS2_I|MAS2_G, 0, flash_esel, BOOKE_PAGESZ_256M, 1); - setup_portals(); + setup_qbman_portals(); return 0; } diff --git a/board/keymile/kmp204x/kmp204x.c b/board/keymile/kmp204x/kmp204x.c index 8c9d6b1..d70b1d1 100644 --- a/board/keymile/kmp204x/kmp204x.c +++ b/board/keymile/kmp204x/kmp204x.c @@ -126,7 +126,7 @@ int board_early_init_r(void) invalidate_icache(); set_liodns(); - setup_portals(); + setup_qbman_portals(); ret = trigger_fpga_config(); if (ret) diff --git a/board/varisys/cyrus/cyrus.c b/board/varisys/cyrus/cyrus.c index 30f518a..f458627 100644 --- a/board/varisys/cyrus/cyrus.c +++ b/board/varisys/cyrus/cyrus.c @@ -69,7 +69,7 @@ int board_early_init_r(void) set_liodns(); #ifdef CONFIG_SYS_DPAA_QBMAN - setup_portals(); + setup_qbman_portals(); #endif print_lbc_regs(); return 0; -- cgit v1.1