All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v11 0/5] soc: fsl: Add initial guts driver
@ 2016-07-17  2:50 Scott Wood
  2016-07-17  2:50 ` [PATCH v11 1/5] dt: bindings: update Freescale DCFG compatible Scott Wood
                   ` (4 more replies)
  0 siblings, 5 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

This patchset adds the beginnings of a driver to consolidate accesses to
the Freescale/NXP "global utilities" block.  Initially only access to SVR
(the system version register) is provided.  This register is needed by
various drivers, mainly for errata detection.  Access to SVR via
mfspr(SPRN_SVR) is now discouraged, especially in drivers that are
not PPC-specific.

I plan to send this via the PPC tree for this merge window, to provide a
base for using/extending the guts driver in various drivers in the next
cycle.

Scott Wood (1):
  powerpc/fsl-pci: Use fsl_guts_get_svr()

Yangbo Lu (2):
  dt: bindings: move guts devicetree doc out of powerpc directory
  soc: fsl: add GUTS driver for QorIQ platforms

yangbo lu (2):
  dt: bindings: update Freescale DCFG compatible
  powerpc/fsl: move mpc85xx.h to include/linux/fsl

 Documentation/devicetree/bindings/arm/fsl.txt      |   6 +-
 .../bindings/{powerpc => soc}/fsl/guts.txt         |   3 +
 arch/powerpc/Kconfig                               |   1 +
 arch/powerpc/kernel/cpu_setup_fsl_booke.S          |   2 +-
 arch/powerpc/platforms/85xx/common.c               |   2 -
 arch/powerpc/sysdev/fsl_pci.c                      |   8 +-
 drivers/clk/clk-qoriq.c                            |   3 +-
 drivers/i2c/busses/i2c-mpc.c                       |   2 +-
 drivers/iommu/fsl_pamu.c                           |   3 +-
 drivers/net/ethernet/freescale/gianfar.c           |   2 +-
 drivers/soc/Kconfig                                |   2 +-
 drivers/soc/fsl/Kconfig                            |   8 ++
 drivers/soc/fsl/Makefile                           |   1 +
 drivers/soc/fsl/guts.c                             | 113 ++++++++++++++++++
 include/linux/fsl/guts.h                           | 126 +++++++++++++--------
 .../asm/mpc85xx.h => include/linux/fsl/svr.h       |   4 +-
 16 files changed, 223 insertions(+), 63 deletions(-)
 rename Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)
 create mode 100644 drivers/soc/fsl/Kconfig
 create mode 100644 drivers/soc/fsl/guts.c
 rename arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h (97%)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 28+ messages in thread

* [PATCH v11 1/5] dt: bindings: update Freescale DCFG compatible
  2016-07-17  2:50 [PATCH v11 0/5] soc: fsl: Add initial guts driver Scott Wood
@ 2016-07-17  2:50 ` Scott Wood
  2016-07-17  2:50   ` Scott Wood
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

From: yangbo lu <yangbo.lu@nxp.com>

Update Freescale DCFG compatible with 'fsl,<chip>-dcfg' instead
of 'fsl,ls1021a-dcfg' to include more chips such as ls1021a,
ls1043a, and ls2080a.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Scott Wood <oss@buserror.net>
---
 Documentation/devicetree/bindings/arm/fsl.txt | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/arm/fsl.txt b/Documentation/devicetree/bindings/arm/fsl.txt
index dbbc095..713c1ae 100644
--- a/Documentation/devicetree/bindings/arm/fsl.txt
+++ b/Documentation/devicetree/bindings/arm/fsl.txt
@@ -119,7 +119,11 @@ Freescale DCFG
 configuration and status for the device. Such as setting the secondary
 core start address and release the secondary core from holdoff and startup.
   Required properties:
-  - compatible: should be "fsl,ls1021a-dcfg"
+  - compatible: should be "fsl,<chip>-dcfg"
+    Possible compatibles:
+	"fsl,ls1021a-dcfg"
+	"fsl,ls1043a-dcfg"
+	"fsl,ls2080a-dcfg"
   - reg : should contain base address and length of DCFG memory-mapped registers
 
 Example:
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 2/5] dt: bindings: move guts devicetree doc out of powerpc directory
@ 2016-07-17  2:50   ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

From: Yangbo Lu <yangbo.lu@nxp.com>

Move guts devicetree doc to Documentation/devicetree/bindings/soc/fsl/
since it's used by not only PowerPC but also ARM. And add a specification
for 'little-endian' property.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Scott Wood <oss@buserror.net>
---
 Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt | 3 +++
 1 file changed, 3 insertions(+)
 rename Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)

diff --git a/Documentation/devicetree/bindings/powerpc/fsl/guts.txt b/Documentation/devicetree/bindings/soc/fsl/guts.txt
similarity index 91%
rename from Documentation/devicetree/bindings/powerpc/fsl/guts.txt
rename to Documentation/devicetree/bindings/soc/fsl/guts.txt
index b71b203..07adca9 100644
--- a/Documentation/devicetree/bindings/powerpc/fsl/guts.txt
+++ b/Documentation/devicetree/bindings/soc/fsl/guts.txt
@@ -25,6 +25,9 @@ Recommended properties:
  - fsl,liodn-bits : Indicates the number of defined bits in the LIODN
    registers, for those SOCs that have a PAMU device.
 
+ - little-endian : Indicates that the global utilities block is little
+   endian. The default is big endian.
+
 Examples:
 	global-utilities@e0000 {	/* global utilities block */
 		compatible = "fsl,mpc8548-guts";
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 2/5] dt: bindings: move guts devicetree doc out of powerpc directory
@ 2016-07-17  2:50   ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ
  Cc: Yangbo Lu, linux-mmc-u79uwXL29TY76Z2rM5mHXA, Arnd Bergmann,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Scott Wood

From: Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>

Move guts devicetree doc to Documentation/devicetree/bindings/soc/fsl/
since it's used by not only PowerPC but also ARM. And add a specification
for 'little-endian' property.

Signed-off-by: Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>
Acked-by: Rob Herring <robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Signed-off-by: Scott Wood <oss-fOR+EgIDQEHk1uMJSBkQmQ@public.gmane.org>
---
 Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt | 3 +++
 1 file changed, 3 insertions(+)
 rename Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)

diff --git a/Documentation/devicetree/bindings/powerpc/fsl/guts.txt b/Documentation/devicetree/bindings/soc/fsl/guts.txt
similarity index 91%
rename from Documentation/devicetree/bindings/powerpc/fsl/guts.txt
rename to Documentation/devicetree/bindings/soc/fsl/guts.txt
index b71b203..07adca9 100644
--- a/Documentation/devicetree/bindings/powerpc/fsl/guts.txt
+++ b/Documentation/devicetree/bindings/soc/fsl/guts.txt
@@ -25,6 +25,9 @@ Recommended properties:
  - fsl,liodn-bits : Indicates the number of defined bits in the LIODN
    registers, for those SOCs that have a PAMU device.
 
+ - little-endian : Indicates that the global utilities block is little
+   endian. The default is big endian.
+
 Examples:
 	global-utilities@e0000 {	/* global utilities block */
 		compatible = "fsl,mpc8548-guts";
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 3/5] soc: fsl: add GUTS driver for QorIQ platforms
  2016-07-17  2:50 [PATCH v11 0/5] soc: fsl: Add initial guts driver Scott Wood
  2016-07-17  2:50 ` [PATCH v11 1/5] dt: bindings: update Freescale DCFG compatible Scott Wood
  2016-07-17  2:50   ` Scott Wood
@ 2016-07-17  2:50 ` Scott Wood
  2016-07-17  2:50   ` Scott Wood
  2016-07-17  2:50 ` [PATCH v11 5/5] powerpc/fsl-pci: Use fsl_guts_get_svr() Scott Wood
  4 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

From: Yangbo Lu <yangbo.lu@nxp.com>

The global utilities block controls power management, I/O device
enabling, power-onreset(POR) configuration monitoring, alternate
function selection for multiplexed signals,and clock control.

This patch adds a driver to manage and access global utilities block.
Initially only reading SVR is supported.  Other guts accesses, such as
reading RCW, should eventually be moved into this driver as well.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
[scottwood: minor cleanup]
Signed-off-by: Scott Wood <oss@buserror.net>
---
 arch/powerpc/platforms/85xx/common.c |   2 -
 drivers/soc/Kconfig                  |   2 +-
 drivers/soc/fsl/Kconfig              |   8 +++
 drivers/soc/fsl/Makefile             |   1 +
 drivers/soc/fsl/guts.c               | 113 +++++++++++++++++++++++++++++++
 include/linux/fsl/guts.h             | 126 ++++++++++++++++++++++-------------
 6 files changed, 201 insertions(+), 51 deletions(-)
 create mode 100644 drivers/soc/fsl/Kconfig
 create mode 100644 drivers/soc/fsl/guts.c

diff --git a/arch/powerpc/platforms/85xx/common.c b/arch/powerpc/platforms/85xx/common.c
index 28720a4..badd193 100644
--- a/arch/powerpc/platforms/85xx/common.c
+++ b/arch/powerpc/platforms/85xx/common.c
@@ -29,8 +29,6 @@ static const struct of_device_id mpc85xx_common_ids[] __initconst = {
 	{ .compatible = "fsl,srio", },
 	/* So that the DMA channel nodes can be probed individually: */
 	{ .compatible = "fsl,eloplus-dma", },
-	/* For the PMC driver */
-	{ .compatible = "fsl,mpc8548-guts", },
 	/* Probably unnecessary? */
 	{ .compatible = "gpio-leds", },
 	/* For all PCI controllers */
diff --git a/drivers/soc/Kconfig b/drivers/soc/Kconfig
index cb58ef0..7106463 100644
--- a/drivers/soc/Kconfig
+++ b/drivers/soc/Kconfig
@@ -2,7 +2,7 @@ menu "SOC (System On Chip) specific Drivers"
 
 source "drivers/soc/bcm/Kconfig"
 source "drivers/soc/brcmstb/Kconfig"
-source "drivers/soc/fsl/qe/Kconfig"
+source "drivers/soc/fsl/Kconfig"
 source "drivers/soc/mediatek/Kconfig"
 source "drivers/soc/qcom/Kconfig"
 source "drivers/soc/rockchip/Kconfig"
diff --git a/drivers/soc/fsl/Kconfig b/drivers/soc/fsl/Kconfig
new file mode 100644
index 0000000..b313759
--- /dev/null
+++ b/drivers/soc/fsl/Kconfig
@@ -0,0 +1,8 @@
+#
+# Freescale SOC drivers
+#
+
+source "drivers/soc/fsl/qe/Kconfig"
+
+config FSL_GUTS
+	bool
diff --git a/drivers/soc/fsl/Makefile b/drivers/soc/fsl/Makefile
index 203307f..02afb7f 100644
--- a/drivers/soc/fsl/Makefile
+++ b/drivers/soc/fsl/Makefile
@@ -4,3 +4,4 @@
 
 obj-$(CONFIG_QUICC_ENGINE)		+= qe/
 obj-$(CONFIG_CPM)			+= qe/
+obj-$(CONFIG_FSL_GUTS)			+= guts.o
diff --git a/drivers/soc/fsl/guts.c b/drivers/soc/fsl/guts.c
new file mode 100644
index 0000000..b534654
--- /dev/null
+++ b/drivers/soc/fsl/guts.c
@@ -0,0 +1,113 @@
+/*
+ * Freescale QorIQ Platforms GUTS Driver
+ *
+ * Copyright (C) 2016 Freescale Semiconductor, Inc.
+ *
+ * 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.
+ */
+
+#include <linux/io.h>
+#include <linux/slab.h>
+#include <linux/mutex.h>
+#include <linux/of_address.h>
+#include <linux/of_platform.h>
+#include <linux/fsl/guts.h>
+
+struct guts {
+	struct ccsr_guts __iomem *regs;
+	bool little_endian;
+};
+
+static struct guts *guts;
+static DEFINE_MUTEX(guts_lock);
+
+u32 fsl_guts_get_svr(void)
+{
+	u32 svr = 0;
+
+	if (!guts || !guts->regs) {
+#ifdef CONFIG_PPC
+		svr =  mfspr(SPRN_SVR);
+#endif
+		return svr;
+	}
+
+	if (guts->little_endian)
+		svr = ioread32(&guts->regs->svr);
+	else
+		svr = ioread32be(&guts->regs->svr);
+
+	return svr;
+}
+EXPORT_SYMBOL(fsl_guts_get_svr);
+
+/*
+ * Table for matching compatible strings, for device tree
+ * guts node, for Freescale QorIQ SOCs.
+ */
+static const struct of_device_id guts_of_match[] = {
+	{ .compatible = "fsl,qoriq-device-config-1.0", },
+	{ .compatible = "fsl,qoriq-device-config-2.0", },
+	{ .compatible = "fsl,p1010-guts", },
+	{ .compatible = "fsl,p1020-guts", },
+	{ .compatible = "fsl,p1021-guts", },
+	{ .compatible = "fsl,p1022-guts", },
+	{ .compatible = "fsl,p1023-guts", },
+	{ .compatible = "fsl,p2020-guts", },
+	{ .compatible = "fsl,bsc9131-guts", },
+	{ .compatible = "fsl,bsc9132-guts", },
+	{ .compatible = "fsl,mpc8536-guts", },
+	{ .compatible = "fsl,mpc8544-guts", },
+	{ .compatible = "fsl,mpc8548-guts", },
+	{ .compatible = "fsl,mpc8568-guts", },
+	{ .compatible = "fsl,mpc8569-guts", },
+	{ .compatible = "fsl,mpc8572-guts", },
+	{ .compatible = "fsl,ls1021a-dcfg", },
+	{ .compatible = "fsl,ls1043a-dcfg", },
+	{ .compatible = "fsl,ls2080a-dcfg", },
+	{}
+};
+
+int fsl_guts_init(void)
+{
+	struct device_node *np;
+	int ret;
+
+	mutex_lock(&guts_lock);
+	/* Initialize guts only once */
+	if (guts) {
+		ret = guts->regs ? 0 : -ENOMEM;
+		goto out;
+	}
+
+	np = of_find_matching_node(NULL, guts_of_match);
+	if (!np) {
+		ret = -ENODEV;
+		goto out;
+	}
+
+	guts = kzalloc(sizeof(*guts), GFP_KERNEL);
+	if (!guts) {
+		ret = -ENOMEM;
+		goto out_np;
+	}
+
+	guts->little_endian = of_property_read_bool(np, "little-endian");
+
+	guts->regs = of_iomap(np, 0);
+	if (!guts->regs) {
+		ret = -ENOMEM;
+		goto out_np;
+	}
+
+	ret = 0;
+out_np:
+	of_node_put(np);
+out:
+	mutex_unlock(&guts_lock);
+	return ret;
+}
+EXPORT_SYMBOL(fsl_guts_init);
diff --git a/include/linux/fsl/guts.h b/include/linux/fsl/guts.h
index 649e917..7e1e22b 100644
--- a/include/linux/fsl/guts.h
+++ b/include/linux/fsl/guts.h
@@ -29,83 +29,113 @@
  * #ifdefs.
  */
 struct ccsr_guts {
-	__be32	porpllsr;	/* 0x.0000 - POR PLL Ratio Status Register */
-	__be32	porbmsr;	/* 0x.0004 - POR Boot Mode Status Register */
-	__be32	porimpscr;	/* 0x.0008 - POR I/O Impedance Status and Control Register */
-	__be32	pordevsr;	/* 0x.000c - POR I/O Device Status Register */
-	__be32	pordbgmsr;	/* 0x.0010 - POR Debug Mode Status Register */
-	__be32	pordevsr2;	/* 0x.0014 - POR device status register 2 */
+	u32	porpllsr;	/* 0x.0000 - POR PLL Ratio Status Register */
+	u32	porbmsr;	/* 0x.0004 - POR Boot Mode Status Register */
+	u32	porimpscr;	/* 0x.0008 - POR I/O Impedance Status and
+				 *           Control Register
+				 */
+	u32	pordevsr;	/* 0x.000c - POR I/O Device Status Register */
+	u32	pordbgmsr;	/* 0x.0010 - POR Debug Mode Status Register */
+	u32	pordevsr2;	/* 0x.0014 - POR device status register 2 */
 	u8	res018[0x20 - 0x18];
-	__be32	porcir;		/* 0x.0020 - POR Configuration Information Register */
+	u32	porcir;		/* 0x.0020 - POR Configuration Information
+				 *           Register
+				 */
 	u8	res024[0x30 - 0x24];
-	__be32	gpiocr;		/* 0x.0030 - GPIO Control Register */
+	u32	gpiocr;		/* 0x.0030 - GPIO Control Register */
 	u8	res034[0x40 - 0x34];
-	__be32	gpoutdr;	/* 0x.0040 - General-Purpose Output Data Register */
+	u32	gpoutdr;	/* 0x.0040 - General-Purpose Output Data
+				 *           Register
+				 */
 	u8	res044[0x50 - 0x44];
-	__be32	gpindr;		/* 0x.0050 - General-Purpose Input Data Register */
+	u32	gpindr;		/* 0x.0050 - General-Purpose Input Data
+				 *           Register
+				 */
 	u8	res054[0x60 - 0x54];
-	__be32	pmuxcr;		/* 0x.0060 - Alternate Function Signal Multiplex Control */
-        __be32  pmuxcr2;	/* 0x.0064 - Alternate function signal multiplex control 2 */
-        __be32  dmuxcr;		/* 0x.0068 - DMA Mux Control Register */
+	u32	pmuxcr;		/* 0x.0060 - Alternate Function Signal
+				 *           Multiplex Control
+				 */
+	u32	pmuxcr2;	/* 0x.0064 - Alternate function signal
+				 *           multiplex control 2
+				 */
+	u32	dmuxcr;		/* 0x.0068 - DMA Mux Control Register */
         u8	res06c[0x70 - 0x6c];
-	__be32	devdisr;	/* 0x.0070 - Device Disable Control */
+	u32	devdisr;	/* 0x.0070 - Device Disable Control */
 #define CCSR_GUTS_DEVDISR_TB1	0x00001000
 #define CCSR_GUTS_DEVDISR_TB0	0x00004000
-	__be32	devdisr2;	/* 0x.0074 - Device Disable Control 2 */
+	u32	devdisr2;	/* 0x.0074 - Device Disable Control 2 */
 	u8	res078[0x7c - 0x78];
-	__be32  pmjcr;		/* 0x.007c - 4 Power Management Jog Control Register */
-	__be32	powmgtcsr;	/* 0x.0080 - Power Management Status and Control Register */
-	__be32  pmrccr;		/* 0x.0084 - Power Management Reset Counter Configuration Register */
-	__be32  pmpdccr;	/* 0x.0088 - Power Management Power Down Counter Configuration Register */
-	__be32  pmcdr;		/* 0x.008c - 4Power management clock disable register */
-	__be32	mcpsumr;	/* 0x.0090 - Machine Check Summary Register */
-	__be32	rstrscr;	/* 0x.0094 - Reset Request Status and Control Register */
-	__be32  ectrstcr;	/* 0x.0098 - Exception reset control register */
-	__be32  autorstsr;	/* 0x.009c - Automatic reset status register */
-	__be32	pvr;		/* 0x.00a0 - Processor Version Register */
-	__be32	svr;		/* 0x.00a4 - System Version Register */
+	u32	pmjcr;		/* 0x.007c - 4 Power Management Jog Control
+				 *           Register
+				 */
+	u32	powmgtcsr;	/* 0x.0080 - Power Management Status and
+				 *           Control Register
+				 */
+	u32	pmrccr;		/* 0x.0084 - Power Management Reset Counter
+				 *           Configuration Register
+				 */
+	u32	pmpdccr;	/* 0x.0088 - Power Management Power Down Counter
+				 *           Configuration Register
+				 */
+	u32	pmcdr;		/* 0x.008c - 4Power management clock disable
+				 *           register
+				 */
+	u32	mcpsumr;	/* 0x.0090 - Machine Check Summary Register */
+	u32	rstrscr;	/* 0x.0094 - Reset Request Status and
+				 *           Control Register
+				 */
+	u32	ectrstcr;	/* 0x.0098 - Exception reset control register */
+	u32	autorstsr;	/* 0x.009c - Automatic reset status register */
+	u32	pvr;		/* 0x.00a0 - Processor Version Register */
+	u32	svr;		/* 0x.00a4 - System Version Register */
 	u8	res0a8[0xb0 - 0xa8];
-	__be32	rstcr;		/* 0x.00b0 - Reset Control Register */
+	u32	rstcr;		/* 0x.00b0 - Reset Control Register */
 	u8	res0b4[0xc0 - 0xb4];
-	__be32  iovselsr;	/* 0x.00c0 - I/O voltage select status register
+	u32	iovselsr;	/* 0x.00c0 - I/O voltage select status register
 					     Called 'elbcvselcr' on 86xx SOCs */
 	u8	res0c4[0x100 - 0xc4];
-	__be32	rcwsr[16];	/* 0x.0100 - Reset Control Word Status registers
+	u32	rcwsr[16];	/* 0x.0100 - Reset Control Word Status registers
 					     There are 16 registers */
 	u8	res140[0x224 - 0x140];
-	__be32  iodelay1;	/* 0x.0224 - IO delay control register 1 */
-	__be32  iodelay2;	/* 0x.0228 - IO delay control register 2 */
+	u32	iodelay1;	/* 0x.0224 - IO delay control register 1 */
+	u32	iodelay2;	/* 0x.0228 - IO delay control register 2 */
 	u8	res22c[0x604 - 0x22c];
-	__be32	pamubypenr; 	/* 0x.604 - PAMU bypass enable register */
+	u32	pamubypenr;	/* 0x.604 - PAMU bypass enable register */
 	u8	res608[0x800 - 0x608];
-	__be32	clkdvdr;	/* 0x.0800 - Clock Divide Register */
+	u32	clkdvdr;	/* 0x.0800 - Clock Divide Register */
 	u8	res804[0x900 - 0x804];
-	__be32	ircr;		/* 0x.0900 - Infrared Control Register */
+	u32	ircr;		/* 0x.0900 - Infrared Control Register */
 	u8	res904[0x908 - 0x904];
-	__be32	dmacr;		/* 0x.0908 - DMA Control Register */
+	u32	dmacr;		/* 0x.0908 - DMA Control Register */
 	u8	res90c[0x914 - 0x90c];
-	__be32	elbccr;		/* 0x.0914 - eLBC Control Register */
+	u32	elbccr;		/* 0x.0914 - eLBC Control Register */
 	u8	res918[0xb20 - 0x918];
-	__be32	ddr1clkdr;	/* 0x.0b20 - DDR1 Clock Disable Register */
-	__be32	ddr2clkdr;	/* 0x.0b24 - DDR2 Clock Disable Register */
-	__be32	ddrclkdr;	/* 0x.0b28 - DDR Clock Disable Register */
+	u32	ddr1clkdr;	/* 0x.0b20 - DDR1 Clock Disable Register */
+	u32	ddr2clkdr;	/* 0x.0b24 - DDR2 Clock Disable Register */
+	u32	ddrclkdr;	/* 0x.0b28 - DDR Clock Disable Register */
 	u8	resb2c[0xe00 - 0xb2c];
-	__be32	clkocr;		/* 0x.0e00 - Clock Out Select Register */
+	u32	clkocr;		/* 0x.0e00 - Clock Out Select Register */
 	u8	rese04[0xe10 - 0xe04];
-	__be32	ddrdllcr;	/* 0x.0e10 - DDR DLL Control Register */
+	u32	ddrdllcr;	/* 0x.0e10 - DDR DLL Control Register */
 	u8	rese14[0xe20 - 0xe14];
-	__be32	lbcdllcr;	/* 0x.0e20 - LBC DLL Control Register */
-	__be32  cpfor;		/* 0x.0e24 - L2 charge pump fuse override register */
+	u32	lbcdllcr;	/* 0x.0e20 - LBC DLL Control Register */
+	u32	cpfor;		/* 0x.0e24 - L2 charge pump fuse override
+				 *           register
+				 */
 	u8	rese28[0xf04 - 0xe28];
-	__be32	srds1cr0;	/* 0x.0f04 - SerDes1 Control Register 0 */
-	__be32	srds1cr1;	/* 0x.0f08 - SerDes1 Control Register 0 */
+	u32	srds1cr0;	/* 0x.0f04 - SerDes1 Control Register 0 */
+	u32	srds1cr1;	/* 0x.0f08 - SerDes1 Control Register 0 */
 	u8	resf0c[0xf2c - 0xf0c];
-	__be32  itcr;		/* 0x.0f2c - Internal transaction control register */
+	u32	itcr;		/* 0x.0f2c - Internal transaction control
+				 *           register
+				 */
 	u8	resf30[0xf40 - 0xf30];
-	__be32	srds2cr0;	/* 0x.0f40 - SerDes2 Control Register 0 */
-	__be32	srds2cr1;	/* 0x.0f44 - SerDes2 Control Register 0 */
+	u32	srds2cr0;	/* 0x.0f40 - SerDes2 Control Register 0 */
+	u32	srds2cr1;	/* 0x.0f44 - SerDes2 Control Register 0 */
 } __attribute__ ((packed));
 
+u32 fsl_guts_get_svr(void);
+int fsl_guts_init(void);
 
 /* Alternate function signal multiplex control */
 #define MPC85xx_PMUXCR_QE(x) (0x8000 >> (x))
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-17  2:50   ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

From: yangbo lu <yangbo.lu@nxp.com>

Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
header file.  This SVR numberspace is used on some ARM chips as well as
PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
need to ifdef the header inclusion and all references to the SVR symbols.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Acked-by: Wolfram Sang <wsa@the-dreams.de>
Acked-by: Stephen Boyd <sboyd@codeaurora.org>
Acked-by: Joerg Roedel <jroedel@suse.de>
[scottwood: update description]
Signed-off-by: Scott Wood <oss@buserror.net>
---
 arch/powerpc/kernel/cpu_setup_fsl_booke.S                     | 2 +-
 arch/powerpc/sysdev/fsl_pci.c                                 | 2 +-
 drivers/clk/clk-qoriq.c                                       | 3 +--
 drivers/i2c/busses/i2c-mpc.c                                  | 2 +-
 drivers/iommu/fsl_pamu.c                                      | 3 +--
 drivers/net/ethernet/freescale/gianfar.c                      | 2 +-
 arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h | 4 ++--
 7 files changed, 8 insertions(+), 10 deletions(-)
 rename arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h (97%)

diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
index 462aed9..2b0284e 100644
--- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
+++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
@@ -13,13 +13,13 @@
  *
  */
 
+#include <linux/fsl/svr.h>
 #include <asm/page.h>
 #include <asm/processor.h>
 #include <asm/cputable.h>
 #include <asm/ppc_asm.h>
 #include <asm/mmu-book3e.h>
 #include <asm/asm-offsets.h>
-#include <asm/mpc85xx.h>
 
 _GLOBAL(__e500_icache_setup)
 	mfspr	r0, SPRN_L1CSR1
diff --git a/arch/powerpc/sysdev/fsl_pci.c b/arch/powerpc/sysdev/fsl_pci.c
index 0ef9df4..0fd1895 100644
--- a/arch/powerpc/sysdev/fsl_pci.c
+++ b/arch/powerpc/sysdev/fsl_pci.c
@@ -22,6 +22,7 @@
 #include <linux/delay.h>
 #include <linux/string.h>
 #include <linux/fsl/edac.h>
+#include <linux/fsl/svr.h>
 #include <linux/init.h>
 #include <linux/interrupt.h>
 #include <linux/memblock.h>
@@ -37,7 +38,6 @@
 #include <asm/pci-bridge.h>
 #include <asm/ppc-pci.h>
 #include <asm/machdep.h>
-#include <asm/mpc85xx.h>
 #include <asm/disassemble.h>
 #include <asm/ppc-opcode.h>
 #include <sysdev/fsl_soc.h>
diff --git a/drivers/clk/clk-qoriq.c b/drivers/clk/clk-qoriq.c
index 58566a17..4b6c438 100644
--- a/drivers/clk/clk-qoriq.c
+++ b/drivers/clk/clk-qoriq.c
@@ -13,6 +13,7 @@
 #include <linux/clk.h>
 #include <linux/clk-provider.h>
 #include <linux/fsl/guts.h>
+#include <linux/fsl/svr.h>
 #include <linux/io.h>
 #include <linux/kernel.h>
 #include <linux/module.h>
@@ -1149,8 +1150,6 @@ bad_args:
 }
 
 #ifdef CONFIG_PPC
-#include <asm/mpc85xx.h>
-
 static const u32 a4510_svrs[] __initconst = {
 	(SVR_P2040 << 8) | 0x10,	/* P2040 1.0 */
 	(SVR_P2040 << 8) | 0x11,	/* P2040 1.1 */
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 48ecffe..600704c 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -27,9 +27,9 @@
 #include <linux/i2c.h>
 #include <linux/interrupt.h>
 #include <linux/delay.h>
+#include <linux/fsl/svr.h>
 
 #include <asm/mpc52xx.h>
-#include <asm/mpc85xx.h>
 #include <sysdev/fsl_soc.h>
 
 #define DRV_NAME "mpc-i2c"
diff --git a/drivers/iommu/fsl_pamu.c b/drivers/iommu/fsl_pamu.c
index a34355f..af8fb27 100644
--- a/drivers/iommu/fsl_pamu.c
+++ b/drivers/iommu/fsl_pamu.c
@@ -21,11 +21,10 @@
 #include "fsl_pamu.h"
 
 #include <linux/fsl/guts.h>
+#include <linux/fsl/svr.h>
 #include <linux/interrupt.h>
 #include <linux/genalloc.h>
 
-#include <asm/mpc85xx.h>
-
 /* define indexes for each operation mapping scenario */
 #define OMI_QMAN        0x00
 #define OMI_FMAN        0x01
diff --git a/drivers/net/ethernet/freescale/gianfar.c b/drivers/net/ethernet/freescale/gianfar.c
index 2e6785b..450d31f 100644
--- a/drivers/net/ethernet/freescale/gianfar.c
+++ b/drivers/net/ethernet/freescale/gianfar.c
@@ -86,11 +86,11 @@
 #include <linux/udp.h>
 #include <linux/in.h>
 #include <linux/net_tstamp.h>
+#include <linux/fsl/svr.h>
 
 #include <asm/io.h>
 #ifdef CONFIG_PPC
 #include <asm/reg.h>
-#include <asm/mpc85xx.h>
 #endif
 #include <asm/irq.h>
 #include <asm/uaccess.h>
diff --git a/arch/powerpc/include/asm/mpc85xx.h b/include/linux/fsl/svr.h
similarity index 97%
rename from arch/powerpc/include/asm/mpc85xx.h
rename to include/linux/fsl/svr.h
index 213f3a8..8d13836 100644
--- a/arch/powerpc/include/asm/mpc85xx.h
+++ b/include/linux/fsl/svr.h
@@ -9,8 +9,8 @@
  * (at your option) any later version.
  */
 
-#ifndef __ASM_PPC_MPC85XX_H
-#define __ASM_PPC_MPC85XX_H
+#ifndef FSL_SVR_H
+#define FSL_SVR_H
 
 #define SVR_REV(svr)	((svr) & 0xFF)		/* SOC design resision */
 #define SVR_MAJ(svr)	(((svr) >>  4) & 0xF)	/* Major revision field*/
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-17  2:50   ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ
  Cc: Yangbo Lu, linux-mmc-u79uwXL29TY76Z2rM5mHXA, Arnd Bergmann,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Scott Wood

From: yangbo lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>

Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
header file.  This SVR numberspace is used on some ARM chips as well as
PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
need to ifdef the header inclusion and all references to the SVR symbols.

Signed-off-by: Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>
Acked-by: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
Acked-by: Stephen Boyd <sboyd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
Acked-by: Joerg Roedel <jroedel-l3A5Bk7waGM@public.gmane.org>
[scottwood: update description]
Signed-off-by: Scott Wood <oss-fOR+EgIDQEHk1uMJSBkQmQ@public.gmane.org>
---
 arch/powerpc/kernel/cpu_setup_fsl_booke.S                     | 2 +-
 arch/powerpc/sysdev/fsl_pci.c                                 | 2 +-
 drivers/clk/clk-qoriq.c                                       | 3 +--
 drivers/i2c/busses/i2c-mpc.c                                  | 2 +-
 drivers/iommu/fsl_pamu.c                                      | 3 +--
 drivers/net/ethernet/freescale/gianfar.c                      | 2 +-
 arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h | 4 ++--
 7 files changed, 8 insertions(+), 10 deletions(-)
 rename arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h (97%)

diff --git a/arch/powerpc/kernel/cpu_setup_fsl_booke.S b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
index 462aed9..2b0284e 100644
--- a/arch/powerpc/kernel/cpu_setup_fsl_booke.S
+++ b/arch/powerpc/kernel/cpu_setup_fsl_booke.S
@@ -13,13 +13,13 @@
  *
  */
 
+#include <linux/fsl/svr.h>
 #include <asm/page.h>
 #include <asm/processor.h>
 #include <asm/cputable.h>
 #include <asm/ppc_asm.h>
 #include <asm/mmu-book3e.h>
 #include <asm/asm-offsets.h>
-#include <asm/mpc85xx.h>
 
 _GLOBAL(__e500_icache_setup)
 	mfspr	r0, SPRN_L1CSR1
diff --git a/arch/powerpc/sysdev/fsl_pci.c b/arch/powerpc/sysdev/fsl_pci.c
index 0ef9df4..0fd1895 100644
--- a/arch/powerpc/sysdev/fsl_pci.c
+++ b/arch/powerpc/sysdev/fsl_pci.c
@@ -22,6 +22,7 @@
 #include <linux/delay.h>
 #include <linux/string.h>
 #include <linux/fsl/edac.h>
+#include <linux/fsl/svr.h>
 #include <linux/init.h>
 #include <linux/interrupt.h>
 #include <linux/memblock.h>
@@ -37,7 +38,6 @@
 #include <asm/pci-bridge.h>
 #include <asm/ppc-pci.h>
 #include <asm/machdep.h>
-#include <asm/mpc85xx.h>
 #include <asm/disassemble.h>
 #include <asm/ppc-opcode.h>
 #include <sysdev/fsl_soc.h>
diff --git a/drivers/clk/clk-qoriq.c b/drivers/clk/clk-qoriq.c
index 58566a17..4b6c438 100644
--- a/drivers/clk/clk-qoriq.c
+++ b/drivers/clk/clk-qoriq.c
@@ -13,6 +13,7 @@
 #include <linux/clk.h>
 #include <linux/clk-provider.h>
 #include <linux/fsl/guts.h>
+#include <linux/fsl/svr.h>
 #include <linux/io.h>
 #include <linux/kernel.h>
 #include <linux/module.h>
@@ -1149,8 +1150,6 @@ bad_args:
 }
 
 #ifdef CONFIG_PPC
-#include <asm/mpc85xx.h>
-
 static const u32 a4510_svrs[] __initconst = {
 	(SVR_P2040 << 8) | 0x10,	/* P2040 1.0 */
 	(SVR_P2040 << 8) | 0x11,	/* P2040 1.1 */
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 48ecffe..600704c 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -27,9 +27,9 @@
 #include <linux/i2c.h>
 #include <linux/interrupt.h>
 #include <linux/delay.h>
+#include <linux/fsl/svr.h>
 
 #include <asm/mpc52xx.h>
-#include <asm/mpc85xx.h>
 #include <sysdev/fsl_soc.h>
 
 #define DRV_NAME "mpc-i2c"
diff --git a/drivers/iommu/fsl_pamu.c b/drivers/iommu/fsl_pamu.c
index a34355f..af8fb27 100644
--- a/drivers/iommu/fsl_pamu.c
+++ b/drivers/iommu/fsl_pamu.c
@@ -21,11 +21,10 @@
 #include "fsl_pamu.h"
 
 #include <linux/fsl/guts.h>
+#include <linux/fsl/svr.h>
 #include <linux/interrupt.h>
 #include <linux/genalloc.h>
 
-#include <asm/mpc85xx.h>
-
 /* define indexes for each operation mapping scenario */
 #define OMI_QMAN        0x00
 #define OMI_FMAN        0x01
diff --git a/drivers/net/ethernet/freescale/gianfar.c b/drivers/net/ethernet/freescale/gianfar.c
index 2e6785b..450d31f 100644
--- a/drivers/net/ethernet/freescale/gianfar.c
+++ b/drivers/net/ethernet/freescale/gianfar.c
@@ -86,11 +86,11 @@
 #include <linux/udp.h>
 #include <linux/in.h>
 #include <linux/net_tstamp.h>
+#include <linux/fsl/svr.h>
 
 #include <asm/io.h>
 #ifdef CONFIG_PPC
 #include <asm/reg.h>
-#include <asm/mpc85xx.h>
 #endif
 #include <asm/irq.h>
 #include <asm/uaccess.h>
diff --git a/arch/powerpc/include/asm/mpc85xx.h b/include/linux/fsl/svr.h
similarity index 97%
rename from arch/powerpc/include/asm/mpc85xx.h
rename to include/linux/fsl/svr.h
index 213f3a8..8d13836 100644
--- a/arch/powerpc/include/asm/mpc85xx.h
+++ b/include/linux/fsl/svr.h
@@ -9,8 +9,8 @@
  * (at your option) any later version.
  */
 
-#ifndef __ASM_PPC_MPC85XX_H
-#define __ASM_PPC_MPC85XX_H
+#ifndef FSL_SVR_H
+#define FSL_SVR_H
 
 #define SVR_REV(svr)	((svr) & 0xFF)		/* SOC design resision */
 #define SVR_MAJ(svr)	(((svr) >>  4) & 0xF)	/* Major revision field*/
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* [PATCH v11 5/5] powerpc/fsl-pci: Use fsl_guts_get_svr()
  2016-07-17  2:50 [PATCH v11 0/5] soc: fsl: Add initial guts driver Scott Wood
                   ` (3 preceding siblings ...)
  2016-07-17  2:50   ` Scott Wood
@ 2016-07-17  2:50 ` Scott Wood
  4 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-17  2:50 UTC (permalink / raw)
  To: linuxppc-dev
  Cc: Yangbo Lu, linux-mmc, Arnd Bergmann, linux-kernel, devicetree,
	Scott Wood

Establish an initial user of fsl_guts_get_svr(), so that the code gets
some test coverage until users outside arch/powerpc can get converted.

Signed-off-by: Scott Wood <oss@buserror.net>
---
 arch/powerpc/Kconfig          | 1 +
 arch/powerpc/sysdev/fsl_pci.c | 6 +++++-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index fcfe533..765df81 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -777,6 +777,7 @@ config FSL_PCI
  	bool
 	select PPC_INDIRECT_PCI
 	select PCI_QUIRKS
+	select FSL_GUTS
 
 config FSL_PMC
 	bool
diff --git a/arch/powerpc/sysdev/fsl_pci.c b/arch/powerpc/sysdev/fsl_pci.c
index 0fd1895..9ba570cf 100644
--- a/arch/powerpc/sysdev/fsl_pci.c
+++ b/arch/powerpc/sysdev/fsl_pci.c
@@ -22,6 +22,7 @@
 #include <linux/delay.h>
 #include <linux/string.h>
 #include <linux/fsl/edac.h>
+#include <linux/fsl/guts.h>
 #include <linux/fsl/svr.h>
 #include <linux/init.h>
 #include <linux/interrupt.h>
@@ -529,7 +530,10 @@ int fsl_add_bridge(struct platform_device *pdev, int is_primary)
 	struct device_node *dev;
 	struct ccsr_pci __iomem *pci;
 	u16 temp;
-	u32 svr = mfspr(SPRN_SVR);
+	u32 svr;
+
+	fsl_guts_init();
+	svr = fsl_guts_get_svr();
 
 	dev = pdev->dev.of_node;
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-17  2:50   ` Scott Wood
  (?)
@ 2016-07-20 11:24   ` Arnd Bergmann
  2016-07-20 18:31     ` Scott Wood
  -1 siblings, 1 reply; 28+ messages in thread
From: Arnd Bergmann @ 2016-07-20 11:24 UTC (permalink / raw)
  To: Scott Wood; +Cc: linuxppc-dev, Yangbo Lu, linux-mmc, linux-kernel, devicetree

On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> From: yangbo lu <yangbo.lu@nxp.com>
> 
> Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> header file.  This SVR numberspace is used on some ARM chips as well as
> PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
> need to ifdef the header inclusion and all references to the SVR symbols.
> 
> Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> Acked-by: Wolfram Sang <wsa@the-dreams.de>
> Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> Acked-by: Joerg Roedel <jroedel@suse.de>
> [scottwood: update description]
> Signed-off-by: Scott Wood <oss@buserror.net>
> 

As discussed before, please don't introduce yet another vendor specific
way to match a SoC ID from a device driver.

I've posted a patch for an extension to the soc_device infrastructure
to allow comparing the running SoC to a table of devices, use that
instead.

	Arnd

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-20 11:24   ` Arnd Bergmann
@ 2016-07-20 18:31     ` Scott Wood
  2016-07-20 20:35       ` Arnd Bergmann
  2016-07-21 10:26         ` Michael Ellerman
  0 siblings, 2 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-20 18:31 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: linuxppc-dev, Yangbo Lu, linux-mmc, linux-kernel, devicetree

On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > 
> > From: yangbo lu <yangbo.lu@nxp.com>
> > 
> > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > header file.  This SVR numberspace is used on some ARM chips as well as
> > PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
> > need to ifdef the header inclusion and all references to the SVR symbols.
> > 
> > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > Acked-by: Joerg Roedel <jroedel@suse.de>
> > [scottwood: update description]
> > Signed-off-by: Scott Wood <oss@buserror.net>
> > 
> As discussed before, please don't introduce yet another vendor specific
> way to match a SoC ID from a device driver.
> 
> I've posted a patch for an extension to the soc_device infrastructure
> to allow comparing the running SoC to a table of devices, use that
> instead.

As I asked before, in which relevant maintainership capacity are you NACKing
this?

-Scott

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-20 18:31     ` Scott Wood
@ 2016-07-20 20:35       ` Arnd Bergmann
  2016-07-21 10:26         ` Michael Ellerman
  1 sibling, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2016-07-20 20:35 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Scott Wood, linux-mmc, devicetree, linux-kernel, Yangbo Lu

On Wednesday, July 20, 2016 1:31:48 PM CEST Scott Wood wrote:
> On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > 
> > > From: yangbo lu <yangbo.lu@nxp.com>
> > > 
> > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > > header file.  This SVR numberspace is used on some ARM chips as well as
> > > PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
> > > need to ifdef the header inclusion and all references to the SVR symbols.
> > > 
> > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > [scottwood: update description]
> > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > 
> > As discussed before, please don't introduce yet another vendor specific
> > way to match a SoC ID from a device driver.
> > 
> > I've posted a patch for an extension to the soc_device infrastructure
> > to allow comparing the running SoC to a table of devices, use that
> > instead.
> 
> As I asked before, in which relevant maintainership capacity are you NACKing
> this?

I don't know why that's important, but I suggested the creation of
drivers/soc/ as a place to have a more general place for platform
specific drivers as part of being maintainer for arm-soc, and
almost all changes to drivers/soc go through our tree.

Olof does about half the merges, but I do the majority of the reviews
for drivers/soc patches. See also

git log --graph --format="%an %s" --merges drivers/soc/ 

	Arnd

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-20 18:31     ` Scott Wood
@ 2016-07-21 10:26         ` Michael Ellerman
  2016-07-21 10:26         ` Michael Ellerman
  1 sibling, 0 replies; 28+ messages in thread
From: Michael Ellerman @ 2016-07-21 10:26 UTC (permalink / raw)
  To: Scott Wood, Arnd Bergmann
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Yangbo Lu

Quoting Scott Wood (2016-07-21 04:31:48)
> On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > 
> > > From: yangbo lu <yangbo.lu@nxp.com>
> > > 
> > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > > header file.  This SVR numberspace is used on some ARM chips as well as
> > > PPC, and even to check for a PPC SVR multi-arch drivers would otherwise
> > > need to ifdef the header inclusion and all references to the SVR symbols.
> > > 
> > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > [scottwood: update description]
> > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > 
> > As discussed before, please don't introduce yet another vendor specific
> > way to match a SoC ID from a device driver.
> > 
> > I've posted a patch for an extension to the soc_device infrastructure
> > to allow comparing the running SoC to a table of devices, use that
> > instead.
> 
> As I asked before, in which relevant maintainership capacity are you NACKing
> this?

I'll nack the powerpc part until you guys can agree.

cheers

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-21 10:26         ` Michael Ellerman
  0 siblings, 0 replies; 28+ messages in thread
From: Michael Ellerman @ 2016-07-21 10:26 UTC (permalink / raw)
  To: Scott Wood, Arnd Bergmann
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Yangbo Lu

Quoting Scott Wood (2016-07-21 04:31:48)
> On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > =

> > > From: yangbo lu <yangbo.lu@nxp.com>
> > > =

> > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > > header file.=C2=A0=C2=A0This SVR numberspace is used on some ARM chip=
s as well as
> > > PPC, and even to check for a PPC SVR multi-arch drivers would otherwi=
se
> > > need to ifdef the header inclusion and all references to the SVR symb=
ols.
> > > =

> > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > [scottwood: update description]
> > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > =

> > As discussed before, please don't introduce yet another vendor specific
> > way to match a SoC ID from a device driver.
> > =

> > I've posted a patch for an extension to the soc_device infrastructure
> > to allow comparing the running SoC to a table of devices, use that
> > instead.
> =

> As I asked before, in which relevant maintainership capacity are you NACK=
ing
> this?

I'll nack the powerpc part until you guys can agree.

cheers

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-21 10:26         ` Michael Ellerman
@ 2016-07-21 16:45           ` Scott Wood
  -1 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-21 16:45 UTC (permalink / raw)
  To: Michael Ellerman, Arnd Bergmann
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Yangbo Lu

On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> Quoting Scott Wood (2016-07-21 04:31:48)
> > 
> > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > 
> > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > 
> > > > 
> > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > 
> > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > > > header file.  This SVR numberspace is used on some ARM chips as well
> > > > as
> > > > PPC, and even to check for a PPC SVR multi-arch drivers would
> > > > otherwise
> > > > need to ifdef the header inclusion and all references to the SVR
> > > > symbols.
> > > > 
> > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > [scottwood: update description]
> > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > 
> > > As discussed before, please don't introduce yet another vendor specific
> > > way to match a SoC ID from a device driver.
> > > 
> > > I've posted a patch for an extension to the soc_device infrastructure
> > > to allow comparing the running SoC to a table of devices, use that
> > > instead.
> > As I asked before, in which relevant maintainership capacity are you
> > NACKing
> > this?
> I'll nack the powerpc part until you guys can agree.

OK, I've pulled these patches out.

For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR) like
the clock driver does[1] and we can revisit the issue if/when we need to do
something similar on an ARM chip.

-Scott

[1] One of the issues with Arnd's approach is that it wouldn't have worked for
early things like the clock driver, and he didn't seem to mind using ifdef and
mfspr() there.

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-21 16:45           ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-07-21 16:45 UTC (permalink / raw)
  To: Michael Ellerman, Arnd Bergmann
  Cc: linux-mmc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Yangbo Lu

On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> Quoting Scott Wood (2016-07-21 04:31:48)
> > 
> > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > 
> > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > 
> > > > 
> > > > From: yangbo lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>
> > > > 
> > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a common
> > > > header file.  This SVR numberspace is used on some ARM chips as well
> > > > as
> > > > PPC, and even to check for a PPC SVR multi-arch drivers would
> > > > otherwise
> > > > need to ifdef the header inclusion and all references to the SVR
> > > > symbols.
> > > > 
> > > > Signed-off-by: Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org>
> > > > Acked-by: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
> > > > Acked-by: Stephen Boyd <sboyd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
> > > > Acked-by: Joerg Roedel <jroedel-l3A5Bk7waGM@public.gmane.org>
> > > > [scottwood: update description]
> > > > Signed-off-by: Scott Wood <oss-fOR+EgIDQEHk1uMJSBkQmQ@public.gmane.org>
> > > > 
> > > As discussed before, please don't introduce yet another vendor specific
> > > way to match a SoC ID from a device driver.
> > > 
> > > I've posted a patch for an extension to the soc_device infrastructure
> > > to allow comparing the running SoC to a table of devices, use that
> > > instead.
> > As I asked before, in which relevant maintainership capacity are you
> > NACKing
> > this?
> I'll nack the powerpc part until you guys can agree.

OK, I've pulled these patches out.

For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR) like
the clock driver does[1] and we can revisit the issue if/when we need to do
something similar on an ARM chip.

-Scott

[1] One of the issues with Arnd's approach is that it wouldn't have worked for
early things like the clock driver, and he didn't seem to mind using ifdef and
mfspr() there.

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-21 18:34             ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2016-07-21 18:34 UTC (permalink / raw)
  To: Scott Wood
  Cc: Michael Ellerman, linux-mmc, devicetree, linuxppc-dev,
	linux-kernel, Yangbo Lu

On Thursday, July 21, 2016 11:45:26 AM CEST Scott Wood wrote:
> 
> For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR) like
> the clock driver does[1] and we can revisit the issue if/when we need to do
> something similar on an ARM chip.

That sounds ok to me. having an mfspr check isn't nice but does the
job to work around existing bindings. For future chips, we can hopefully
find a way to identify most quirks early enough that the DT binding
can describe them using distinct compatible strings or other properties,
if necessary with the help of the boot loader.

Some other folks on MIPS were interested in having the soc_device
matching infrastructure and contacted me off-list, but they can of
course take the patch I sent and work from that.

	Arnd

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-21 18:34             ` Arnd Bergmann
  0 siblings, 0 replies; 28+ messages in thread
From: Arnd Bergmann @ 2016-07-21 18:34 UTC (permalink / raw)
  To: Scott Wood
  Cc: Michael Ellerman, linux-mmc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Yangbo Lu

On Thursday, July 21, 2016 11:45:26 AM CEST Scott Wood wrote:
> 
> For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR) like
> the clock driver does[1] and we can revisit the issue if/when we need to do
> something similar on an ARM chip.

That sounds ok to me. having an mfspr check isn't nice but does the
job to work around existing bindings. For future chips, we can hopefully
find a way to identify most quirks early enough that the DT binding
can describe them using distinct compatible strings or other properties,
if necessary with the help of the boot loader.

Some other folks on MIPS were interested in having the soc_device
matching infrastructure and contacted me off-list, but they can of
course take the patch I sent and work from that.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-21 16:45           ` Scott Wood
@ 2016-07-25  6:12             ` Yangbo Lu
  -1 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-07-25  6:12 UTC (permalink / raw)
  To: Scott Wood, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel

Hi Scott,


> -----Original Message-----
> From: Scott Wood [mailto:oss@buserror.net]
> Sent: Friday, July 22, 2016 12:45 AM
> To: Michael Ellerman; Arnd Bergmann
> Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> include/linux/fsl
> 
> On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > Quoting Scott Wood (2016-07-21 04:31:48)
> > >
> > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > >
> > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > >
> > > > >
> > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > >
> > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a
> > > > > common header file.  This SVR numberspace is used on some ARM
> > > > > chips as well as PPC, and even to check for a PPC SVR multi-arch
> > > > > drivers would otherwise need to ifdef the header inclusion and
> > > > > all references to the SVR symbols.
> > > > >
> > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > [scottwood: update description]
> > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > >
> > > > As discussed before, please don't introduce yet another vendor
> > > > specific way to match a SoC ID from a device driver.
> > > >
> > > > I've posted a patch for an extension to the soc_device
> > > > infrastructure to allow comparing the running SoC to a table of
> > > > devices, use that instead.
> > > As I asked before, in which relevant maintainership capacity are you
> > > NACKing this?
> > I'll nack the powerpc part until you guys can agree.
> 
> OK, I've pulled these patches out.
> 
> For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR)
> like the clock driver does[1] and we can revisit the issue if/when we
> need to do something similar on an ARM chip.

[Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce non-generic header files(like '#include <asm/mpc85xx.h>')
in mmc driver initially. So I think it will not be accepted to use ifdef CONFIG_PPC and mfspr(SPRN_SVR)...
And this method still couldn’t get SVR of ARM chip now.

Any other suggestion here?
Thank you very much.

- Yangbo Lu

> 
> -Scott
> 
> [1] One of the issues with Arnd's approach is that it wouldn't have
> worked for early things like the clock driver, and he didn't seem to mind
> using ifdef and
> mfspr() there.

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-07-25  6:12             ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-07-25  6:12 UTC (permalink / raw)
  To: Scott Wood, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel

SGkgU2NvdHQsDQoNCg0KPiAtLS0tLU9yaWdpbmFsIE1lc3NhZ2UtLS0tLQ0KPiBGcm9tOiBTY290
dCBXb29kIFttYWlsdG86b3NzQGJ1c2Vycm9yLm5ldF0NCj4gU2VudDogRnJpZGF5LCBKdWx5IDIy
LCAyMDE2IDEyOjQ1IEFNDQo+IFRvOiBNaWNoYWVsIEVsbGVybWFuOyBBcm5kIEJlcmdtYW5uDQo+
IENjOiBsaW51eC1tbWNAdmdlci5rZXJuZWwub3JnOyBkZXZpY2V0cmVlQHZnZXIua2VybmVsLm9y
ZzsgbGludXhwcGMtDQo+IGRldkBsaXN0cy5vemxhYnMub3JnOyBsaW51eC1rZXJuZWxAdmdlci5r
ZXJuZWwub3JnOyBZYW5nYm8gTHUNCj4gU3ViamVjdDogUmU6IFtQQVRDSCB2MTEgNC81XSBwb3dl
cnBjL2ZzbDogbW92ZSBtcGM4NXh4LmggdG8NCj4gaW5jbHVkZS9saW51eC9mc2wNCj4gDQo+IE9u
IFRodSwgMjAxNi0wNy0yMSBhdCAyMDoyNiArMTAwMCwgTWljaGFlbCBFbGxlcm1hbiB3cm90ZToN
Cj4gPiBRdW90aW5nIFNjb3R0IFdvb2QgKDIwMTYtMDctMjEgMDQ6MzE6NDgpDQo+ID4gPg0KPiA+
ID4gT24gV2VkLCAyMDE2LTA3LTIwIGF0IDEzOjI0ICswMjAwLCBBcm5kI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HRvIGRvIHNvbWV0aGluZyBzaW1p
bGFyIG9uIGFuIEFSTSBjaGlwLg0KDQpbTHUgWWFuZ2JvLUI0NzA5M10gSSByZW1lbWJlcmVkIHRo
YXQgVWZmZSBoYWQgb3Bwb3NlZCB1cyB0byBpbnRyb2R1Y2Ugbm9uLWdlbmVyaWMgaGVhZGVyIGZp
bGVzKGxpa2UgJyNpbmNsdWRlIDxhc20vbXBjODV4eC5oPicpDQppbiBtbWMgZHJpdmVyIGluaXRp
YWxseS4gU28gSSB0aGluayBpdCB3aWxsIG5vdCBiZSBhY2NlcHRlZCB0byB1c2UgaWZkZWYgQ09O
RklHX1BQQyBhbmQgbWZzcHIoU1BSTl9TVlIpLi4uDQpBbmQgdGhpcyBtZXRob2Qgc3RpbGwgY291
bGRu4oCZdCBnZXQgU1ZSIG9mIEFSTSBjaGlwIG5vdy4NCg0KQW55IG90aGVyIHN1Z2dlc3Rpb24g
aGVyZT8NClRoYW5rIHlvdSB2ZXJ5IG11Y2guDQoNCi0gWWFuZ2JvIEx1DQoNCj4gDQo+IC1TY290
dA0KPiANCj4gWzFdIE9uZSBvZiB0aGUgaXNzdWVzIHdpdGggQXJuZCdzIGFwcHJvYWNoIGlzIHRo
YXQgaXQgd291bGRuJ3QgaGF2ZQ0KPiB3b3JrZWQgZm9yIGVhcmx5IHRoaW5ncyBsaWtlIHRoZSBj
bG9jayBkcml2ZXIsIGFuZCBoZSBkaWRuJ3Qgc2VlbSB0byBtaW5kDQo+IHVzaW5nIGlmZGVmIGFu
ZA0KPiBtZnNwcigpIHRoZXJlLg0KDQo=

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-25  6:12             ` Yangbo Lu
  (?)
@ 2016-07-27  0:38             ` Scott Wood
  2016-08-02  5:57                 ` Yangbo Lu
  -1 siblings, 1 reply; 28+ messages in thread
From: Scott Wood @ 2016-07-27  0:38 UTC (permalink / raw)
  To: Yangbo Lu, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel

On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> Hi Scott,
> 
> 
> > 
> > -----Original Message-----
> > From: Scott Wood [mailto:oss@buserror.net]
> > Sent: Friday, July 22, 2016 12:45 AM
> > To: Michael Ellerman; Arnd Bergmann
> > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > include/linux/fsl
> > 
> > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > 
> > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > 
> > > > 
> > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > 
> > > > > 
> > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > 
> > > > > > 
> > > > > > 
> > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > 
> > > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h as a
> > > > > > common header file.  This SVR numberspace is used on some ARM
> > > > > > chips as well as PPC, and even to check for a PPC SVR multi-arch
> > > > > > drivers would otherwise need to ifdef the header inclusion and
> > > > > > all references to the SVR symbols.
> > > > > > 
> > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > [scottwood: update description]
> > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > 
> > > > > As discussed before, please don't introduce yet another vendor
> > > > > specific way to match a SoC ID from a device driver.
> > > > > 
> > > > > I've posted a patch for an extension to the soc_device
> > > > > infrastructure to allow comparing the running SoC to a table of
> > > > > devices, use that instead.
> > > > As I asked before, in which relevant maintainership capacity are you
> > > > NACKing this?
> > > I'll nack the powerpc part until you guys can agree.
> > OK, I've pulled these patches out.
> > 
> > For the MMC issue I suggest using ifdef CONFIG_PPC and mfspr(SPRN_SVR)
> > like the clock driver does[1] and we can revisit the issue if/when we
> > need to do something similar on an ARM chip.
> [Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce non-
> generic header files(like '#include <asm/mpc85xx.h>')
> in mmc driver initially. So I think it will not be accepted to use ifdef
> CONFIG_PPC and mfspr(SPRN_SVR)...
> And this method still couldn’t get SVR of ARM chip now.

Right, as I said we'll have to revisit the issue if/when we have the same
problem on an ARM chip.  That also applies if the PPC ifdef is still getting
NACKed from the MMC side.

> Any other suggestion here?

The other option is to try to come up with something that fits into Arnd's
framework while addressing the concerns I raised.  The soc_id string should be
well-structured to avoid mismatches and compatibility problems (especially
since it would get exposed to userspace).  Maybe something like:

svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc name>,die:<soc
die name>,rev:X.Y,<tag1>,<tag2>,<...>,

with the final comma used so that globs can put a colon on either end to be
sure they're matching a full field.  The SoC die name would be the primary
chip for a given die (e.g. p4040 would have a die name of p4080).  The "name"
and "die" fields would never include the trailing "e" indicated by the E bit.

Extra tags could be used for common groupings, such as all chips from a
particular die before a certain revision.  Once a tag is added it can't be
removed or reordered, to maintain userspace compatibility, but new tags could
be appended.

Some examples:

svr:0x82000020,svre:0x82000020,name:p4080,die:p4080,rev:2.0,
svr:0x82000020,svr
e:0x82080020,name:p4080,die:p4080,rev:2.0,
svr:0x82000030,svre:0x82000030,name:
p4080,die:p4080,rev:3.0,
svr:0x82000030,svre:0x82080030,name:p4080,die:p4080,re
v:3.0,
svr:0x82010020,svre:0x82010020,name:p4040,die:p4080,rev:2.0,
svr:0x820100
20,svre:0x82090020,name:p4040,die:p4080,rev:2.0,

svr:0x82010030,svre:0x82010030
,name:p4040,die:p4080,rev:3.0,
svr:0x82010030,svre:0x82090030,name:p4040,die:p4
080,rev:3.0,

Then if you want to apply a workaround on:
- all chips using the p4080 die, match with "*,die:p4080,*"
- all chips using the rev 2.0 p4080 die, match with "*,die:p4080,rev:2.0,*"
- Only p4040, but of any rev, match with "*,name:p4040,*"

Matching via open-coded hex number should be considered a last resort (it's
more error-prone, either for getting the number wrong or for forgetting
variants -- the latter is already a common problem), but preferable to adding
too many tags.

Using wildcards within a tag field would be discouraged.  

-Scott

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-07-27  0:38             ` Scott Wood
  2016-08-02  5:57                 ` Yangbo Lu
@ 2016-08-02  5:57                 ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-02  5:57 UTC (permalink / raw)
  To: Scott Wood, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Xiaobo Xie

Hi Scott,

> -----Original Message-----
> From: Scott Wood [mailto:oss@buserror.net]
> Sent: Wednesday, July 27, 2016 8:38 AM
> To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> include/linux/fsl
> 
> On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > Hi Scott,
> >
> >
> > >
> > > -----Original Message-----
> > > From: Scott Wood [mailto:oss@buserror.net]
> > > Sent: Friday, July 22, 2016 12:45 AM
> > > To: Michael Ellerman; Arnd Bergmann
> > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > include/linux/fsl
> > >
> > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > >
> > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > >
> > > > >
> > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > >
> > > > > >
> > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > >
> > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h
> > > > > > > as a common header file.  This SVR numberspace is used on
> > > > > > > some ARM chips as well as PPC, and even to check for a PPC
> > > > > > > SVR multi-arch drivers would otherwise need to ifdef the
> > > > > > > header inclusion and all references to the SVR symbols.
> > > > > > >
> > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > [scottwood: update description]
> > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > >
> > > > > > As discussed before, please don't introduce yet another vendor
> > > > > > specific way to match a SoC ID from a device driver.
> > > > > >
> > > > > > I've posted a patch for an extension to the soc_device
> > > > > > infrastructure to allow comparing the running SoC to a table
> > > > > > of devices, use that instead.
> > > > > As I asked before, in which relevant maintainership capacity are
> > > > > you NACKing this?
> > > > I'll nack the powerpc part until you guys can agree.
> > > OK, I've pulled these patches out.
> > >
> > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit the
> > > issue if/when we need to do something similar on an ARM chip.
> > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce
> > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > driver initially. So I think it will not be accepted to use ifdef
> > CONFIG_PPC and mfspr(SPRN_SVR)...
> > And this method still couldn’t get SVR of ARM chip now.
> 
> Right, as I said we'll have to revisit the issue if/when we have the same
> problem on an ARM chip.  That also applies if the PPC ifdef is still
> getting NACKed from the MMC side.

[Lu Yangbo-B47093] It's not clear for me about your idea :( 
Do you mean we can still use this method, or not ?
I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
Is there any solution to resolve ?
:)

> 
> > Any other suggestion here?
> 
> The other option is to try to come up with something that fits into
> Arnd's framework while addressing the concerns I raised.  The soc_id
> string should be well-structured to avoid mismatches and compatibility
> problems (especially since it would get exposed to userspace).  Maybe
> something like:
> 
> svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,

[Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
struct soc_device_attribute {
        const char *machine;
        const char *family;
        const char *revision;
        const char *soc_id;
};

We can put the 'model' in root node of dts as machine, put 'Freescale QorIQ' as family,
and put x.x as revision. Is it ok?
As you suggested, you like to use below string as soc_id. It's easy to get svr, but how does the software know the name and die,
and put them into this string ? It's a large code to define them. 
> svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
Should we remove rev here since there is also a revision member?

Regarding the guts_init, we still call guts_init and then match the soc, or we change to use platform driver?
Or do you know any better place to call guts_init to initialize only once?

Thank you so much :)

> 
> with the final comma used so that globs can put a colon on either end to
> be sure they're matching a full field.  The SoC die name would be the
> primary chip for a given die (e.g. p4040 would have a die name of
> p4080).  The "name"
> and "die" fields would never include the trailing "e" indicated by the E
> bit.
> 
> Extra tags could be used for common groupings, such as all chips from a
> particular die before a certain revision.  Once a tag is added it can't
> be removed or reordered, to maintain userspace compatibility, but new
> tags could be appended.
> 
> Some examples:
> 
> svr:0x82000020,svre:0x82000020,name:p4080,die:p4080,rev:2.0,
> svr:0x82000020,svr
> e:0x82080020,name:p4080,die:p4080,rev:2.0,
> svr:0x82000030,svre:0x82000030,name:
> p4080,die:p4080,rev:3.0,
> svr:0x82000030,svre:0x82080030,name:p4080,die:p4080,re
> v:3.0,
> svr:0x82010020,svre:0x82010020,name:p4040,die:p4080,rev:2.0,
> svr:0x820100
> 20,svre:0x82090020,name:p4040,die:p4080,rev:2.0,
> 
> svr:0x82010030,svre:0x82010030
> ,name:p4040,die:p4080,rev:3.0,
> svr:0x82010030,svre:0x82090030,name:p4040,die:p4
> 080,rev:3.0,
> 
> Then if you want to apply a workaround on:
> - all chips using the p4080 die, match with "*,die:p4080,*"
> - all chips using the rev 2.0 p4080 die, match with
> "*,die:p4080,rev:2.0,*"
> - Only p4040, but of any rev, match with "*,name:p4040,*"
> 
> Matching via open-coded hex number should be considered a last resort
> (it's more error-prone, either for getting the number wrong or for
> forgetting variants -- the latter is already a common problem), but
> preferable to adding too many tags.
> 
> Using wildcards within a tag field would be discouraged.
> 
> -Scott

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-02  5:57                 ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-02  5:57 UTC (permalink / raw)
  To: Scott Wood, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: devicetree, linux-mmc, linuxppc-dev, Xiaobo Xie, linux-kernel

Hi Scott,

> -----Original Message-----
> From: Scott Wood [mailto:oss@buserror.net]
> Sent: Wednesday, July 27, 2016 8:38 AM
> To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> include/linux/fsl
> 
> On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > Hi Scott,
> >
> >
> > >
> > > -----Original Message-----
> > > From: Scott Wood [mailto:oss@buserror.net]
> > > Sent: Friday, July 22, 2016 12:45 AM
> > > To: Michael Ellerman; Arnd Bergmann
> > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > include/linux/fsl
> > >
> > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > >
> > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > >
> > > > >
> > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > >
> > > > > >
> > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > >
> > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h
> > > > > > > as a common header file.  This SVR numberspace is used on
> > > > > > > some ARM chips as well as PPC, and even to check for a PPC
> > > > > > > SVR multi-arch drivers would otherwise need to ifdef the
> > > > > > > header inclusion and all references to the SVR symbols.
> > > > > > >
> > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > [scottwood: update description]
> > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > >
> > > > > > As discussed before, please don't introduce yet another vendor
> > > > > > specific way to match a SoC ID from a device driver.
> > > > > >
> > > > > > I've posted a patch for an extension to the soc_device
> > > > > > infrastructure to allow comparing the running SoC to a table
> > > > > > of devices, use that instead.
> > > > > As I asked before, in which relevant maintainership capacity are
> > > > > you NACKing this?
> > > > I'll nack the powerpc part until you guys can agree.
> > > OK, I've pulled these patches out.
> > >
> > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit the
> > > issue if/when we need to do something similar on an ARM chip.
> > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce
> > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > driver initially. So I think it will not be accepted to use ifdef
> > CONFIG_PPC and mfspr(SPRN_SVR)...
> > And this method still couldn’t get SVR of ARM chip now.
> 
> Right, as I said we'll have to revisit the issue if/when we have the same
> problem on an ARM chip.  That also applies if the PPC ifdef is still
> getting NACKed from the MMC side.

[Lu Yangbo-B47093] It's not clear for me about your idea :( 
Do you mean we can still use this method, or not ?
I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
Is there any solution to resolve ?
:)

> 
> > Any other suggestion here?
> 
> The other option is to try to come up with something that fits into
> Arnd's framework while addressing the concerns I raised.  The soc_id
> string should be well-structured to avoid mismatches and compatibility
> problems (especially since it would get exposed to userspace).  Maybe
> something like:
> 
> svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,

[Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
struct soc_device_attribute {
        const char *machine;
        const char *family;
        const char *revision;
        const char *soc_id;
};

We can put the 'model' in root node of dts as machine, put 'Freescale QorIQ' as family,
and put x.x as revision. Is it ok?
As you suggested, you like to use below string as soc_id. It's easy to get svr, but how does the software know the name and die,
and put them into this string ? It's a large code to define them. 
> svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
Should we remove rev here since there is also a revision member?

Regarding the guts_init, we still call guts_init and then match the soc, or we change to use platform driver?
Or do you know any better place to call guts_init to initialize only once?

Thank you so much :)

> 
> with the final comma used so that globs can put a colon on either end to
> be sure they're matching a full field.  The SoC die name would be the
> primary chip for a given die (e.g. p4040 would have a die name of
> p4080).  The "name"
> and "die" fields would never include the trailing "e" indicated by the E
> bit.
> 
> Extra tags could be used for common groupings, such as all chips from a
> particular die before a certain revision.  Once a tag is added it can't
> be removed or reordered, to maintain userspace compatibility, but new
> tags could be appended.
> 
> Some examples:
> 
> svr:0x82000020,svre:0x82000020,name:p4080,die:p4080,rev:2.0,
> svr:0x82000020,svr
> e:0x82080020,name:p4080,die:p4080,rev:2.0,
> svr:0x82000030,svre:0x82000030,name:
> p4080,die:p4080,rev:3.0,
> svr:0x82000030,svre:0x82080030,name:p4080,die:p4080,re
> v:3.0,
> svr:0x82010020,svre:0x82010020,name:p4040,die:p4080,rev:2.0,
> svr:0x820100
> 20,svre:0x82090020,name:p4040,die:p4080,rev:2.0,
> 
> svr:0x82010030,svre:0x82010030
> ,name:p4040,die:p4080,rev:3.0,
> svr:0x82010030,svre:0x82090030,name:p4040,die:p4
> 080,rev:3.0,
> 
> Then if you want to apply a workaround on:
> - all chips using the p4080 die, match with "*,die:p4080,*"
> - all chips using the rev 2.0 p4080 die, match with
> "*,die:p4080,rev:2.0,*"
> - Only p4040, but of any rev, match with "*,name:p4040,*"
> 
> Matching via open-coded hex number should be considered a last resort
> (it's more error-prone, either for getting the number wrong or for
> forgetting variants -- the latter is already a common problem), but
> preferable to adding too many tags.
> 
> Using wildcards within a tag field would be discouraged.
> 
> -Scott

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-02  5:57                 ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-02  5:57 UTC (permalink / raw)
  To: Scott Wood, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Xiaobo Xie

SGkgU2NvdHQsDQoNCj4gLS0t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lIHA0MDgwIGRpZSwgbWF0Y2ggd2l0aCAiKixkaWU6cDQw
ODAsKiINCj4gLSBhbGwgY2hpcHMgdXNpbmcgdGhlIHJldiAyLjAgcDQwODAgZGllLCBtYXRjaCB3
aXRoDQo+ICIqLGRpZTpwNDA4MCxyZXY6Mi4wLCoiDQo+IC0gT25seSBwNDA0MCwgYnV0IG9mIGFu
eSByZXYsIG1hdGNoIHdpdGggIiosbmFtZTpwNDA0MCwqIg0KPiANCj4gTWF0Y2hpbmcgdmlhIG9w
ZW4tY29kZWQgaGV4IG51bWJlciBzaG91bGQgYmUgY29uc2lkZXJlZCBhIGxhc3QgcmVzb3J0DQo+
IChpdCdzIG1vcmUgZXJyb3ItcHJvbmUsIGVpdGhlciBmb3IgZ2V0dGluZyB0aGUgbnVtYmVyIHdy
b25nIG9yIGZvcg0KPiBmb3JnZXR0aW5nIHZhcmlhbnRzIC0tIHRoZSBsYXR0ZXIgaXMgYWxyZWFk
eSBhIGNvbW1vbiBwcm9ibGVtKSwgYnV0DQo+IHByZWZlcmFibGUgdG8gYWRkaW5nIHRvbyBtYW55
IHRhZ3MuDQo+IA0KPiBVc2luZyB3aWxkY2FyZHMgd2l0aGluIGEgdGFnIGZpZWxkIHdvdWxkIGJl
IGRpc2NvdXJhZ2VkLg0KPiANCj4gLVNjb3R0DQoNCg==

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
  2016-08-02  5:57                 ` Yangbo Lu
@ 2016-08-02 21:40                   ` Scott Wood
  -1 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-08-02 21:40 UTC (permalink / raw)
  To: Yangbo Lu, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Xiaobo Xie

On Tue, 2016-08-02 at 05:57 +0000, Yangbo Lu wrote:
> Hi Scott,
> 
> > 
> > -----Original Message-----
> > From: Scott Wood [mailto:oss@buserror.net]
> > Sent: Wednesday, July 27, 2016 8:38 AM
> > To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > include/linux/fsl
> > 
> > On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > > 
> > > Hi Scott,
> > > 
> > > 
> > > > 
> > > > 
> > > > -----Original Message-----
> > > > From: Scott Wood [mailto:oss@buserror.net]
> > > > Sent: Friday, July 22, 2016 12:45 AM
> > > > To: Michael Ellerman; Arnd Bergmann
> > > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> > > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > > include/linux/fsl
> > > > 
> > > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > > > 
> > > > > 
> > > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > > > 
> > > > > > 
> > > > > > 
> > > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > > > 
> > > > > > > 
> > > > > > > 
> > > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > > > 
> > > > > > > > 
> > > > > > > > 
> > > > > > > > 
> > > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > > > 
> > > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h
> > > > > > > > as a common header file.  This SVR numberspace is used on
> > > > > > > > some ARM chips as well as PPC, and even to check for a PPC
> > > > > > > > SVR multi-arch drivers would otherwise need to ifdef the
> > > > > > > > header inclusion and all references to the SVR symbols.
> > > > > > > > 
> > > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > > [scottwood: update description]
> > > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > > > 
> > > > > > > As discussed before, please don't introduce yet another vendor
> > > > > > > specific way to match a SoC ID from a device driver.
> > > > > > > 
> > > > > > > I've posted a patch for an extension to the soc_device
> > > > > > > infrastructure to allow comparing the running SoC to a table
> > > > > > > of devices, use that instead.
> > > > > > As I asked before, in which relevant maintainership capacity are
> > > > > > you NACKing this?
> > > > > I'll nack the powerpc part until you guys can agree.
> > > > OK, I've pulled these patches out.
> > > > 
> > > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit the
> > > > issue if/when we need to do something similar on an ARM chip.
> > > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce
> > > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > > driver initially. So I think it will not be accepted to use ifdef
> > > CONFIG_PPC and mfspr(SPRN_SVR)...
> > > And this method still couldn’t get SVR of ARM chip now.
> > Right, as I said we'll have to revisit the issue if/when we have the same
> > problem on an ARM chip.  That also applies if the PPC ifdef is still
> > getting NACKed from the MMC side.
> [Lu Yangbo-B47093] It's not clear for me about your idea :( 
> Do you mean we can still use this method, or not ?
> I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
> Is there any solution to resolve ?
> :)

As I said, I'm OK with using the SPR.  It's up to you to find out whether it's
still unacceptable with the MMC maintainers given all the discussion (it would
be the quickest way to get the workaround enabled), or just go with the method
below.

> > > Any other suggestion here?
> > The other option is to try to come up with something that fits into
> > Arnd's framework while addressing the concerns I raised.  The soc_id
> > string should be well-structured to avoid mismatches and compatibility
> > problems (especially since it would get exposed to userspace).  Maybe
> > something like:
> > 
> > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> [Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
> struct soc_device_attribute {
>         const char *machine;
>         const char *family;
>         const char *revision;
>         const char *soc_id;
> };
> 
> We can put the 'model' in root node of dts as machine, put 'Freescale QorIQ'
> as family,

I'd just put "QorIQ" to avoid the question of whether to use "Freescale" or
"NXP".

> and put x.x as revision. Is it ok?
> As you suggested, you like to use below string as soc_id. It's easy to get
> svr, but how does the software know the name and die,
> and put them into this string ? It's a large code to define them. 

Yes, there would need to be a table in the guts driver for each SVR.  If the
SVR isn't found in the table then the soc_id would only contain the svr: and
svre: fields.

> > 
> > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> Should we remove rev here since there is also a revision member?

Yes, I forgot there was a revision field -- it should go there obviously.

> Regarding the guts_init, we still call guts_init and then match the soc, or
> we change to use platform driver?
> Or do you know any better place to call guts_init to initialize only once?

Use a platform driver for now.  If we ever need to check an ARM SVR in the
clock driver or similar place, then Arnd can explain what he wants us to do
then :-)

-Scott

^ permalink raw reply	[flat|nested] 28+ messages in thread

* Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-02 21:40                   ` Scott Wood
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Wood @ 2016-08-02 21:40 UTC (permalink / raw)
  To: Yangbo Lu, Michael Ellerman, Arnd Bergmann, Ulf Hansson
  Cc: devicetree, linux-mmc, linuxppc-dev, Xiaobo Xie, linux-kernel

On Tue, 2016-08-02 at 05:57 +0000, Yangbo Lu wrote:
> Hi Scott,
> 
> > 
> > -----Original Message-----
> > From: Scott Wood [mailto:oss@buserror.net]
> > Sent: Wednesday, July 27, 2016 8:38 AM
> > To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > include/linux/fsl
> > 
> > On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > > 
> > > Hi Scott,
> > > 
> > > 
> > > > 
> > > > 
> > > > -----Original Message-----
> > > > From: Scott Wood [mailto:oss@buserror.net]
> > > > Sent: Friday, July 22, 2016 12:45 AM
> > > > To: Michael Ellerman; Arnd Bergmann
> > > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Yangbo Lu
> > > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > > include/linux/fsl
> > > > 
> > > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > > > 
> > > > > 
> > > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > > > 
> > > > > > 
> > > > > > 
> > > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > > > 
> > > > > > > 
> > > > > > > 
> > > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > > > 
> > > > > > > > 
> > > > > > > > 
> > > > > > > > 
> > > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > > > 
> > > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to svr.h
> > > > > > > > as a common header file.  This SVR numberspace is used on
> > > > > > > > some ARM chips as well as PPC, and even to check for a PPC
> > > > > > > > SVR multi-arch drivers would otherwise need to ifdef the
> > > > > > > > header inclusion and all references to the SVR symbols.
> > > > > > > > 
> > > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > > [scottwood: update description]
> > > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > > > 
> > > > > > > As discussed before, please don't introduce yet another vendor
> > > > > > > specific way to match a SoC ID from a device driver.
> > > > > > > 
> > > > > > > I've posted a patch for an extension to the soc_device
> > > > > > > infrastructure to allow comparing the running SoC to a table
> > > > > > > of devices, use that instead.
> > > > > > As I asked before, in which relevant maintainership capacity are
> > > > > > you NACKing this?
> > > > > I'll nack the powerpc part until you guys can agree.
> > > > OK, I've pulled these patches out.
> > > > 
> > > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit the
> > > > issue if/when we need to do something similar on an ARM chip.
> > > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to introduce
> > > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > > driver initially. So I think it will not be accepted to use ifdef
> > > CONFIG_PPC and mfspr(SPRN_SVR)...
> > > And this method still couldn’t get SVR of ARM chip now.
> > Right, as I said we'll have to revisit the issue if/when we have the same
> > problem on an ARM chip.  That also applies if the PPC ifdef is still
> > getting NACKed from the MMC side.
> [Lu Yangbo-B47093] It's not clear for me about your idea :( 
> Do you mean we can still use this method, or not ?
> I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
> Is there any solution to resolve ?
> :)

As I said, I'm OK with using the SPR.  It's up to you to find out whether it's
still unacceptable with the MMC maintainers given all the discussion (it would
be the quickest way to get the workaround enabled), or just go with the method
below.

> > > Any other suggestion here?
> > The other option is to try to come up with something that fits into
> > Arnd's framework while addressing the concerns I raised.  The soc_id
> > string should be well-structured to avoid mismatches and compatibility
> > problems (especially since it would get exposed to userspace).  Maybe
> > something like:
> > 
> > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> [Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
> struct soc_device_attribute {
>         const char *machine;
>         const char *family;
>         const char *revision;
>         const char *soc_id;
> };
> 
> We can put the 'model' in root node of dts as machine, put 'Freescale QorIQ'
> as family,

I'd just put "QorIQ" to avoid the question of whether to use "Freescale" or
"NXP".

> and put x.x as revision. Is it ok?
> As you suggested, you like to use below string as soc_id. It's easy to get
> svr, but how does the software know the name and die,
> and put them into this string ? It's a large code to define them. 

Yes, there would need to be a table in the guts driver for each SVR.  If the
SVR isn't found in the table then the soc_id would only contain the svr: and
svre: fields.

> > 
> > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> Should we remove rev here since there is also a revision member?

Yes, I forgot there was a revision field -- it should go there obviously.

> Regarding the guts_init, we still call guts_init and then match the soc, or
> we change to use platform driver?
> Or do you know any better place to call guts_init to initialize only once?

Use a platform driver for now.  If we ever need to check an ARM SVR in the
clock driver or similar place, then Arnd can explain what he wants us to do
then :-)

-Scott

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-03  3:33                     ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-03  3:33 UTC (permalink / raw)
  To: Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Xiaobo Xie,
	Scott Wood, Michael Ellerman, Arnd Bergmann

Hi Uffe,


> -----Original Message-----
> From: Scott Wood [mailto:oss@buserror.net]
> Sent: Wednesday, August 03, 2016 5:41 AM
> To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Xiaobo Xie
> Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> include/linux/fsl
> 
> On Tue, 2016-08-02 at 05:57 +0000, Yangbo Lu wrote:
> > Hi Scott,
> >
> > >
> > > -----Original Message-----
> > > From: Scott Wood [mailto:oss@buserror.net]
> > > Sent: Wednesday, July 27, 2016 8:38 AM
> > > To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > include/linux/fsl
> > >
> > > On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > > >
> > > > Hi Scott,
> > > >
> > > >
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: Scott Wood [mailto:oss@buserror.net]
> > > > > Sent: Friday, July 22, 2016 12:45 AM
> > > > > To: Michael Ellerman; Arnd Bergmann
> > > > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org;
> > > > > linuxppc- dev@lists.ozlabs.org; linux-kernel@vger.kernel.org;
> > > > > Yangbo Lu
> > > > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > > > include/linux/fsl
> > > > >
> > > > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > > > >
> > > > > >
> > > > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > > > >
> > > > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to
> > > > > > > > > svr.h as a common header file.  This SVR numberspace is
> > > > > > > > > used on some ARM chips as well as PPC, and even to check
> > > > > > > > > for a PPC SVR multi-arch drivers would otherwise need to
> > > > > > > > > ifdef the header inclusion and all references to the SVR
> symbols.
> > > > > > > > >
> > > > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > > > [scottwood: update description]
> > > > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > > > >
> > > > > > > > As discussed before, please don't introduce yet another
> > > > > > > > vendor specific way to match a SoC ID from a device driver.
> > > > > > > >
> > > > > > > > I've posted a patch for an extension to the soc_device
> > > > > > > > infrastructure to allow comparing the running SoC to a
> > > > > > > > table of devices, use that instead.
> > > > > > > As I asked before, in which relevant maintainership capacity
> > > > > > > are you NACKing this?
> > > > > > I'll nack the powerpc part until you guys can agree.
> > > > > OK, I've pulled these patches out.
> > > > >
> > > > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit
> > > > > the issue if/when we need to do something similar on an ARM chip.
> > > > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to
> > > > introduce
> > > > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > > > driver initially. So I think it will not be accepted to use ifdef
> > > > CONFIG_PPC and mfspr(SPRN_SVR)...
> > > > And this method still couldn’t get SVR of ARM chip now.
> > > Right, as I said we'll have to revisit the issue if/when we have the
> > > same problem on an ARM chip.  That also applies if the PPC ifdef is
> > > still getting NACKed from the MMC side.
> > [Lu Yangbo-B47093] It's not clear for me about your idea :( Do you
> > mean we can still use this method, or not ?
> > I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
> > Is there any solution to resolve ?
> > :)
> 
> As I said, I'm OK with using the SPR.  It's up to you to find out whether
> it's still unacceptable with the MMC maintainers given all the discussion
> (it would be the quickest way to get the workaround enabled), or just go
> with the method below.

[Lu Yangbo-B47093] As you know, this patchset(as below) has been discussed for more than one year.
What I want is just to add a fix for an specific soc revision.

Yangbo Lu (7):
  Documentation: DT: update Freescale DCFG compatible
  ARM64: dts: ls2080a: add device configuration node
  soc: fsl: add GUTS driver for QorIQ platforms
  dt: move guts devicetree doc out of powerpc directory
  powerpc/fsl: move mpc85xx.h to include/linux/fsl
  MAINTAINERS: add entry for Freescale SoC drivers
  mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0

But we have to abandon it since Arnd strongly disagree our guts driver method to get soc revision.
Now I have to ask you to reconsider the original method to get soc revison since we really have no better idea.
As Scott suggested above, use ifdef CONFIG_PPC and mfspr(SPRN_SVR) like the clock driver does to get SVR.
It's quickest way to resolve our esdhc issue. Could you reconsider to use this?

Although Arnd provided another new method by sending a proof-of-concept patch as below, there were still many controversial points.
I'm worried that would be discussed for a quite long time like the guts driver.
[PATCH 1/4]  base: soc: introduce soc_device_match() interface
[PATCH 2/4] soc: fsl: add GUTS driver for QorIQ platforms
[PATCH 3/4] mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0
[PATCH 4/4] Revert "powerpc/fsl: Move fsl_guts.h out of arch/powerpc"

Anyway, what I want is just to fix the esdhc issue ASAP. 
Uffe, Could you reconsider whether you could accept the way using ifdef CONFIG_PPC and mfspr(SPRN_SVR)?
Or do you have any suggestion.

I will appreciate your suggestion.
Thanks a lot.

- Yangbo
> 
> > > > Any other suggestion here?
> > > The other option is to try to come up with something that fits into
> > > Arnd's framework while addressing the concerns I raised.  The soc_id
> > > string should be well-structured to avoid mismatches and
> > > compatibility problems (especially since it would get exposed to
> > > userspace).  Maybe something like:
> > >
> > > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> > [Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
> > struct soc_device_attribute {
> >         const char *machine;
> >         const char *family;
> >         const char *revision;
> >         const char *soc_id;
> > };
> >
> > We can put the 'model' in root node of dts as machine, put 'Freescale
> QorIQ'
> > as family,
> 
> I'd just put "QorIQ" to avoid the question of whether to use "Freescale"
> or "NXP".
> 
> > and put x.x as revision. Is it ok?
> > As you suggested, you like to use below string as soc_id. It's easy to
> > get svr, but how does the software know the name and die, and put them
> > into this string ? It's a large code to define them.
> 
> Yes, there would need to be a table in the guts driver for each SVR.  If
> the SVR isn't found in the table then the soc_id would only contain the
> svr: and
> svre: fields.
> 
> > >
> > > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> > Should we remove rev here since there is also a revision member?
> 
> Yes, I forgot there was a revision field -- it should go there obviously.
> 
> > Regarding the guts_init, we still call guts_init and then match the
> > soc, or we change to use platform driver?
> > Or do you know any better place to call guts_init to initialize only
> once?
> 
> Use a platform driver for now.  If we ever need to check an ARM SVR in
> the clock driver or similar place, then Arnd can explain what he wants us
> to do then :-)
> 
> -Scott

^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-03  3:33                     ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-03  3:33 UTC (permalink / raw)
  To: Ulf Hansson
  Cc: linux-mmc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Xiaobo Xie, Scott Wood,
	Michael Ellerman, Arnd Bergmann

Hi Uffe,


> -----Original Message-----
> From: Scott Wood [mailto:oss@buserror.net]
> Sent: Wednesday, August 03, 2016 5:41 AM
> To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> dev@lists.ozlabs.org; linux-kernel@vger.kernel.org; Xiaobo Xie
> Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> include/linux/fsl
> 
> On Tue, 2016-08-02 at 05:57 +0000, Yangbo Lu wrote:
> > Hi Scott,
> >
> > >
> > > -----Original Message-----
> > > From: Scott Wood [mailto:oss@buserror.net]
> > > Sent: Wednesday, July 27, 2016 8:38 AM
> > > To: Yangbo Lu; Michael Ellerman; Arnd Bergmann; Ulf Hansson
> > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org; linuxppc-
> > > dev@lists.ozlabs.org; linux-kernel@vger.kernel.org
> > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > include/linux/fsl
> > >
> > > On Mon, 2016-07-25 at 06:12 +0000, Yangbo Lu wrote:
> > > >
> > > > Hi Scott,
> > > >
> > > >
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: Scott Wood [mailto:oss@buserror.net]
> > > > > Sent: Friday, July 22, 2016 12:45 AM
> > > > > To: Michael Ellerman; Arnd Bergmann
> > > > > Cc: linux-mmc@vger.kernel.org; devicetree@vger.kernel.org;
> > > > > linuxppc- dev@lists.ozlabs.org; linux-kernel@vger.kernel.org;
> > > > > Yangbo Lu
> > > > > Subject: Re: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to
> > > > > include/linux/fsl
> > > > >
> > > > > On Thu, 2016-07-21 at 20:26 +1000, Michael Ellerman wrote:
> > > > > >
> > > > > >
> > > > > > Quoting Scott Wood (2016-07-21 04:31:48)
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > On Wed, 2016-07-20 at 13:24 +0200, Arnd Bergmann wrote:
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > On Saturday, July 16, 2016 9:50:21 PM CEST Scott Wood wrote:
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > From: yangbo lu <yangbo.lu@nxp.com>
> > > > > > > > >
> > > > > > > > > Move mpc85xx.h to include/linux/fsl and rename it to
> > > > > > > > > svr.h as a common header file.  This SVR numberspace is
> > > > > > > > > used on some ARM chips as well as PPC, and even to check
> > > > > > > > > for a PPC SVR multi-arch drivers would otherwise need to
> > > > > > > > > ifdef the header inclusion and all references to the SVR
> symbols.
> > > > > > > > >
> > > > > > > > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
> > > > > > > > > Acked-by: Wolfram Sang <wsa@the-dreams.de>
> > > > > > > > > Acked-by: Stephen Boyd <sboyd@codeaurora.org>
> > > > > > > > > Acked-by: Joerg Roedel <jroedel@suse.de>
> > > > > > > > > [scottwood: update description]
> > > > > > > > > Signed-off-by: Scott Wood <oss@buserror.net>
> > > > > > > > >
> > > > > > > > As discussed before, please don't introduce yet another
> > > > > > > > vendor specific way to match a SoC ID from a device driver.
> > > > > > > >
> > > > > > > > I've posted a patch for an extension to the soc_device
> > > > > > > > infrastructure to allow comparing the running SoC to a
> > > > > > > > table of devices, use that instead.
> > > > > > > As I asked before, in which relevant maintainership capacity
> > > > > > > are you NACKing this?
> > > > > > I'll nack the powerpc part until you guys can agree.
> > > > > OK, I've pulled these patches out.
> > > > >
> > > > > For the MMC issue I suggest using ifdef CONFIG_PPC and
> > > > > mfspr(SPRN_SVR) like the clock driver does[1] and we can revisit
> > > > > the issue if/when we need to do something similar on an ARM chip.
> > > > [Lu Yangbo-B47093] I remembered that Uffe had opposed us to
> > > > introduce
> > > > non- generic header files(like '#include <asm/mpc85xx.h>') in mmc
> > > > driver initially. So I think it will not be accepted to use ifdef
> > > > CONFIG_PPC and mfspr(SPRN_SVR)...
> > > > And this method still couldn’t get SVR of ARM chip now.
> > > Right, as I said we'll have to revisit the issue if/when we have the
> > > same problem on an ARM chip.  That also applies if the PPC ifdef is
> > > still getting NACKed from the MMC side.
> > [Lu Yangbo-B47093] It's not clear for me about your idea :( Do you
> > mean we can still use this method, or not ?
> > I think Uffe had opposed to use ifdef CONFIG_PPC and mfspr(SPRN_SVR).
> > Is there any solution to resolve ?
> > :)
> 
> As I said, I'm OK with using the SPR.  It's up to you to find out whether
> it's still unacceptable with the MMC maintainers given all the discussion
> (it would be the quickest way to get the workaround enabled), or just go
> with the method below.

[Lu Yangbo-B47093] As you know, this patchset(as below) has been discussed for more than one year.
What I want is just to add a fix for an specific soc revision.

Yangbo Lu (7):
  Documentation: DT: update Freescale DCFG compatible
  ARM64: dts: ls2080a: add device configuration node
  soc: fsl: add GUTS driver for QorIQ platforms
  dt: move guts devicetree doc out of powerpc directory
  powerpc/fsl: move mpc85xx.h to include/linux/fsl
  MAINTAINERS: add entry for Freescale SoC drivers
  mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0

But we have to abandon it since Arnd strongly disagree our guts driver method to get soc revision.
Now I have to ask you to reconsider the original method to get soc revison since we really have no better idea.
As Scott suggested above, use ifdef CONFIG_PPC and mfspr(SPRN_SVR) like the clock driver does to get SVR.
It's quickest way to resolve our esdhc issue. Could you reconsider to use this?

Although Arnd provided another new method by sending a proof-of-concept patch as below, there were still many controversial points.
I'm worried that would be discussed for a quite long time like the guts driver.
[PATCH 1/4]  base: soc: introduce soc_device_match() interface
[PATCH 2/4] soc: fsl: add GUTS driver for QorIQ platforms
[PATCH 3/4] mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0
[PATCH 4/4] Revert "powerpc/fsl: Move fsl_guts.h out of arch/powerpc"

Anyway, what I want is just to fix the esdhc issue ASAP. 
Uffe, Could you reconsider whether you could accept the way using ifdef CONFIG_PPC and mfspr(SPRN_SVR)?
Or do you have any suggestion.

I will appreciate your suggestion.
Thanks a lot.

- Yangbo
> 
> > > > Any other suggestion here?
> > > The other option is to try to come up with something that fits into
> > > Arnd's framework while addressing the concerns I raised.  The soc_id
> > > string should be well-structured to avoid mismatches and
> > > compatibility problems (especially since it would get exposed to
> > > userspace).  Maybe something like:
> > >
> > > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> > [Lu Yangbo-B47093] The soc_device_attribut struct is defined as below.
> > struct soc_device_attribute {
> >         const char *machine;
> >         const char *family;
> >         const char *revision;
> >         const char *soc_id;
> > };
> >
> > We can put the 'model' in root node of dts as machine, put 'Freescale
> QorIQ'
> > as family,
> 
> I'd just put "QorIQ" to avoid the question of whether to use "Freescale"
> or "NXP".
> 
> > and put x.x as revision. Is it ok?
> > As you suggested, you like to use below string as soc_id. It's easy to
> > get svr, but how does the software know the name and die, and put them
> > into this string ? It's a large code to define them.
> 
> Yes, there would need to be a table in the guts driver for each SVR.  If
> the SVR isn't found in the table then the soc_id would only contain the
> svr: and
> svre: fields.
> 
> > >
> > > svr:<SVR minus E bit>,svre:<full SVR including E bit>,name:<soc
> > > name>,die:<soc die name>,rev:X.Y,<tag1>,<tag2>,<...>,
> > Should we remove rev here since there is also a revision member?
> 
> Yes, I forgot there was a revision field -- it should go there obviously.
> 
> > Regarding the guts_init, we still call guts_init and then match the
> > soc, or we change to use platform driver?
> > Or do you know any better place to call guts_init to initialize only
> once?
> 
> Use a platform driver for now.  If we ever need to check an ARM SVR in
> the clock driver or similar place, then Arnd can explain what he wants us
> to do then :-)
> 
> -Scott


^ permalink raw reply	[flat|nested] 28+ messages in thread

* RE: [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl
@ 2016-08-03  3:33                     ` Yangbo Lu
  0 siblings, 0 replies; 28+ messages in thread
From: Yangbo Lu @ 2016-08-03  3:33 UTC (permalink / raw)
  To: Ulf Hansson
  Cc: linux-mmc, devicetree, linuxppc-dev, linux-kernel, Xiaobo Xie,
	Scott Wood, Michael Ellerman, Arnd Bergmann

SGkgVWZmZSwNCg0KDQo+IC0tLS0tT3JpZ2luYWwgTWVzc2FnZS0tLS0tDQo+IEZyb206IFNjb3R0
IFdvb2QgW21ha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nested] 28+ messages in thread

end of thread, other threads:[~2016-08-03  3:34 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-17  2:50 [PATCH v11 0/5] soc: fsl: Add initial guts driver Scott Wood
2016-07-17  2:50 ` [PATCH v11 1/5] dt: bindings: update Freescale DCFG compatible Scott Wood
2016-07-17  2:50 ` [PATCH v11 2/5] dt: bindings: move guts devicetree doc out of powerpc directory Scott Wood
2016-07-17  2:50   ` Scott Wood
2016-07-17  2:50 ` [PATCH v11 3/5] soc: fsl: add GUTS driver for QorIQ platforms Scott Wood
2016-07-17  2:50 ` [PATCH v11 4/5] powerpc/fsl: move mpc85xx.h to include/linux/fsl Scott Wood
2016-07-17  2:50   ` Scott Wood
2016-07-20 11:24   ` Arnd Bergmann
2016-07-20 18:31     ` Scott Wood
2016-07-20 20:35       ` Arnd Bergmann
2016-07-21 10:26       ` Michael Ellerman
2016-07-21 10:26         ` Michael Ellerman
2016-07-21 16:45         ` Scott Wood
2016-07-21 16:45           ` Scott Wood
2016-07-21 18:34           ` Arnd Bergmann
2016-07-21 18:34             ` Arnd Bergmann
2016-07-25  6:12           ` Yangbo Lu
2016-07-25  6:12             ` Yangbo Lu
2016-07-27  0:38             ` Scott Wood
2016-08-02  5:57               ` Yangbo Lu
2016-08-02  5:57                 ` Yangbo Lu
2016-08-02  5:57                 ` Yangbo Lu
2016-08-02 21:40                 ` Scott Wood
2016-08-02 21:40                   ` Scott Wood
2016-08-03  3:33                   ` Yangbo Lu
2016-08-03  3:33                     ` Yangbo Lu
2016-08-03  3:33                     ` Yangbo Lu
2016-07-17  2:50 ` [PATCH v11 5/5] powerpc/fsl-pci: Use fsl_guts_get_svr() Scott Wood

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.