~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/arch/powerpc/platforms/83xx/mpc837x_rdb.c

Version: ~ [ linux-5.2-rc1 ] ~ [ linux-5.1.2 ] ~ [ linux-5.0.16 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.43 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.119 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.176 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.179 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.19.8 ] ~ [ linux-3.18.139 ] ~ [ linux-3.17.8 ] ~ [ linux-3.16.67 ] ~ [ linux-3.15.10 ] ~ [ linux-3.14.79 ] ~ [ linux-3.13.11 ] ~ [ linux-3.12.74 ] ~ [ linux-3.11.10 ] ~ [ linux-3.10.108 ] ~ [ linux-3.9.11 ] ~ [ linux-3.8.13 ] ~ [ linux-3.7.10 ] ~ [ linux-3.6.11 ] ~ [ linux-3.5.7 ] ~ [ linux-3.4.113 ] ~ [ linux-3.3.8 ] ~ [ linux-3.2.102 ] ~ [ linux-3.1.10 ] ~ [ linux-3.0.101 ] ~ [ linux-2.6.39.4 ] ~ [ linux-2.6.38.8 ] ~ [ linux-2.6.37.6 ] ~ [ linux-2.6.36.4 ] ~ [ linux-2.6.35.14 ] ~ [ linux-2.6.34.15 ] ~ [ linux-2.6.33.20 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*
  2  * arch/powerpc/platforms/83xx/mpc837x_rdb.c
  3  *
  4  * Copyright (C) 2007 Freescale Semiconductor, Inc. All rights reserved.
  5  *
  6  * MPC837x RDB board specific routines
  7  *
  8  * This program is free software; you can redistribute  it and/or modify it
  9  * under  the terms of  the GNU General  Public License as published by the
 10  * Free Software Foundation;  either version 2 of the  License, or (at your
 11  * option) any later version.
 12  */
 13 
 14 #include <linux/pci.h>
 15 #include <linux/of_platform.h>
 16 
 17 #include <asm/time.h>
 18 #include <asm/ipic.h>
 19 #include <asm/udbg.h>
 20 #include <sysdev/fsl_soc.h>
 21 #include <sysdev/fsl_pci.h>
 22 
 23 #include "mpc83xx.h"
 24 
 25 static void mpc837x_rdb_sd_cfg(void)
 26 {
 27         void __iomem *im;
 28 
 29         im = ioremap(get_immrbase(), 0x1000);
 30         if (!im) {
 31                 WARN_ON(1);
 32                 return;
 33         }
 34 
 35         /*
 36          * On RDB boards (in contrast to MDS) USBB pins are used for SD only,
 37          * so we can safely mux them away from the USB block.
 38          */
 39         clrsetbits_be32(im + MPC83XX_SICRL_OFFS, MPC837X_SICRL_USBB_MASK,
 40                                                  MPC837X_SICRL_SD);
 41         clrsetbits_be32(im + MPC83XX_SICRH_OFFS, MPC837X_SICRH_SPI_MASK,
 42                                                  MPC837X_SICRH_SD);
 43         iounmap(im);
 44 }
 45 
 46 /* ************************************************************************
 47  *
 48  * Setup the architecture
 49  *
 50  */
 51 static void __init mpc837x_rdb_setup_arch(void)
 52 {
 53         if (ppc_md.progress)
 54                 ppc_md.progress("mpc837x_rdb_setup_arch()", 0);
 55 
 56         mpc83xx_setup_pci();
 57         mpc837x_usb_cfg();
 58         mpc837x_rdb_sd_cfg();
 59 }
 60 
 61 machine_device_initcall(mpc837x_rdb, mpc83xx_declare_of_platform_devices);
 62 
 63 static const char * const board[] __initconst = {
 64         "fsl,mpc8377rdb",
 65         "fsl,mpc8378rdb",
 66         "fsl,mpc8379rdb",
 67         "fsl,mpc8377wlan",
 68         NULL
 69 };
 70 
 71 /*
 72  * Called very early, MMU is off, device-tree isn't unflattened
 73  */
 74 static int __init mpc837x_rdb_probe(void)
 75 {
 76         return of_flat_dt_match(of_get_flat_dt_root(), board);
 77 }
 78 
 79 define_machine(mpc837x_rdb) {
 80         .name                   = "MPC837x RDB/WLAN",
 81         .probe                  = mpc837x_rdb_probe,
 82         .setup_arch             = mpc837x_rdb_setup_arch,
 83         .init_IRQ               = mpc83xx_ipic_init_IRQ,
 84         .get_irq                = ipic_get_irq,
 85         .restart                = mpc83xx_restart,
 86         .time_init              = mpc83xx_time_init,
 87         .calibrate_decr         = generic_calibrate_decr,
 88         .progress               = udbg_progress,
 89 };
 90 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

osdn.jp