You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
ARM: OMAP: Split plat/cpu.h into local soc.h for mach-omap1 and mach-omap2
We want to remove plat/cpu.h. To do this, let's first split it to private soc.h to mach-omap1 and mach-omap2. We have to keep plat/cpu.h around until the remaining drivers are fixed, so let's include the local soc.h in plat/cpu.h and for drivers still including plat/cpu.h. Once the drivers are fixed not to include plat/cpu.h, we can remove the file. This is needed for the ARM common zImage support. [tony@atomide.com: updated to not print a warning] Signed-off-by: Tony Lindgren <tony@atomide.com>
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
|
||||
#include <asm/mach-types.h>
|
||||
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
#include <plat/usb.h>
|
||||
|
||||
#include <mach/hardware.h>
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
#include <asm/mach-types.h> /* for machine_is_* */
|
||||
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
|
||||
#include <mach/hardware.h>
|
||||
#include <mach/usb.h> /* for OTG_BASE */
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
#include <linux/i2c-omap.h>
|
||||
#include <mach/mux.h>
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
|
||||
#include "../plat-omap/i2c.h"
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#include <linux/io.h>
|
||||
#include <asm/system_info.h>
|
||||
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
|
||||
#include <mach/hardware.h>
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include <asm/sizes.h>
|
||||
#ifndef __ASSEMBLER__
|
||||
#include <asm/types.h>
|
||||
#include <plat/cpu.h>
|
||||
#include "../../mach-omap1/soc.h"
|
||||
|
||||
/*
|
||||
* NOTE: Please use ioremap + __raw_read/write where possible instead of these
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* because of the strncmp().
|
||||
*/
|
||||
#if defined(CONFIG_ARCH_OMAP15XX) && !defined(__ASSEMBLER__)
|
||||
#include <plat/cpu.h>
|
||||
#include "../../mach-omap1/soc.h"
|
||||
|
||||
/*
|
||||
* OMAP-1510 Local Bus address offset
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include <asm/irq.h>
|
||||
#include <asm/mach/irq.h>
|
||||
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
|
||||
#include <mach/hardware.h>
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
#include <plat-omap/dma-omap.h>
|
||||
#include <mach/mux.h>
|
||||
#include <plat/cpu.h>
|
||||
#include "soc.h"
|
||||
#include <linux/platform_data/asoc-ti-mcbsp.h>
|
||||
|
||||
#include <mach/irqs.h>
|
||||
|
||||
@@ -0,0 +1,229 @@
|
||||
/*
|
||||
* OMAP cpu type detection
|
||||
*
|
||||
* Copyright (C) 2004, 2008 Nokia Corporation
|
||||
*
|
||||
* Copyright (C) 2009-11 Texas Instruments.
|
||||
*
|
||||
* Written by Tony Lindgren <tony.lindgren@nokia.com>
|
||||
*
|
||||
* Added OMAP4/5 specific defines - Santosh Shilimkar<santosh.shilimkar@ti.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __ASM_ARCH_OMAP_CPU_H
|
||||
#define __ASM_ARCH_OMAP_CPU_H
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
#include <linux/bitops.h>
|
||||
|
||||
/*
|
||||
* Test if multicore OMAP support is needed
|
||||
*/
|
||||
#undef MULTI_OMAP1
|
||||
#undef OMAP_NAME
|
||||
|
||||
#ifdef CONFIG_ARCH_OMAP730
|
||||
# ifdef OMAP_NAME
|
||||
# undef MULTI_OMAP1
|
||||
# define MULTI_OMAP1
|
||||
# else
|
||||
# define OMAP_NAME omap730
|
||||
# endif
|
||||
#endif
|
||||
#ifdef CONFIG_ARCH_OMAP850
|
||||
# ifdef OMAP_NAME
|
||||
# undef MULTI_OMAP1
|
||||
# define MULTI_OMAP1
|
||||
# else
|
||||
# define OMAP_NAME omap850
|
||||
# endif
|
||||
#endif
|
||||
#ifdef CONFIG_ARCH_OMAP15XX
|
||||
# ifdef OMAP_NAME
|
||||
# undef MULTI_OMAP1
|
||||
# define MULTI_OMAP1
|
||||
# else
|
||||
# define OMAP_NAME omap1510
|
||||
# endif
|
||||
#endif
|
||||
#ifdef CONFIG_ARCH_OMAP16XX
|
||||
# ifdef OMAP_NAME
|
||||
# undef MULTI_OMAP1
|
||||
# define MULTI_OMAP1
|
||||
# else
|
||||
# define OMAP_NAME omap16xx
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/*
|
||||
* omap_rev bits:
|
||||
* CPU id bits (0730, 1510, 1710, 2422...) [31:16]
|
||||
* CPU revision (See _REV_ defined in cpu.h) [15:08]
|
||||
* CPU class bits (15xx, 16xx, 24xx, 34xx...) [07:00]
|
||||
*/
|
||||
unsigned int omap_rev(void);
|
||||
|
||||
/*
|
||||
* Get the CPU revision for OMAP devices
|
||||
*/
|
||||
#define GET_OMAP_REVISION() ((omap_rev() >> 8) & 0xff)
|
||||
|
||||
/*
|
||||
* Macros to group OMAP into cpu classes.
|
||||
* These can be used in most places.
|
||||
* cpu_is_omap7xx(): True for OMAP730, OMAP850
|
||||
* cpu_is_omap15xx(): True for OMAP1510, OMAP5910 and OMAP310
|
||||
* cpu_is_omap16xx(): True for OMAP1610, OMAP5912 and OMAP1710
|
||||
*/
|
||||
#define GET_OMAP_CLASS (omap_rev() & 0xff)
|
||||
|
||||
#define IS_OMAP_CLASS(class, id) \
|
||||
static inline int is_omap ##class (void) \
|
||||
{ \
|
||||
return (GET_OMAP_CLASS == (id)) ? 1 : 0; \
|
||||
}
|
||||
|
||||
#define GET_OMAP_SUBCLASS ((omap_rev() >> 20) & 0x0fff)
|
||||
|
||||
#define IS_OMAP_SUBCLASS(subclass, id) \
|
||||
static inline int is_omap ##subclass (void) \
|
||||
{ \
|
||||
return (GET_OMAP_SUBCLASS == (id)) ? 1 : 0; \
|
||||
}
|
||||
|
||||
IS_OMAP_CLASS(7xx, 0x07)
|
||||
IS_OMAP_CLASS(15xx, 0x15)
|
||||
IS_OMAP_CLASS(16xx, 0x16)
|
||||
|
||||
#define cpu_is_omap7xx() 0
|
||||
#define cpu_is_omap15xx() 0
|
||||
#define cpu_is_omap16xx() 0
|
||||
|
||||
#if defined(MULTI_OMAP1)
|
||||
# if defined(CONFIG_ARCH_OMAP730)
|
||||
# undef cpu_is_omap7xx
|
||||
# define cpu_is_omap7xx() is_omap7xx()
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP850)
|
||||
# undef cpu_is_omap7xx
|
||||
# define cpu_is_omap7xx() is_omap7xx()
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP15XX)
|
||||
# undef cpu_is_omap15xx
|
||||
# define cpu_is_omap15xx() is_omap15xx()
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP16XX)
|
||||
# undef cpu_is_omap16xx
|
||||
# define cpu_is_omap16xx() is_omap16xx()
|
||||
# endif
|
||||
#else
|
||||
# if defined(CONFIG_ARCH_OMAP730)
|
||||
# undef cpu_is_omap7xx
|
||||
# define cpu_is_omap7xx() 1
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP850)
|
||||
# undef cpu_is_omap7xx
|
||||
# define cpu_is_omap7xx() 1
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP15XX)
|
||||
# undef cpu_is_omap15xx
|
||||
# define cpu_is_omap15xx() 1
|
||||
# endif
|
||||
# if defined(CONFIG_ARCH_OMAP16XX)
|
||||
# undef cpu_is_omap16xx
|
||||
# define cpu_is_omap16xx() 1
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Macros to detect individual cpu types.
|
||||
* These are only rarely needed.
|
||||
* cpu_is_omap310(): True for OMAP310
|
||||
* cpu_is_omap1510(): True for OMAP1510
|
||||
* cpu_is_omap1610(): True for OMAP1610
|
||||
* cpu_is_omap1611(): True for OMAP1611
|
||||
* cpu_is_omap5912(): True for OMAP5912
|
||||
* cpu_is_omap1621(): True for OMAP1621
|
||||
* cpu_is_omap1710(): True for OMAP1710
|
||||
*/
|
||||
#define GET_OMAP_TYPE ((omap_rev() >> 16) & 0xffff)
|
||||
|
||||
#define IS_OMAP_TYPE(type, id) \
|
||||
static inline int is_omap ##type (void) \
|
||||
{ \
|
||||
return (GET_OMAP_TYPE == (id)) ? 1 : 0; \
|
||||
}
|
||||
|
||||
IS_OMAP_TYPE(310, 0x0310)
|
||||
IS_OMAP_TYPE(1510, 0x1510)
|
||||
IS_OMAP_TYPE(1610, 0x1610)
|
||||
IS_OMAP_TYPE(1611, 0x1611)
|
||||
IS_OMAP_TYPE(5912, 0x1611)
|
||||
IS_OMAP_TYPE(1621, 0x1621)
|
||||
IS_OMAP_TYPE(1710, 0x1710)
|
||||
|
||||
#define cpu_is_omap310() 0
|
||||
#define cpu_is_omap1510() 0
|
||||
#define cpu_is_omap1610() 0
|
||||
#define cpu_is_omap5912() 0
|
||||
#define cpu_is_omap1611() 0
|
||||
#define cpu_is_omap1621() 0
|
||||
#define cpu_is_omap1710() 0
|
||||
|
||||
/* These are needed to compile common code */
|
||||
#ifdef CONFIG_ARCH_OMAP1
|
||||
#define cpu_is_omap242x() 0
|
||||
#define cpu_is_omap2430() 0
|
||||
#define cpu_is_omap243x() 0
|
||||
#define cpu_is_omap24xx() 0
|
||||
#define cpu_is_omap34xx() 0
|
||||
#define cpu_is_omap44xx() 0
|
||||
#define soc_is_omap54xx() 0
|
||||
#define soc_is_am33xx() 0
|
||||
#define cpu_class_is_omap1() 1
|
||||
#define cpu_class_is_omap2() 0
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Whether we have MULTI_OMAP1 or not, we still need to distinguish
|
||||
* between 310 vs. 1510 and 1611B/5912 vs. 1710.
|
||||
*/
|
||||
|
||||
#if defined(CONFIG_ARCH_OMAP15XX)
|
||||
# undef cpu_is_omap310
|
||||
# undef cpu_is_omap1510
|
||||
# define cpu_is_omap310() is_omap310()
|
||||
# define cpu_is_omap1510() is_omap1510()
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_ARCH_OMAP16XX)
|
||||
# undef cpu_is_omap1610
|
||||
# undef cpu_is_omap1611
|
||||
# undef cpu_is_omap5912
|
||||
# undef cpu_is_omap1621
|
||||
# undef cpu_is_omap1710
|
||||
# define cpu_is_omap1610() is_omap1610()
|
||||
# define cpu_is_omap1611() is_omap1611()
|
||||
# define cpu_is_omap5912() is_omap5912()
|
||||
# define cpu_is_omap1621() is_omap1621()
|
||||
# define cpu_is_omap1710() is_omap1710()
|
||||
#endif
|
||||
|
||||
#endif /* __ASSEMBLY__ */
|
||||
#endif
|
||||
@@ -39,6 +39,7 @@
|
||||
#include "gpmc.h"
|
||||
#include "gpmc-smc91x.h"
|
||||
|
||||
#include "soc.h"
|
||||
#include "board-flash.h"
|
||||
#include "mux.h"
|
||||
#include "sdram-qimonda-hyb18m512160af-6.h"
|
||||
|
||||
@@ -17,11 +17,10 @@
|
||||
#include <linux/mtd/physmap.h>
|
||||
#include <linux/io.h>
|
||||
|
||||
#include <plat/cpu.h>
|
||||
#include "gpmc.h"
|
||||
#include <linux/platform_data/mtd-nand-omap2.h>
|
||||
#include <linux/platform_data/mtd-onenand-omap2.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "common.h"
|
||||
#include "board-flash.h"
|
||||
#include "gpmc-onenand.h"
|
||||
|
||||
@@ -46,6 +46,7 @@
|
||||
#include <plat/usb.h>
|
||||
#include "omap_device.h"
|
||||
|
||||
#include "soc.h"
|
||||
#include "mux.h"
|
||||
#include "hsmmc.h"
|
||||
#include "pm.h"
|
||||
|
||||
@@ -52,6 +52,7 @@
|
||||
#include <video/omapdss.h>
|
||||
#include <video/omap-panel-tfp410.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "mux.h"
|
||||
#include "sdram-micron-mt46h32m32lf-6.h"
|
||||
#include "hsmmc.h"
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include <video/omapdss.h>
|
||||
#include "board-zoom.h"
|
||||
|
||||
#include "soc.h"
|
||||
#include "common.h"
|
||||
|
||||
#define LCD_PANEL_RESET_GPIO_PROD 96
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
#include <linux/list.h>
|
||||
#include <linux/clk.h>
|
||||
|
||||
#include "am33xx.h"
|
||||
#include "soc.h"
|
||||
#include "iomap.h"
|
||||
#include "control.h"
|
||||
#include "clock.h"
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
|
||||
#include <linux/bitops.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "clock.h"
|
||||
#include "clockdomain.h"
|
||||
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
#include "powerdomain.h"
|
||||
#include "clock.h"
|
||||
#include "omap_hwmod.h"
|
||||
#include <plat/cpu.h>
|
||||
|
||||
/*
|
||||
* Clockdomain flags
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <plat/prcm.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "prm.h"
|
||||
#include "prm2xxx_3xxx.h"
|
||||
#include "cm.h"
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/io.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "clockdomain.h"
|
||||
#include "prm2xxx_3xxx.h"
|
||||
#include "cm2xxx_3xxx.h"
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/io.h>
|
||||
|
||||
#include "soc.h"
|
||||
#include "clockdomain.h"
|
||||
#include "prm2xxx_3xxx.h"
|
||||
#include "cm2xxx_3xxx.h"
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user