ARM: imx: Add MXC_CPU_IMX6ULL and cpu_is_imx6ull
authorLeonard Crestez <leonard.crestez@nxp.com>
Tue, 6 Jun 2017 17:50:42 +0000 (20:50 +0300)
committerShawn Guo <shawnguo@kernel.org>
Wed, 7 Jun 2017 03:38:15 +0000 (11:38 +0800)
Support for imx6ull is already present but it's based on
of_machine_is_compatible("fsl,imx6ull") checks. Add it to the MXC_CPU_*
enumeration as well.

This also fixes /sys/devices/soc0/soc_id reading "Unknown".

Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm/mach-imx/cpu.c
arch/arm/mach-imx/mxc.h

index b3347d32349f6adc947bcacc4d9349ebb75889d2..94906ed4939236b4a3d9a1a4896e57a418b23b98 100644 (file)
@@ -131,6 +131,9 @@ struct device * __init imx_soc_device_init(void)
        case MXC_CPU_IMX6UL:
                soc_id = "i.MX6UL";
                break;
+       case MXC_CPU_IMX6ULL:
+               soc_id = "i.MX6ULL";
+               break;
        case MXC_CPU_IMX7D:
                soc_id = "i.MX7D";
                break;
index 34f2ff62583c6ebc1e93dd1285d6e2b3c83d5e65..e00d6260c3dfb96c25b7a5ab337bec1e108c8e1f 100644 (file)
@@ -39,6 +39,7 @@
 #define MXC_CPU_IMX6SX         0x62
 #define MXC_CPU_IMX6Q          0x63
 #define MXC_CPU_IMX6UL         0x64
+#define MXC_CPU_IMX6ULL                0x65
 #define MXC_CPU_IMX7D          0x72
 
 #define IMX_DDR_TYPE_LPDDR2            1
@@ -73,6 +74,11 @@ static inline bool cpu_is_imx6ul(void)
        return __mxc_cpu_type == MXC_CPU_IMX6UL;
 }
 
+static inline bool cpu_is_imx6ull(void)
+{
+       return __mxc_cpu_type == MXC_CPU_IMX6ULL;
+}
+
 static inline bool cpu_is_imx6q(void)
 {
        return __mxc_cpu_type == MXC_CPU_IMX6Q;