Path: blob/master/arch/powerpc/platforms/52xx/mpc5200_simple.c
26481 views
// SPDX-License-Identifier: GPL-2.0-or-later1/*2* Support for 'mpc5200-simple-platform' compatible boards.3*4* Written by Marian Balakowicz <[email protected]>5* Copyright (C) 2007 Semihalf6*7* Description:8* This code implements support for a simple MPC52xx based boards which9* do not need a custom platform specific setup. Such boards are10* supported assuming the following:11*12* - GPIO pins are configured by the firmware,13* - CDM configuration (clocking) is setup correctly by firmware,14* - if the 'fsl,has-wdt' property is present in one of the15* gpt nodes, then it is safe to use such gpt to reset the board,16* - PCI is supported if enabled in the kernel configuration17* and if there is a PCI bus node defined in the device tree.18*19* Boards that are compatible with this generic platform support20* are listed in a 'board' table.21*/2223#undef DEBUG24#include <linux/of.h>25#include <asm/time.h>26#include <asm/machdep.h>27#include <asm/mpc52xx.h>2829/*30* Setup the architecture31*/32static void __init mpc5200_simple_setup_arch(void)33{34if (ppc_md.progress)35ppc_md.progress("mpc5200_simple_setup_arch()", 0);3637/* Map important registers from the internal memory map */38mpc52xx_map_common_devices();3940/* Some mpc5200 & mpc5200b related configuration */41mpc5200_setup_xlb_arbiter();42}4344/* list of the supported boards */45static const char *board[] __initdata = {46"anonymous,a3m071",47"anonymous,a4m072",48"anon,charon",49"ifm,o2d",50"intercontrol,digsy-mtc",51"manroland,mucmc52",52"manroland,uc101",53"phytec,pcm030",54"phytec,pcm032",55"promess,motionpro",56"schindler,cm5200",57"tqc,tqm5200",58NULL59};6061define_machine(mpc5200_simple_platform) {62.name = "mpc5200-simple-platform",63.compatibles = board,64.setup_arch = mpc5200_simple_setup_arch,65.discover_phbs = mpc52xx_setup_pci,66.init = mpc52xx_declare_of_platform_devices,67.init_IRQ = mpc52xx_init_irq,68.get_irq = mpc52xx_get_irq,69.restart = mpc52xx_restart,70};717273