Skip to content

Commit

Permalink
common: arm: freescale: layerscape: Move header files out of common.h
Browse files Browse the repository at this point in the history
We should not have an arch-specific header file in common.h. Adjust the
board files a little so it is not needed, and drop it.

Signed-off-by: Simon Glass <[email protected]>
  • Loading branch information
sjg20 authored and trini committed Jun 5, 2017
1 parent 89f5eaa commit 457e51c
Show file tree
Hide file tree
Showing 14 changed files with 33 additions and 12 deletions.
11 changes: 11 additions & 0 deletions arch/arm/include/asm/arch-fsl-layerscape/soc.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,16 @@
#ifndef _ASM_ARMV8_FSL_LAYERSCAPE_SOC_H_
#define _ASM_ARMV8_FSL_LAYERSCAPE_SOC_H_

#ifndef __ASSEMBLY__
#include <linux/types.h>
#ifdef CONFIG_FSL_LSCH2
#include <asm/arch/immap_lsch2.h>
#endif
#ifdef CONFIG_FSL_LSCH3
#include <asm/arch/immap_lsch3.h>
#endif
#endif

#ifdef CONFIG_SYS_FSL_CCSR_GUR_LE
#define gur_in32(a) in_le32(a)
#define gur_out32(a, v) out_le32(a, v)
Expand Down Expand Up @@ -120,4 +130,5 @@ void erratum_a010315(void);
bool soc_has_dp_ddr(void);
bool soc_has_aiop(void);
#endif

#endif /* _ASM_ARMV8_FSL_LAYERSCAPE_SOC_H_ */
1 change: 1 addition & 0 deletions arch/arm/include/asm/arch-ls102xa/clock.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ enum mxc_clock {
};

unsigned int mxc_get_clock(enum mxc_clock clk);
ulong get_ddr_freq(ulong);
uint get_svr(void);

#endif /* __ASM_ARCH_LS102XA_CLOCK_H_ */
Empty file.
3 changes: 2 additions & 1 deletion drivers/ddr/fsl/ctrl_regs.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
#include <fsl_ddr.h>
#include <fsl_immap.h>
#include <asm/io.h>
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3)
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3) || \
defined(CONFIG_ARM)
#include <asm/arch/clock.h>
#endif

Expand Down
3 changes: 2 additions & 1 deletion drivers/ddr/fsl/fsl_ddr_gen4.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
#include <fsl_immap.h>
#include <fsl_ddr.h>
#include <fsl_errata.h>
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3)
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3) || \
defined(CONFIG_ARM)
#include <asm/arch/clock.h>
#endif

Expand Down
3 changes: 2 additions & 1 deletion drivers/ddr/fsl/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
#include <fsl_ddr_sdram.h>

#include <fsl_ddr.h>
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3)
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3) || \
defined(CONFIG_ARM)
#include <asm/arch/clock.h>
#endif

Expand Down
3 changes: 2 additions & 1 deletion drivers/ddr/fsl/util.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
#include <fsl_ddr.h>
#include <fsl_immap.h>
#include <asm/io.h>
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3)
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3) || \
defined(CONFIG_ARM)
#include <asm/arch/clock.h>
#endif

Expand Down
3 changes: 2 additions & 1 deletion drivers/usb/common/fsl-errata.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
#include <common.h>
#include <fsl_errata.h>
#include<fsl_usb.h>
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3)
#if defined(CONFIG_FSL_LSCH2) || defined(CONFIG_FSL_LSCH3) || \
defined(CONFIG_ARM)
#include <asm/arch/clock.h>
#endif

Expand Down
7 changes: 0 additions & 7 deletions include/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,6 @@ typedef volatile unsigned char vu_char;
#include <stdarg.h>
#include <linux/kernel.h>

#ifdef CONFIG_FSL_LSCH3
#include <asm/arch/immap_lsch3.h>
#endif
#ifdef CONFIG_FSL_LSCH2
#include <asm/arch/immap_lsch2.h>
#endif

#include <part.h>
#include <flash.h>
#include <image.h>
Expand Down
2 changes: 2 additions & 0 deletions include/configs/ls1012a_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -121,4 +121,6 @@
#define CONFIG_PANIC_HANG
#define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */

#include <asm/arch/soc.h>

#endif /* __LS1012A_COMMON_H */
2 changes: 2 additions & 0 deletions include/configs/ls1043a_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -300,4 +300,6 @@

#define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */

#include <asm/arch/soc.h>

#endif /* __LS1043A_COMMON_H */
2 changes: 2 additions & 0 deletions include/configs/ls1046a_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -237,4 +237,6 @@

#define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */

#include <asm/arch/soc.h>

#endif /* __LS1046A_COMMON_H */
2 changes: 2 additions & 0 deletions include/configs/ls2080a_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,4 +250,6 @@ unsigned long long get_qixis_addr(void);

#define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */

#include <asm/arch/soc.h>

#endif /* __LS2_COMMON_H */
3 changes: 3 additions & 0 deletions include/fsl_ifc.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
#ifdef CONFIG_FSL_IFC
#include <config.h>
#include <common.h>
#ifdef CONFIG_ARM
#include <asm/arch/soc.h>
#endif

#define FSL_IFC_V1_1_0 0x01010000
#define FSL_IFC_V2_0_0 0x02000000
Expand Down

0 comments on commit 457e51c

Please sign in to comment.