mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-30 09:36:40 +07:00
ARM: kirkwood: convert to DT irqchip and clocksource
With recent support for true irqchip and clocksource drivers for Orion SoCs, now make use of it on DT enabled Kirkwood boards. This also introduces a new Kconfig option for legacy (non-DT) Kirkwood where old code is moved out to and polishes DT board file a little bit. Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> Signed-off-by: Jason Cooper <jason@lakedaemon.net>
This commit is contained in:
parent
f07d73e33d
commit
2326f04321
@ -2,67 +2,81 @@ if ARCH_KIRKWOOD
|
|||||||
|
|
||||||
menu "Marvell Kirkwood Implementations"
|
menu "Marvell Kirkwood Implementations"
|
||||||
|
|
||||||
|
config KIRKWOOD_LEGACY
|
||||||
|
bool
|
||||||
|
|
||||||
config MACH_D2NET_V2
|
config MACH_D2NET_V2
|
||||||
bool "LaCie d2 Network v2 NAS Board"
|
bool "LaCie d2 Network v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie d2 Network v2 NAS.
|
LaCie d2 Network v2 NAS.
|
||||||
|
|
||||||
config MACH_DOCKSTAR
|
config MACH_DOCKSTAR
|
||||||
bool "Seagate FreeAgent DockStar"
|
bool "Seagate FreeAgent DockStar"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Seagate FreeAgent DockStar.
|
Seagate FreeAgent DockStar.
|
||||||
|
|
||||||
config MACH_ESATA_SHEEVAPLUG
|
config MACH_ESATA_SHEEVAPLUG
|
||||||
bool "Marvell eSATA SheevaPlug Reference Board"
|
bool "Marvell eSATA SheevaPlug Reference Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell eSATA SheevaPlug Reference Board.
|
Marvell eSATA SheevaPlug Reference Board.
|
||||||
|
|
||||||
config MACH_GURUPLUG
|
config MACH_GURUPLUG
|
||||||
bool "Marvell GuruPlug Reference Board"
|
bool "Marvell GuruPlug Reference Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell GuruPlug Reference Board.
|
Marvell GuruPlug Reference Board.
|
||||||
|
|
||||||
config MACH_INETSPACE_V2
|
config MACH_INETSPACE_V2
|
||||||
bool "LaCie Internet Space v2 NAS Board"
|
bool "LaCie Internet Space v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie Internet Space v2 NAS.
|
LaCie Internet Space v2 NAS.
|
||||||
|
|
||||||
config MACH_MV88F6281GTW_GE
|
config MACH_MV88F6281GTW_GE
|
||||||
bool "Marvell 88F6281 GTW GE Board"
|
bool "Marvell 88F6281 GTW GE Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell 88F6281 GTW GE Board.
|
Marvell 88F6281 GTW GE Board.
|
||||||
|
|
||||||
config MACH_NET2BIG_V2
|
config MACH_NET2BIG_V2
|
||||||
bool "LaCie 2Big Network v2 NAS Board"
|
bool "LaCie 2Big Network v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie 2Big Network v2 NAS.
|
LaCie 2Big Network v2 NAS.
|
||||||
|
|
||||||
config MACH_NET5BIG_V2
|
config MACH_NET5BIG_V2
|
||||||
bool "LaCie 5Big Network v2 NAS Board"
|
bool "LaCie 5Big Network v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie 5Big Network v2 NAS.
|
LaCie 5Big Network v2 NAS.
|
||||||
|
|
||||||
config MACH_NETSPACE_MAX_V2
|
config MACH_NETSPACE_MAX_V2
|
||||||
bool "LaCie Network Space Max v2 NAS Board"
|
bool "LaCie Network Space Max v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie Network Space Max v2 NAS.
|
LaCie Network Space Max v2 NAS.
|
||||||
|
|
||||||
config MACH_NETSPACE_V2
|
config MACH_NETSPACE_V2
|
||||||
bool "LaCie Network Space v2 NAS Board"
|
bool "LaCie Network Space v2 NAS Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
LaCie Network Space v2 NAS.
|
LaCie Network Space v2 NAS.
|
||||||
|
|
||||||
config MACH_OPENRD
|
config MACH_OPENRD
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
bool
|
bool
|
||||||
|
|
||||||
config MACH_OPENRD_BASE
|
config MACH_OPENRD_BASE
|
||||||
@ -88,30 +102,35 @@ config MACH_OPENRD_ULTIMATE
|
|||||||
|
|
||||||
config MACH_RD88F6192_NAS
|
config MACH_RD88F6192_NAS
|
||||||
bool "Marvell RD-88F6192-NAS Reference Board"
|
bool "Marvell RD-88F6192-NAS Reference Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell RD-88F6192-NAS Reference Board.
|
Marvell RD-88F6192-NAS Reference Board.
|
||||||
|
|
||||||
config MACH_RD88F6281
|
config MACH_RD88F6281
|
||||||
bool "Marvell RD-88F6281 Reference Board"
|
bool "Marvell RD-88F6281 Reference Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell RD-88F6281 Reference Board.
|
Marvell RD-88F6281 Reference Board.
|
||||||
|
|
||||||
config MACH_SHEEVAPLUG
|
config MACH_SHEEVAPLUG
|
||||||
bool "Marvell SheevaPlug Reference Board"
|
bool "Marvell SheevaPlug Reference Board"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
Marvell SheevaPlug Reference Board.
|
Marvell SheevaPlug Reference Board.
|
||||||
|
|
||||||
config MACH_T5325
|
config MACH_T5325
|
||||||
bool "HP t5325 Thin Client"
|
bool "HP t5325 Thin Client"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
HP t5325 Thin Client.
|
HP t5325 Thin Client.
|
||||||
|
|
||||||
config MACH_TS219
|
config MACH_TS219
|
||||||
bool "QNAP TS-110, TS-119, TS-119P+, TS-210, TS-219, TS-219P and TS-219P+ Turbo NAS"
|
bool "QNAP TS-110, TS-119, TS-119P+, TS-210, TS-219, TS-219P and TS-219P+ Turbo NAS"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
QNAP TS-110, TS-119, TS-119P+, TS-210, TS-219, TS-219P and
|
QNAP TS-110, TS-119, TS-119P+, TS-210, TS-219, TS-219P and
|
||||||
@ -119,6 +138,7 @@ config MACH_TS219
|
|||||||
|
|
||||||
config MACH_TS41X
|
config MACH_TS41X
|
||||||
bool "QNAP TS-410, TS-410U, TS-419P, TS-419P+ and TS-419U Turbo NAS"
|
bool "QNAP TS-410, TS-410U, TS-419P, TS-419P+ and TS-419U Turbo NAS"
|
||||||
|
select KIRKWOOD_LEGACY
|
||||||
help
|
help
|
||||||
Say 'Y' here if you want your kernel to support the
|
Say 'Y' here if you want your kernel to support the
|
||||||
QNAP TS-410, TS-410U, TS-419P, TS-419P+ and TS-419U Turbo
|
QNAP TS-410, TS-410U, TS-419P, TS-419P+ and TS-419U Turbo
|
||||||
@ -129,6 +149,8 @@ comment "Device tree entries"
|
|||||||
config ARCH_KIRKWOOD_DT
|
config ARCH_KIRKWOOD_DT
|
||||||
bool "Marvell Kirkwood Flattened Device Tree"
|
bool "Marvell Kirkwood Flattened Device Tree"
|
||||||
select KIRKWOOD_CLK
|
select KIRKWOOD_CLK
|
||||||
|
select ORION_IRQCHIP
|
||||||
|
select ORION_TIMER
|
||||||
select POWER_SUPPLY
|
select POWER_SUPPLY
|
||||||
select POWER_RESET
|
select POWER_RESET
|
||||||
select POWER_RESET_GPIO
|
select POWER_RESET_GPIO
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
obj-y += common.o irq.o pcie.o mpp.o
|
obj-y += common.o pcie.o
|
||||||
|
obj-$(CONFIG_KIRKWOOD_LEGACY) += irq.o mpp.o
|
||||||
obj-$(CONFIG_MACH_D2NET_V2) += d2net_v2-setup.o lacie_v2-common.o
|
obj-$(CONFIG_MACH_D2NET_V2) += d2net_v2-setup.o lacie_v2-common.o
|
||||||
obj-$(CONFIG_MACH_DOCKSTAR) += dockstar-setup.o
|
obj-$(CONFIG_MACH_DOCKSTAR) += dockstar-setup.o
|
||||||
obj-$(CONFIG_MACH_ESATA_SHEEVAPLUG) += sheevaplug-setup.o
|
obj-$(CONFIG_MACH_ESATA_SHEEVAPLUG) += sheevaplug-setup.o
|
||||||
|
@ -15,6 +15,9 @@
|
|||||||
#include <linux/of.h>
|
#include <linux/of.h>
|
||||||
#include <linux/of_platform.h>
|
#include <linux/of_platform.h>
|
||||||
#include <linux/clk-provider.h>
|
#include <linux/clk-provider.h>
|
||||||
|
#include <linux/clocksource.h>
|
||||||
|
#include <linux/dma-mapping.h>
|
||||||
|
#include <linux/irqchip.h>
|
||||||
#include <linux/kexec.h>
|
#include <linux/kexec.h>
|
||||||
#include <asm/mach/arch.h>
|
#include <asm/mach/arch.h>
|
||||||
#include <asm/mach/map.h>
|
#include <asm/mach/map.h>
|
||||||
@ -67,10 +70,17 @@ static void __init kirkwood_legacy_clk_init(void)
|
|||||||
clk_prepare_enable(clk);
|
clk_prepare_enable(clk);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void __init kirkwood_of_clk_init(void)
|
static void __init kirkwood_dt_time_init(void)
|
||||||
{
|
{
|
||||||
of_clk_init(NULL);
|
of_clk_init(NULL);
|
||||||
kirkwood_legacy_clk_init();
|
clocksource_of_init();
|
||||||
|
}
|
||||||
|
|
||||||
|
static void __init kirkwood_dt_init_early(void)
|
||||||
|
{
|
||||||
|
mvebu_mbus_init("marvell,kirkwood-mbus",
|
||||||
|
BRIDGE_WINS_BASE, BRIDGE_WINS_SZ,
|
||||||
|
DDR_WINDOW_CPU_BASE, DDR_WINDOW_CPU_SZ);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void __init kirkwood_dt_init(void)
|
static void __init kirkwood_dt_init(void)
|
||||||
@ -91,8 +101,8 @@ static void __init kirkwood_dt_init(void)
|
|||||||
|
|
||||||
kirkwood_cpufreq_init();
|
kirkwood_cpufreq_init();
|
||||||
|
|
||||||
/* Setup root of clk tree */
|
/* Setup clocks for legacy devices */
|
||||||
kirkwood_of_clk_init();
|
kirkwood_legacy_clk_init();
|
||||||
|
|
||||||
kirkwood_cpuidle_init();
|
kirkwood_cpuidle_init();
|
||||||
|
|
||||||
@ -114,9 +124,8 @@ static const char * const kirkwood_dt_board_compat[] = {
|
|||||||
DT_MACHINE_START(KIRKWOOD_DT, "Marvell Kirkwood (Flattened Device Tree)")
|
DT_MACHINE_START(KIRKWOOD_DT, "Marvell Kirkwood (Flattened Device Tree)")
|
||||||
/* Maintainer: Jason Cooper <jason@lakedaemon.net> */
|
/* Maintainer: Jason Cooper <jason@lakedaemon.net> */
|
||||||
.map_io = kirkwood_map_io,
|
.map_io = kirkwood_map_io,
|
||||||
.init_early = kirkwood_init_early,
|
.init_early = kirkwood_dt_init_early,
|
||||||
.init_irq = orion_dt_init_irq,
|
.init_time = kirkwood_dt_time_init,
|
||||||
.init_time = kirkwood_timer_init,
|
|
||||||
.init_machine = kirkwood_dt_init,
|
.init_machine = kirkwood_dt_init,
|
||||||
.restart = kirkwood_restart,
|
.restart = kirkwood_restart,
|
||||||
.dt_compat = kirkwood_dt_board_compat,
|
.dt_compat = kirkwood_dt_board_compat,
|
||||||
|
Loading…
Reference in New Issue
Block a user