linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] Generic NVRAM support for large MMIO devices
@ 2009-07-02 16:12 Martyn Welch
  2009-07-02 16:12 ` [PATCH 1/5] Allow byte length reads from mmio NVRAM driver Martyn Welch
                   ` (5 more replies)
  0 siblings, 6 replies; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

The following series allows the generic NVRAM driver to access MMIO based NVRAMs. In addition it enables support for NVRAMs of sizes differing from those found on PowerPC Macs (providing a safe fallback). Patches are also included to enable support for the NVRAM found on the GE Fanuc PPC9A, SBC310 and SBC610.

If this patch series is unsuitable this late in the day for 2.6.31, please concider it for 2.6.32.

Martyn

-- 
Martyn Welch MEng MPhil MIET (Principal Software Engineer)   T:+44(0)1327322748
GE Fanuc Intelligent Platforms Ltd,        |Registered in England and Wales
Tove Valley Business Park, Towcester,      |(3828642) at 100 Barbirolli Square,
Northants, NN12 6PF, UK T:+44(0)1327359444 |Manchester,M2 3AB  VAT:GB 927559189

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

* [PATCH 1/5] Allow byte length reads from mmio NVRAM driver
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
@ 2009-07-02 16:12 ` Martyn Welch
  2009-07-02 16:12 ` [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips Martyn Welch
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

Add a byte length read and write interface compatible with the nvram_generic driver interface to the mmio driver.

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

 arch/powerpc/sysdev/mmio_nvram.c |   32 ++++++++++++++++++++++++++++++++
 1 files changed, 32 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/sysdev/mmio_nvram.c b/arch/powerpc/sysdev/mmio_nvram.c
index 7b49633..2073242 100644
--- a/arch/powerpc/sysdev/mmio_nvram.c
+++ b/arch/powerpc/sysdev/mmio_nvram.c
@@ -53,6 +53,23 @@ static ssize_t mmio_nvram_read(char *buf, size_t count, loff_t *index)
 	return count;
 }
 
+static unsigned char mmio_nvram_read_val(int addr)
+{
+	unsigned long flags;
+	unsigned char val;
+
+	if (addr >= mmio_nvram_len)
+		return 0xff;
+
+	spin_lock_irqsave(&mmio_nvram_lock, flags);
+
+	val = ioread8(mmio_nvram_start + addr);
+
+	spin_unlock_irqrestore(&mmio_nvram_lock, flags);
+
+	return val;
+}
+
 static ssize_t mmio_nvram_write(char *buf, size_t count, loff_t *index)
 {
 	unsigned long flags;
@@ -72,6 +89,19 @@ static ssize_t mmio_nvram_write(char *buf, size_t count, loff_t *index)
 	return count;
 }
 
+void mmio_nvram_write_val(int addr, unsigned char val)
+{
+	unsigned long flags;
+
+	if (addr < mmio_nvram_len) {
+		spin_lock_irqsave(&mmio_nvram_lock, flags);
+
+		iowrite8(val, mmio_nvram_start + addr);
+
+		spin_unlock_irqrestore(&mmio_nvram_lock, flags);
+	}
+}
+
 static ssize_t mmio_nvram_get_size(void)
 {
 	return mmio_nvram_len;
@@ -114,6 +144,8 @@ int __init mmio_nvram_init(void)
 	printk(KERN_INFO "mmio NVRAM, %luk at 0x%lx mapped to %p\n",
 	       mmio_nvram_len >> 10, nvram_addr, mmio_nvram_start);
 
+	ppc_md.nvram_read_val	= mmio_nvram_read_val;
+	ppc_md.nvram_write_val	= mmio_nvram_write_val;
 	ppc_md.nvram_read	= mmio_nvram_read;
 	ppc_md.nvram_write	= mmio_nvram_write;
 	ppc_md.nvram_size	= mmio_nvram_get_size;

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

* [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
  2009-07-02 16:12 ` [PATCH 1/5] Allow byte length reads from mmio NVRAM driver Martyn Welch
@ 2009-07-02 16:12 ` Martyn Welch
  2009-07-23  7:43   ` Benjamin Herrenschmidt
  2009-08-13  7:15   ` Benjamin Herrenschmidt
  2009-07-02 16:12 ` [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610 Martyn Welch
                   ` (3 subsequent siblings)
  5 siblings, 2 replies; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

 arch/powerpc/include/asm/nvram.h |    3 +++
 arch/powerpc/kernel/setup_32.c   |    8 ++++++++
 drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
 3 files changed, 31 insertions(+), 7 deletions(-)

diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
index efde5ac..71df8b2 100644
--- a/arch/powerpc/include/asm/nvram.h
+++ b/arch/powerpc/include/asm/nvram.h
@@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
 /* Synchronize NVRAM */
 extern void	nvram_sync(void);
 
+/* Determine NVRAM size */
+extern ssize_t nvram_size(void);
+
 /* Normal access to NVRAM */
 extern unsigned char nvram_read_byte(int i);
 extern void nvram_write_byte(unsigned char c, int i);
diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
index 1d15424..28f7570 100644
--- a/arch/powerpc/kernel/setup_32.c
+++ b/arch/powerpc/kernel/setup_32.c
@@ -208,6 +208,14 @@ void nvram_write_byte(unsigned char val, int addr)
 }
 EXPORT_SYMBOL(nvram_write_byte);
 
+ssize_t nvram_size(void)
+{
+	if (ppc_md.nvram_size)
+		return ppc_md.nvram_size();
+	return -1;
+}
+EXPORT_SYMBOL(nvram_size);
+
 void nvram_sync(void)
 {
 	if (ppc_md.nvram_sync)
diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
index a00869c..e5f71f3 100644
--- a/drivers/char/generic_nvram.c
+++ b/drivers/char/generic_nvram.c
@@ -2,7 +2,7 @@
  * Generic /dev/nvram driver for architectures providing some
  * "generic" hooks, that is :
  *
- * nvram_read_byte, nvram_write_byte, nvram_sync
+ * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_size
  *
  * Note that an additional hook is supported for PowerMac only
  * for getting the nvram "partition" informations
@@ -28,6 +28,8 @@
 
 #define NVRAM_SIZE	8192
 
+static ssize_t nvram_len;
+
 static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
 {
 	lock_kernel();
@@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
 		offset += file->f_pos;
 		break;
 	case 2:
-		offset += NVRAM_SIZE;
+		offset += nvram_len;
 		break;
 	}
 	if (offset < 0) {
@@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
 
 	if (!access_ok(VERIFY_WRITE, buf, count))
 		return -EFAULT;
-	if (*ppos >= NVRAM_SIZE)
+	if (*ppos >= nvram_len)
 		return 0;
-	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
+	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
 		if (__put_user(nvram_read_byte(i), p))
 			return -EFAULT;
 	*ppos = i;
@@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
 
 	if (!access_ok(VERIFY_READ, buf, count))
 		return -EFAULT;
-	if (*ppos >= NVRAM_SIZE)
+	if (*ppos >= nvram_len)
 		return 0;
-	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
+	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
 		if (__get_user(c, p))
 			return -EFAULT;
 		nvram_write_byte(c, i);
@@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
 
 int __init nvram_init(void)
 {
+	int ret = 0;
+
 	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
 		NVRAM_VERSION);
-	return misc_register(&nvram_dev);
+	ret = misc_register(&nvram_dev);
+	if (ret != 0)
+		goto out;
+
+	nvram_len = nvram_size();
+	if (nvram_len < 0)
+		nvram_len = NVRAM_SIZE;
+
+out:
+	return ret;
 }
 
 void __exit nvram_cleanup(void)

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

* [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
  2009-07-02 16:12 ` [PATCH 1/5] Allow byte length reads from mmio NVRAM driver Martyn Welch
  2009-07-02 16:12 ` [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips Martyn Welch
@ 2009-07-02 16:12 ` Martyn Welch
  2009-11-05 14:10   ` Kumar Gala
  2009-11-12 14:03   ` Kumar Gala
  2009-07-02 16:12 ` [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310 Martyn Welch
                   ` (2 subsequent siblings)
  5 siblings, 2 replies; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

This patch enables the NVRAM found on the GE Fanuc SBC610

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

 arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
 arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
 arch/powerpc/platforms/86xx/Kconfig            |    1 +
 arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
 4 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/boot/dts/gef_sbc610.dts b/arch/powerpc/boot/dts/gef_sbc610.dts
index 35a6318..30911ad 100644
--- a/arch/powerpc/boot/dts/gef_sbc610.dts
+++ b/arch/powerpc/boot/dts/gef_sbc610.dts
@@ -84,6 +84,12 @@
 			  6 0 0xfd000000 0x00800000     // IO FPGA (8-bit)
 			  7 0 0xfd800000 0x00800000>;   // IO FPGA (32-bit)
 
+		nvram@3,0 {
+			device_type = "nvram";
+			compatible = "simtek,stk14ca8";
+			reg = <0x3 0x0 0x20000>;
+		};
+
 		fpga@4,0 {
 			compatible = "gef,fpga-regs";
 			reg = <0x4 0x0 0x40>;
diff --git a/arch/powerpc/configs/86xx/gef_sbc610_defconfig b/arch/powerpc/configs/86xx/gef_sbc610_defconfig
index c6a7fc8..b4a7c03 100644
--- a/arch/powerpc/configs/86xx/gef_sbc610_defconfig
+++ b/arch/powerpc/configs/86xx/gef_sbc610_defconfig
@@ -201,7 +201,7 @@ CONFIG_MPIC=y
 # CONFIG_MPIC_WEIRD is not set
 # CONFIG_PPC_I8259 is not set
 # CONFIG_PPC_RTAS is not set
-# CONFIG_MMIO_NVRAM is not set
+CONFIG_MMIO_NVRAM=y
 # CONFIG_PPC_MPC106 is not set
 # CONFIG_PPC_970_NAP is not set
 # CONFIG_PPC_INDIRECT_IO is not set
@@ -1083,7 +1083,7 @@ CONFIG_UNIX98_PTYS=y
 # CONFIG_IPMI_HANDLER is not set
 CONFIG_HW_RANDOM=y
 # CONFIG_HW_RANDOM_TIMERIOMEM is not set
-# CONFIG_NVRAM is not set
+CONFIG_NVRAM=y
 # CONFIG_R3964 is not set
 # CONFIG_APPLICOM is not set
 # CONFIG_RAW_DRIVER is not set
diff --git a/arch/powerpc/platforms/86xx/Kconfig b/arch/powerpc/platforms/86xx/Kconfig
index 9c7b64a..9d02dea 100644
--- a/arch/powerpc/platforms/86xx/Kconfig
+++ b/arch/powerpc/platforms/86xx/Kconfig
@@ -51,6 +51,7 @@ config GEF_SBC310
 config GEF_SBC610
 	bool "GE Fanuc SBC610"
 	select DEFAULT_UIMAGE
+	select MMIO_NVRAM
 	select GENERIC_GPIO
 	select ARCH_REQUIRE_GPIOLIB
 	select HAS_RAPIDIO
diff --git a/arch/powerpc/platforms/86xx/gef_sbc610.c b/arch/powerpc/platforms/86xx/gef_sbc610.c
index 72b31a6..e10688a 100644
--- a/arch/powerpc/platforms/86xx/gef_sbc610.c
+++ b/arch/powerpc/platforms/86xx/gef_sbc610.c
@@ -33,6 +33,7 @@
 #include <asm/udbg.h>
 
 #include <asm/mpic.h>
+#include <asm/nvram.h>
 
 #include <sysdev/fsl_pci.h>
 #include <sysdev/fsl_soc.h>
@@ -95,6 +96,10 @@ static void __init gef_sbc610_setup_arch(void)
 			printk(KERN_WARNING "Unable to map board registers\n");
 		of_node_put(regs);
 	}
+
+#if defined(CONFIG_MMIO_NVRAM)
+	mmio_nvram_init();
+#endif
 }
 
 /* Return the PCB revision */

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

* [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
                   ` (2 preceding siblings ...)
  2009-07-02 16:12 ` [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610 Martyn Welch
@ 2009-07-02 16:12 ` Martyn Welch
  2009-11-12 14:04   ` Kumar Gala
  2009-07-02 16:12 ` [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A Martyn Welch
  2009-07-23  7:44 ` [PATCH 0/5] Generic NVRAM support for large MMIO devices Benjamin Herrenschmidt
  5 siblings, 1 reply; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

Add support for NVRAM on GE Fanuc's SBC310.

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

 arch/powerpc/boot/dts/gef_sbc310.dts           |    6 ++++++
 arch/powerpc/configs/86xx/gef_sbc310_defconfig |    4 ++--
 arch/powerpc/platforms/86xx/Kconfig            |    1 +
 arch/powerpc/platforms/86xx/gef_sbc310.c       |    5 +++++
 4 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/boot/dts/gef_sbc310.dts b/arch/powerpc/boot/dts/gef_sbc310.dts
index 2107d3c..820c2b3 100644
--- a/arch/powerpc/boot/dts/gef_sbc310.dts
+++ b/arch/powerpc/boot/dts/gef_sbc310.dts
@@ -115,6 +115,12 @@
 			};
 		};
 
+		nvram@3,0 {
+			device_type = "nvram";
+			compatible = "simtek,stk14ca8";
+			reg = <0x3 0x0 0x20000>;
+		};
+
 		fpga@4,0 {
 			compatible = "gef,fpga-regs";
 			reg = <0x4 0x0 0x40>;
diff --git a/arch/powerpc/configs/86xx/gef_sbc310_defconfig b/arch/powerpc/configs/86xx/gef_sbc310_defconfig
index f2362e5..3d70f2a 100644
--- a/arch/powerpc/configs/86xx/gef_sbc310_defconfig
+++ b/arch/powerpc/configs/86xx/gef_sbc310_defconfig
@@ -1,7 +1,7 @@
 #
 # Automatically generated make config: don't edit
 # Linux kernel version: 2.6.30
-# Thu Jul  2 14:10:12 2009
+# Thu Jul  2 14:10:51 2009
 #
 # CONFIG_PPC64 is not set
 
@@ -214,7 +214,7 @@ CONFIG_MPIC=y
 # CONFIG_MPIC_WEIRD is not set
 # CONFIG_PPC_I8259 is not set
 # CONFIG_PPC_RTAS is not set
-# CONFIG_MMIO_NVRAM is not set
+CONFIG_MMIO_NVRAM=y
 # CONFIG_PPC_MPC106 is not set
 # CONFIG_PPC_970_NAP is not set
 # CONFIG_PPC_INDIRECT_IO is not set
diff --git a/arch/powerpc/platforms/86xx/Kconfig b/arch/powerpc/platforms/86xx/Kconfig
index 9d02dea..6012022 100644
--- a/arch/powerpc/platforms/86xx/Kconfig
+++ b/arch/powerpc/platforms/86xx/Kconfig
@@ -43,6 +43,7 @@ config GEF_PPC9A
 config GEF_SBC310
 	bool "GE Fanuc SBC310"
 	select DEFAULT_UIMAGE
+	select MMIO_NVRAM
 	select GENERIC_GPIO
 	select ARCH_REQUIRE_GPIOLIB
 	help
diff --git a/arch/powerpc/platforms/86xx/gef_sbc310.c b/arch/powerpc/platforms/86xx/gef_sbc310.c
index 90754e7..6a1a613 100644
--- a/arch/powerpc/platforms/86xx/gef_sbc310.c
+++ b/arch/powerpc/platforms/86xx/gef_sbc310.c
@@ -33,6 +33,7 @@
 #include <asm/udbg.h>
 
 #include <asm/mpic.h>
+#include <asm/nvram.h>
 
 #include <sysdev/fsl_pci.h>
 #include <sysdev/fsl_soc.h>
@@ -95,6 +96,10 @@ static void __init gef_sbc310_setup_arch(void)
 			printk(KERN_WARNING "Unable to map board registers\n");
 		of_node_put(regs);
 	}
+
+#if defined(CONFIG_MMIO_NVRAM)
+	mmio_nvram_init();
+#endif
 }
 
 /* Return the PCB revision */

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

* [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
                   ` (3 preceding siblings ...)
  2009-07-02 16:12 ` [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310 Martyn Welch
@ 2009-07-02 16:12 ` Martyn Welch
  2009-11-12 14:04   ` Kumar Gala
  2009-07-23  7:44 ` [PATCH 0/5] Generic NVRAM support for large MMIO devices Benjamin Herrenschmidt
  5 siblings, 1 reply; 21+ messages in thread
From: Martyn Welch @ 2009-07-02 16:12 UTC (permalink / raw)
  To: linuxppc-dev

Add support for NVRAM on GE Fanuc's PPC9A.

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

 arch/powerpc/boot/dts/gef_ppc9a.dts           |    6 ++++++
 arch/powerpc/configs/86xx/gef_ppc9a_defconfig |    4 ++--
 arch/powerpc/platforms/86xx/Kconfig           |    1 +
 arch/powerpc/platforms/86xx/gef_ppc9a.c       |    5 +++++
 4 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/boot/dts/gef_ppc9a.dts b/arch/powerpc/boot/dts/gef_ppc9a.dts
index 910944e..c86114e 100644
--- a/arch/powerpc/boot/dts/gef_ppc9a.dts
+++ b/arch/powerpc/boot/dts/gef_ppc9a.dts
@@ -118,6 +118,12 @@
 			};
 		};
 
+		nvram@3,0 {
+			device_type = "nvram";
+			compatible = "simtek,stk14ca8";
+			reg = <0x3 0x0 0x20000>;
+		};
+
 		fpga@4,0 {
 			compatible = "gef,ppc9a-fpga-regs";
 			reg = <0x4 0x0 0x40>;
diff --git a/arch/powerpc/configs/86xx/gef_ppc9a_defconfig b/arch/powerpc/configs/86xx/gef_ppc9a_defconfig
index d8354d9..e175abf 100644
--- a/arch/powerpc/configs/86xx/gef_ppc9a_defconfig
+++ b/arch/powerpc/configs/86xx/gef_ppc9a_defconfig
@@ -1,7 +1,7 @@
 #
 # Automatically generated make config: don't edit
 # Linux kernel version: 2.6.30
-# Thu Jul  2 13:55:24 2009
+# Thu Jul  2 13:59:13 2009
 #
 # CONFIG_PPC64 is not set
 
@@ -214,7 +214,7 @@ CONFIG_MPIC=y
 # CONFIG_MPIC_WEIRD is not set
 # CONFIG_PPC_I8259 is not set
 # CONFIG_PPC_RTAS is not set
-# CONFIG_MMIO_NVRAM is not set
+CONFIG_MMIO_NVRAM=y
 # CONFIG_PPC_MPC106 is not set
 # CONFIG_PPC_970_NAP is not set
 # CONFIG_PPC_INDIRECT_IO is not set
diff --git a/arch/powerpc/platforms/86xx/Kconfig b/arch/powerpc/platforms/86xx/Kconfig
index 6012022..2bbfd53 100644
--- a/arch/powerpc/platforms/86xx/Kconfig
+++ b/arch/powerpc/platforms/86xx/Kconfig
@@ -35,6 +35,7 @@ config MPC8610_HPCD
 config GEF_PPC9A
 	bool "GE Fanuc PPC9A"
 	select DEFAULT_UIMAGE
+	select MMIO_NVRAM
 	select GENERIC_GPIO
 	select ARCH_REQUIRE_GPIOLIB
 	help
diff --git a/arch/powerpc/platforms/86xx/gef_ppc9a.c b/arch/powerpc/platforms/86xx/gef_ppc9a.c
index 287f7bd..a792e5d 100644
--- a/arch/powerpc/platforms/86xx/gef_ppc9a.c
+++ b/arch/powerpc/platforms/86xx/gef_ppc9a.c
@@ -33,6 +33,7 @@
 #include <asm/udbg.h>
 
 #include <asm/mpic.h>
+#include <asm/nvram.h>
 
 #include <sysdev/fsl_pci.h>
 #include <sysdev/fsl_soc.h>
@@ -95,6 +96,10 @@ static void __init gef_ppc9a_setup_arch(void)
 			printk(KERN_WARNING "Unable to map board registers\n");
 		of_node_put(regs);
 	}
+
+#if defined(CONFIG_MMIO_NVRAM)
+	mmio_nvram_init();
+#endif
 }
 
 /* Return the PCB revision */

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

* Re: [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-07-02 16:12 ` [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips Martyn Welch
@ 2009-07-23  7:43   ` Benjamin Herrenschmidt
  2009-07-23 11:31     ` Martyn Welch
  2009-08-13  7:15   ` Benjamin Herrenschmidt
  1 sibling, 1 reply; 21+ messages in thread
From: Benjamin Herrenschmidt @ 2009-07-23  7:43 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev

On Thu, 2009-07-02 at 17:12 +0100, Martyn Welch wrote:
> Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.
> 
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>

What about other archs that use this driver ? They would also need
that new nvram_size() ...

BTW. This patch touches non-arch code so should at least be CCed to lkml

Cheers,
Ben.

> ---
> 
>  arch/powerpc/include/asm/nvram.h |    3 +++
>  arch/powerpc/kernel/setup_32.c   |    8 ++++++++
>  drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
>  3 files changed, 31 insertions(+), 7 deletions(-)
> 
> diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
> index efde5ac..71df8b2 100644
> --- a/arch/powerpc/include/asm/nvram.h
> +++ b/arch/powerpc/include/asm/nvram.h
> @@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
>  /* Synchronize NVRAM */
>  extern void	nvram_sync(void);
>  
> +/* Determine NVRAM size */
> +extern ssize_t nvram_size(void);
> +
>  /* Normal access to NVRAM */
>  extern unsigned char nvram_read_byte(int i);
>  extern void nvram_write_byte(unsigned char c, int i);
> diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
> index 1d15424..28f7570 100644
> --- a/arch/powerpc/kernel/setup_32.c
> +++ b/arch/powerpc/kernel/setup_32.c
> @@ -208,6 +208,14 @@ void nvram_write_byte(unsigned char val, int addr)
>  }
>  EXPORT_SYMBOL(nvram_write_byte);
>  
> +ssize_t nvram_size(void)
> +{
> +	if (ppc_md.nvram_size)
> +		return ppc_md.nvram_size();
> +	return -1;
> +}
> +EXPORT_SYMBOL(nvram_size);
> +
>  void nvram_sync(void)
>  {
>  	if (ppc_md.nvram_sync)
> diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
> index a00869c..e5f71f3 100644
> --- a/drivers/char/generic_nvram.c
> +++ b/drivers/char/generic_nvram.c
> @@ -2,7 +2,7 @@
>   * Generic /dev/nvram driver for architectures providing some
>   * "generic" hooks, that is :
>   *
> - * nvram_read_byte, nvram_write_byte, nvram_sync
> + * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_size
>   *
>   * Note that an additional hook is supported for PowerMac only
>   * for getting the nvram "partition" informations
> @@ -28,6 +28,8 @@
>  
>  #define NVRAM_SIZE	8192
>  
> +static ssize_t nvram_len;
> +
>  static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  {
>  	lock_kernel();
> @@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  		offset += file->f_pos;
>  		break;
>  	case 2:
> -		offset += NVRAM_SIZE;
> +		offset += nvram_len;
>  		break;
>  	}
>  	if (offset < 0) {
> @@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
>  
>  	if (!access_ok(VERIFY_WRITE, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
>  		if (__put_user(nvram_read_byte(i), p))
>  			return -EFAULT;
>  	*ppos = i;
> @@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
>  
>  	if (!access_ok(VERIFY_READ, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
>  		if (__get_user(c, p))
>  			return -EFAULT;
>  		nvram_write_byte(c, i);
> @@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
>  
>  int __init nvram_init(void)
>  {
> +	int ret = 0;
> +
>  	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
>  		NVRAM_VERSION);
> -	return misc_register(&nvram_dev);
> +	ret = misc_register(&nvram_dev);
> +	if (ret != 0)
> +		goto out;
> +
> +	nvram_len = nvram_size();
> +	if (nvram_len < 0)
> +		nvram_len = NVRAM_SIZE;
> +
> +out:
> +	return ret;
>  }
>  
>  void __exit nvram_cleanup(void)

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

* Re: [PATCH 0/5] Generic NVRAM support for large MMIO devices
  2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
                   ` (4 preceding siblings ...)
  2009-07-02 16:12 ` [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A Martyn Welch
@ 2009-07-23  7:44 ` Benjamin Herrenschmidt
  2009-07-24  9:25   ` Martyn Welch
  5 siblings, 1 reply; 21+ messages in thread
From: Benjamin Herrenschmidt @ 2009-07-23  7:44 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev

On Thu, 2009-07-02 at 17:12 +0100, Martyn Welch wrote:
> The following series allows the generic NVRAM driver to access MMIO
> based NVRAMs. In addition it enables support for NVRAMs of sizes
> differing from those found on PowerPC Macs (providing a safe
> fallback). Patches are also included to enable support for the NVRAM
> found on the GE Fanuc PPC9A, SBC310 and SBC610.
> 
> If this patch series is unsuitable this late in the day for 2.6.31,
> please concider it for 2.6.32.

No major issue with the series other than the change to the generic
nvram code which needs to not break other architectures :-) Also,
it will probably need to go through Andrew Morton, unless there's
a maintainer for that driver, is there ?

Once you sort out that aspect of the patch series, I'm happy to take
the rest in powerpc.git

Cheers,
Ben.

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

* Re: [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-07-23  7:43   ` Benjamin Herrenschmidt
@ 2009-07-23 11:31     ` Martyn Welch
  0 siblings, 0 replies; 21+ messages in thread
From: Martyn Welch @ 2009-07-23 11:31 UTC (permalink / raw)
  To: Benjamin Herrenschmidt; +Cc: linuxppc-dev

Benjamin Herrenschmidt wrote:
> On Thu, 2009-07-02 at 17:12 +0100, Martyn Welch wrote:
>   
>> Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.
>>
>> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
>>     
>
> What about other archs that use this driver ? They would also need
> that new nvram_size() ...
>   
I'm fairly confident that this driver is solely used by the PowerPC 
architecture. The config option being set in  arch/powerpc/Kconfig[1]. 
Other than the obvious matches in drivers/char/Makefile[2] and powerpc 
defconfigs, the only other places I can find the option being used are:

* As a requirement for CONFIG_NVRAM on the PowerPC platform in 
drivers/char/Kconfig[3]
* In "include/config/auto.conf" and "include/linux/autoconf.h". Are 
these for generation of generic configs?

Martyn

[1] 
http://git.kernel.org/gitweb.cgi?p=linux/kernel/git/benh/powerpc.git;a=blob;f=arch/powerpc/Kconfig#l145
[2] 
http://git.kernel.org/gitweb.cgi?p=linux/kernel/git/benh/powerpc.git;a=blob;f=drivers/char/Makefile#l83
[3] 
http://git.kernel.org/gitweb.cgi?p=linux/kernel/git/benh/powerpc.git;a=blob;f=drivers/char/Kconfig#l777
> BTW. This patch touches non-arch code so should at least be CCed to lkml
>
> Cheers,
> Ben.
>
>   
>> ---
>>
>>  arch/powerpc/include/asm/nvram.h |    3 +++
>>  arch/powerpc/kernel/setup_32.c   |    8 ++++++++
>>  drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
>>  3 files changed, 31 insertions(+), 7 deletions(-)
>>
>> diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
>> index efde5ac..71df8b2 100644
>> --- a/arch/powerpc/include/asm/nvram.h
>> +++ b/arch/powerpc/include/asm/nvram.h
>> @@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
>>  /* Synchronize NVRAM */
>>  extern void	nvram_sync(void);
>>  
>> +/* Determine NVRAM size */
>> +extern ssize_t nvram_size(void);
>> +
>>  /* Normal access to NVRAM */
>>  extern unsigned char nvram_read_byte(int i);
>>  extern void nvram_write_byte(unsigned char c, int i);
>> diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
>> index 1d15424..28f7570 100644
>> --- a/arch/powerpc/kernel/setup_32.c
>> +++ b/arch/powerpc/kernel/setup_32.c
>> @@ -208,6 +208,14 @@ void nvram_write_byte(unsigned char val, int addr)
>>  }
>>  EXPORT_SYMBOL(nvram_write_byte);
>>  
>> +ssize_t nvram_size(void)
>> +{
>> +	if (ppc_md.nvram_size)
>> +		return ppc_md.nvram_size();
>> +	return -1;
>> +}
>> +EXPORT_SYMBOL(nvram_size);
>> +
>>  void nvram_sync(void)
>>  {
>>  	if (ppc_md.nvram_sync)
>> diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
>> index a00869c..e5f71f3 100644
>> --- a/drivers/char/generic_nvram.c
>> +++ b/drivers/char/generic_nvram.c
>> @@ -2,7 +2,7 @@
>>   * Generic /dev/nvram driver for architectures providing some
>>   * "generic" hooks, that is :
>>   *
>> - * nvram_read_byte, nvram_write_byte, nvram_sync
>> + * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_size
>>   *
>>   * Note that an additional hook is supported for PowerMac only
>>   * for getting the nvram "partition" informations
>> @@ -28,6 +28,8 @@
>>  
>>  #define NVRAM_SIZE	8192
>>  
>> +static ssize_t nvram_len;
>> +
>>  static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>>  {
>>  	lock_kernel();
>> @@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>>  		offset += file->f_pos;
>>  		break;
>>  	case 2:
>> -		offset += NVRAM_SIZE;
>> +		offset += nvram_len;
>>  		break;
>>  	}
>>  	if (offset < 0) {
>> @@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
>>  
>>  	if (!access_ok(VERIFY_WRITE, buf, count))
>>  		return -EFAULT;
>> -	if (*ppos >= NVRAM_SIZE)
>> +	if (*ppos >= nvram_len)
>>  		return 0;
>> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
>> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
>>  		if (__put_user(nvram_read_byte(i), p))
>>  			return -EFAULT;
>>  	*ppos = i;
>> @@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
>>  
>>  	if (!access_ok(VERIFY_READ, buf, count))
>>  		return -EFAULT;
>> -	if (*ppos >= NVRAM_SIZE)
>> +	if (*ppos >= nvram_len)
>>  		return 0;
>> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
>> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
>>  		if (__get_user(c, p))
>>  			return -EFAULT;
>>  		nvram_write_byte(c, i);
>> @@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
>>  
>>  int __init nvram_init(void)
>>  {
>> +	int ret = 0;
>> +
>>  	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
>>  		NVRAM_VERSION);
>> -	return misc_register(&nvram_dev);
>> +	ret = misc_register(&nvram_dev);
>> +	if (ret != 0)
>> +		goto out;
>> +
>> +	nvram_len = nvram_size();
>> +	if (nvram_len < 0)
>> +		nvram_len = NVRAM_SIZE;
>> +
>> +out:
>> +	return ret;
>>  }
>>  
>>  void __exit nvram_cleanup(void)
>>     
>
>   


-- 
Martyn Welch MEng MPhil MIET (Principal Software Engineer)   T:+44(0)1327322748
GE Fanuc Intelligent Platforms Ltd,        |Registered in England and Wales
Tove Valley Business Park, Towcester,      |(3828642) at 100 Barbirolli Square,
Northants, NN12 6PF, UK T:+44(0)1327359444 |Manchester,M2 3AB  VAT:GB 927559189

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

* Re: [PATCH 0/5] Generic NVRAM support for large MMIO devices
  2009-07-23  7:44 ` [PATCH 0/5] Generic NVRAM support for large MMIO devices Benjamin Herrenschmidt
@ 2009-07-24  9:25   ` Martyn Welch
  2009-07-24 10:35     ` Benjamin Herrenschmidt
  0 siblings, 1 reply; 21+ messages in thread
From: Martyn Welch @ 2009-07-24  9:25 UTC (permalink / raw)
  To: Benjamin Herrenschmidt; +Cc: linuxppc-dev, akpm

Benjamin Herrenschmidt wrote:
> On Thu, 2009-07-02 at 17:12 +0100, Martyn Welch wrote:
>   
>> The following series allows the generic NVRAM driver to access MMIO
>> based NVRAMs. In addition it enables support for NVRAMs of sizes
>> differing from those found on PowerPC Macs (providing a safe
>> fallback). Patches are also included to enable support for the NVRAM
>> found on the GE Fanuc PPC9A, SBC310 and SBC610.
>>
>> If this patch series is unsuitable this late in the day for 2.6.31,
>> please concider it for 2.6.32.
>>     
>
> No major issue with the series other than the change to the generic
> nvram code which needs to not break other architectures :-) Also,
> it will probably need to go through Andrew Morton, unless there's
> a maintainer for that driver, is there ?
>   
I'm not aware of a maintainer for the "generic nvram" driver. As 
mentioned in my other email, I'm fairly confident that this driver 
(/drivers/char/generic_nvram.c) is only used on PowerPC. I'm beginning 
to enter what is for me uncharted territory :-) How should I proceed? 
Are you happy to take the entire patch series, do I send the entire 
patch series to Andrew and LKML or just patch 2/5?

Martyn
> Once you sort out that aspect of the patch series, I'm happy to take
> the rest in powerpc.git
>
> Cheers,
> Ben.
>
>   


-- 
Martyn Welch MEng MPhil MIET (Principal Software Engineer)   T:+44(0)1327322748
GE Fanuc Intelligent Platforms Ltd,        |Registered in England and Wales
Tove Valley Business Park, Towcester,      |(3828642) at 100 Barbirolli Square,
Northants, NN12 6PF, UK T:+44(0)1327359444 |Manchester,M2 3AB  VAT:GB 927559189

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

* Re: [PATCH 0/5] Generic NVRAM support for large MMIO devices
  2009-07-24  9:25   ` Martyn Welch
@ 2009-07-24 10:35     ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 21+ messages in thread
From: Benjamin Herrenschmidt @ 2009-07-24 10:35 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev, akpm


> I'm not aware of a maintainer for the "generic nvram" driver. As 
> mentioned in my other email, I'm fairly confident that this driver 
> (/drivers/char/generic_nvram.c) is only used on PowerPC. I'm beginning 
> to enter what is for me uncharted territory :-) How should I proceed? 
> Are you happy to take the entire patch series, do I send the entire 
> patch series to Andrew and LKML or just patch 2/5?

I'll dbl check, if it's only ppc then I'll take the whole series,

As usual, if you don't see things happening by end of next week, ping
me :-) But it's on patchwork so hopefully it won't fall through the
cracks.

Cheers,
Ben.

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

* Re: [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-07-02 16:12 ` [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips Martyn Welch
  2009-07-23  7:43   ` Benjamin Herrenschmidt
@ 2009-08-13  7:15   ` Benjamin Herrenschmidt
  2009-08-13  8:03     ` [PATCH v2] " Martyn Welch
  1 sibling, 1 reply; 21+ messages in thread
From: Benjamin Herrenschmidt @ 2009-08-13  7:15 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev

On Thu, 2009-07-02 at 17:12 +0100, Martyn Welch wrote:
> Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.
> 
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>

I was about to stick 1/5 and 2/5 in -test (on the way to -next) but
I hit this when building 64-bit kernels:

/home/benh/linux-powerpc-test/arch/powerpc/platforms/pseries/nvram.c:26: error: ‘nvram_size’ redeclared as different kind of symbol
/home/benh/linux-powerpc-test/arch/powerpc/include/asm/nvram.h:111: error: previous declaration of ‘nvram_size’ was here
make[3]: *** [arch/powerpc/platforms/pseries/nvram.o] Error 1

Looks trivial enough, can you respin the patch ?

Cheers,
Ben.

> ---
> 
>  arch/powerpc/include/asm/nvram.h |    3 +++
>  arch/powerpc/kernel/setup_32.c   |    8 ++++++++
>  drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
>  3 files changed, 31 insertions(+), 7 deletions(-)
> 
> diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
> index efde5ac..71df8b2 100644
> --- a/arch/powerpc/include/asm/nvram.h
> +++ b/arch/powerpc/include/asm/nvram.h
> @@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
>  /* Synchronize NVRAM */
>  extern void	nvram_sync(void);
>  
> +/* Determine NVRAM size */
> +extern ssize_t nvram_size(void);
> +
>  /* Normal access to NVRAM */
>  extern unsigned char nvram_read_byte(int i);
>  extern void nvram_write_byte(unsigned char c, int i);
> diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
> index 1d15424..28f7570 100644
> --- a/arch/powerpc/kernel/setup_32.c
> +++ b/arch/powerpc/kernel/setup_32.c
> @@ -208,6 +208,14 @@ void nvram_write_byte(unsigned char val, int addr)
>  }
>  EXPORT_SYMBOL(nvram_write_byte);
>  
> +ssize_t nvram_size(void)
> +{
> +	if (ppc_md.nvram_size)
> +		return ppc_md.nvram_size();
> +	return -1;
> +}
> +EXPORT_SYMBOL(nvram_size);
> +
>  void nvram_sync(void)
>  {
>  	if (ppc_md.nvram_sync)
> diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
> index a00869c..e5f71f3 100644
> --- a/drivers/char/generic_nvram.c
> +++ b/drivers/char/generic_nvram.c
> @@ -2,7 +2,7 @@
>   * Generic /dev/nvram driver for architectures providing some
>   * "generic" hooks, that is :
>   *
> - * nvram_read_byte, nvram_write_byte, nvram_sync
> + * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_size
>   *
>   * Note that an additional hook is supported for PowerMac only
>   * for getting the nvram "partition" informations
> @@ -28,6 +28,8 @@
>  
>  #define NVRAM_SIZE	8192
>  
> +static ssize_t nvram_len;
> +
>  static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  {
>  	lock_kernel();
> @@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  		offset += file->f_pos;
>  		break;
>  	case 2:
> -		offset += NVRAM_SIZE;
> +		offset += nvram_len;
>  		break;
>  	}
>  	if (offset < 0) {
> @@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
>  
>  	if (!access_ok(VERIFY_WRITE, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
>  		if (__put_user(nvram_read_byte(i), p))
>  			return -EFAULT;
>  	*ppos = i;
> @@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
>  
>  	if (!access_ok(VERIFY_READ, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
>  		if (__get_user(c, p))
>  			return -EFAULT;
>  		nvram_write_byte(c, i);
> @@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
>  
>  int __init nvram_init(void)
>  {
> +	int ret = 0;
> +
>  	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
>  		NVRAM_VERSION);
> -	return misc_register(&nvram_dev);
> +	ret = misc_register(&nvram_dev);
> +	if (ret != 0)
> +		goto out;
> +
> +	nvram_len = nvram_size();
> +	if (nvram_len < 0)
> +		nvram_len = NVRAM_SIZE;
> +
> +out:
> +	return ret;
>  }
>  
>  void __exit nvram_cleanup(void)

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

* [PATCH v2] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-08-13  7:15   ` Benjamin Herrenschmidt
@ 2009-08-13  8:03     ` Martyn Welch
  2009-08-13  8:05       ` Benjamin Herrenschmidt
  0 siblings, 1 reply; 21+ messages in thread
From: Martyn Welch @ 2009-08-13  8:03 UTC (permalink / raw)
  To: benh; +Cc: linuxppc-dev

Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.

Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
---

Ben: Is this a suitable solution?

v2: rename nvram_size() to nvram_get_size(), thus avoiding the collision with the global
variables in arch/powerpc/platforms/pseries/nvram.c and
arch/powerpc/platforms/chrp/nvram.c of the same name.

 arch/powerpc/include/asm/nvram.h |    3 +++
 arch/powerpc/kernel/setup_32.c   |    8 ++++++++
 drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
 3 files changed, 31 insertions(+), 7 deletions(-)

diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
index efde5ac..6c587ed 100644
--- a/arch/powerpc/include/asm/nvram.h
+++ b/arch/powerpc/include/asm/nvram.h
@@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
 /* Synchronize NVRAM */
 extern void	nvram_sync(void);
 
+/* Determine NVRAM size */
+extern ssize_t nvram_get_size(void);
+
 /* Normal access to NVRAM */
 extern unsigned char nvram_read_byte(int i);
 extern void nvram_write_byte(unsigned char c, int i);
diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
index e1e3059..53bcf3d 100644
--- a/arch/powerpc/kernel/setup_32.c
+++ b/arch/powerpc/kernel/setup_32.c
@@ -210,6 +210,14 @@ void nvram_write_byte(unsigned char val, int addr)
 }
 EXPORT_SYMBOL(nvram_write_byte);
 
+ssize_t nvram_get_size(void)
+{
+	if (ppc_md.nvram_size)
+		return ppc_md.nvram_size();
+	return -1;
+}
+EXPORT_SYMBOL(nvram_get_size);
+
 void nvram_sync(void)
 {
 	if (ppc_md.nvram_sync)
diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
index a00869c..ef31738 100644
--- a/drivers/char/generic_nvram.c
+++ b/drivers/char/generic_nvram.c
@@ -2,7 +2,7 @@
  * Generic /dev/nvram driver for architectures providing some
  * "generic" hooks, that is :
  *
- * nvram_read_byte, nvram_write_byte, nvram_sync
+ * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_get_size
  *
  * Note that an additional hook is supported for PowerMac only
  * for getting the nvram "partition" informations
@@ -28,6 +28,8 @@
 
 #define NVRAM_SIZE	8192
 
+static ssize_t nvram_len;
+
 static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
 {
 	lock_kernel();
@@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
 		offset += file->f_pos;
 		break;
 	case 2:
-		offset += NVRAM_SIZE;
+		offset += nvram_len;
 		break;
 	}
 	if (offset < 0) {
@@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
 
 	if (!access_ok(VERIFY_WRITE, buf, count))
 		return -EFAULT;
-	if (*ppos >= NVRAM_SIZE)
+	if (*ppos >= nvram_len)
 		return 0;
-	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
+	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
 		if (__put_user(nvram_read_byte(i), p))
 			return -EFAULT;
 	*ppos = i;
@@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
 
 	if (!access_ok(VERIFY_READ, buf, count))
 		return -EFAULT;
-	if (*ppos >= NVRAM_SIZE)
+	if (*ppos >= nvram_len)
 		return 0;
-	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
+	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
 		if (__get_user(c, p))
 			return -EFAULT;
 		nvram_write_byte(c, i);
@@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
 
 int __init nvram_init(void)
 {
+	int ret = 0;
+
 	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
 		NVRAM_VERSION);
-	return misc_register(&nvram_dev);
+	ret = misc_register(&nvram_dev);
+	if (ret != 0)
+		goto out;
+
+	nvram_len = nvram_get_size();
+	if (nvram_len < 0)
+		nvram_len = NVRAM_SIZE;
+
+out:
+	return ret;
 }
 
 void __exit nvram_cleanup(void)

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

* Re: [PATCH v2] Mechanism to enable use Generic NVRAM driver for different size chips
  2009-08-13  8:03     ` [PATCH v2] " Martyn Welch
@ 2009-08-13  8:05       ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 21+ messages in thread
From: Benjamin Herrenschmidt @ 2009-08-13  8:05 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev

On Thu, 2009-08-13 at 09:03 +0100, Martyn Welch wrote:
> Remove the reliance on a staticly defined NVRAM size, allowing platforms to support NVRAMs with sizes differing from the standard. A fall back value is provided for platforms not supporting this extension.
> 
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
> ---
> 
> Ben: Is this a suitable solution?

Yup. I'll have a closer look tomorrow. Thanks.

Cheers,
Ben.

> v2: rename nvram_size() to nvram_get_size(), thus avoiding the collision with the global
> variables in arch/powerpc/platforms/pseries/nvram.c and
> arch/powerpc/platforms/chrp/nvram.c of the same name.
> 
>  arch/powerpc/include/asm/nvram.h |    3 +++
>  arch/powerpc/kernel/setup_32.c   |    8 ++++++++
>  drivers/char/generic_nvram.c     |   27 ++++++++++++++++++++-------
>  3 files changed, 31 insertions(+), 7 deletions(-)
> 
> diff --git a/arch/powerpc/include/asm/nvram.h b/arch/powerpc/include/asm/nvram.h
> index efde5ac..6c587ed 100644
> --- a/arch/powerpc/include/asm/nvram.h
> +++ b/arch/powerpc/include/asm/nvram.h
> @@ -107,6 +107,9 @@ extern void	pmac_xpram_write(int xpaddr, u8 data);
>  /* Synchronize NVRAM */
>  extern void	nvram_sync(void);
>  
> +/* Determine NVRAM size */
> +extern ssize_t nvram_get_size(void);
> +
>  /* Normal access to NVRAM */
>  extern unsigned char nvram_read_byte(int i);
>  extern void nvram_write_byte(unsigned char c, int i);
> diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
> index e1e3059..53bcf3d 100644
> --- a/arch/powerpc/kernel/setup_32.c
> +++ b/arch/powerpc/kernel/setup_32.c
> @@ -210,6 +210,14 @@ void nvram_write_byte(unsigned char val, int addr)
>  }
>  EXPORT_SYMBOL(nvram_write_byte);
>  
> +ssize_t nvram_get_size(void)
> +{
> +	if (ppc_md.nvram_size)
> +		return ppc_md.nvram_size();
> +	return -1;
> +}
> +EXPORT_SYMBOL(nvram_get_size);
> +
>  void nvram_sync(void)
>  {
>  	if (ppc_md.nvram_sync)
> diff --git a/drivers/char/generic_nvram.c b/drivers/char/generic_nvram.c
> index a00869c..ef31738 100644
> --- a/drivers/char/generic_nvram.c
> +++ b/drivers/char/generic_nvram.c
> @@ -2,7 +2,7 @@
>   * Generic /dev/nvram driver for architectures providing some
>   * "generic" hooks, that is :
>   *
> - * nvram_read_byte, nvram_write_byte, nvram_sync
> + * nvram_read_byte, nvram_write_byte, nvram_sync, nvram_get_size
>   *
>   * Note that an additional hook is supported for PowerMac only
>   * for getting the nvram "partition" informations
> @@ -28,6 +28,8 @@
>  
>  #define NVRAM_SIZE	8192
>  
> +static ssize_t nvram_len;
> +
>  static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  {
>  	lock_kernel();
> @@ -36,7 +38,7 @@ static loff_t nvram_llseek(struct file *file, loff_t offset, int origin)
>  		offset += file->f_pos;
>  		break;
>  	case 2:
> -		offset += NVRAM_SIZE;
> +		offset += nvram_len;
>  		break;
>  	}
>  	if (offset < 0) {
> @@ -56,9 +58,9 @@ static ssize_t read_nvram(struct file *file, char __user *buf,
>  
>  	if (!access_ok(VERIFY_WRITE, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count)
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count)
>  		if (__put_user(nvram_read_byte(i), p))
>  			return -EFAULT;
>  	*ppos = i;
> @@ -74,9 +76,9 @@ static ssize_t write_nvram(struct file *file, const char __user *buf,
>  
>  	if (!access_ok(VERIFY_READ, buf, count))
>  		return -EFAULT;
> -	if (*ppos >= NVRAM_SIZE)
> +	if (*ppos >= nvram_len)
>  		return 0;
> -	for (i = *ppos; count > 0 && i < NVRAM_SIZE; ++i, ++p, --count) {
> +	for (i = *ppos; count > 0 && i < nvram_len; ++i, ++p, --count) {
>  		if (__get_user(c, p))
>  			return -EFAULT;
>  		nvram_write_byte(c, i);
> @@ -133,9 +135,20 @@ static struct miscdevice nvram_dev = {
>  
>  int __init nvram_init(void)
>  {
> +	int ret = 0;
> +
>  	printk(KERN_INFO "Generic non-volatile memory driver v%s\n",
>  		NVRAM_VERSION);
> -	return misc_register(&nvram_dev);
> +	ret = misc_register(&nvram_dev);
> +	if (ret != 0)
> +		goto out;
> +
> +	nvram_len = nvram_get_size();
> +	if (nvram_len < 0)
> +		nvram_len = NVRAM_SIZE;
> +
> +out:
> +	return ret;
>  }
>  
>  void __exit nvram_cleanup(void)

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

* Re: [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-07-02 16:12 ` [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610 Martyn Welch
@ 2009-11-05 14:10   ` Kumar Gala
  2009-11-05 14:23     ` Martyn Welch
  2009-11-12 14:03   ` Kumar Gala
  1 sibling, 1 reply; 21+ messages in thread
From: Kumar Gala @ 2009-11-05 14:10 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev


On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:

> This patch enables the NVRAM found on the GE Fanuc SBC610
>
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
> ---
>
> arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
> arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
> arch/powerpc/platforms/86xx/Kconfig            |    1 +
> arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
> 4 files changed, 14 insertions(+), 2 deletions(-)

I assume these still work w/the updates to the other patches?

- k

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

* Re: [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-11-05 14:10   ` Kumar Gala
@ 2009-11-05 14:23     ` Martyn Welch
  2009-11-05 14:41       ` Kumar Gala
  0 siblings, 1 reply; 21+ messages in thread
From: Martyn Welch @ 2009-11-05 14:23 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev

Kumar Gala wrote:
>
> On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:
>
>> This patch enables the NVRAM found on the GE Fanuc SBC610
>>
>> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
>> ---
>>
>> arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
>> arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
>> arch/powerpc/platforms/86xx/Kconfig            |    1 +
>> arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
>> 4 files changed, 14 insertions(+), 2 deletions(-)
>
> I assume these still work w/the updates to the other patches?
>
> - k
I'm just updating your tree to ensure that the patches still apply (and 
compile) cleanly. I'm fairly confident that they will.

Martyn

-- 
Martyn Welch MEng MPhil MIET (Principal Software Engineer)   T:+44(0)1327322748
GE Fanuc Intelligent Platforms Ltd,        |Registered in England and Wales
Tove Valley Business Park, Towcester,      |(3828642) at 100 Barbirolli Square,
Northants, NN12 6PF, UK T:+44(0)1327359444 |Manchester,M2 3AB  VAT:GB 927559189

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

* Re: [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-11-05 14:23     ` Martyn Welch
@ 2009-11-05 14:41       ` Kumar Gala
  2009-11-05 14:53         ` Martyn Welch
  0 siblings, 1 reply; 21+ messages in thread
From: Kumar Gala @ 2009-11-05 14:41 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev


On Nov 5, 2009, at 8:23 AM, Martyn Welch wrote:

> Kumar Gala wrote:
>>
>> On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:
>>
>>> This patch enables the NVRAM found on the GE Fanuc SBC610
>>>
>>> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
>>> ---
>>>
>>> arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
>>> arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
>>> arch/powerpc/platforms/86xx/Kconfig            |    1 +
>>> arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
>>> 4 files changed, 14 insertions(+), 2 deletions(-)
>>
>> I assume these still work w/the updates to the other patches?
>>
>> - k
> I'm just updating your tree to ensure that the patches still apply  
> (and compile) cleanly. I'm fairly confident that they will.

looks like I'm getting some defconfig merge conflicts.  I'll deal with  
them but will apply these after defconfig updates make it into benh's  
next tree.

- k

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

* Re: [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-11-05 14:41       ` Kumar Gala
@ 2009-11-05 14:53         ` Martyn Welch
  0 siblings, 0 replies; 21+ messages in thread
From: Martyn Welch @ 2009-11-05 14:53 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev

Kumar Gala wrote:
>
> On Nov 5, 2009, at 8:23 AM, Martyn Welch wrote:
>
>> Kumar Gala wrote:
>>>
>>> On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:
>>>
>>>> This patch enables the NVRAM found on the GE Fanuc SBC610
>>>>
>>>> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
>>>> ---
>>>>
>>>> arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
>>>> arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
>>>> arch/powerpc/platforms/86xx/Kconfig            |    1 +
>>>> arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
>>>> 4 files changed, 14 insertions(+), 2 deletions(-)
>>>
>>> I assume these still work w/the updates to the other patches?
>>>
>>> - k
>> I'm just updating your tree to ensure that the patches still apply 
>> (and compile) cleanly. I'm fairly confident that they will.
>
> looks like I'm getting some defconfig merge conflicts.  I'll deal with 
> them but will apply these after defconfig updates make it into benh's 
> next tree.
>
> - k
The patches are sitting in stgit here - I noticed the offset of the 
defconfig changes was different, but didn't notice anything else 
different. I can resend if that's easier?

Martyn

-- 
Martyn Welch MEng MPhil MIET (Principal Software Engineer)   T:+44(0)1327322748
GE Fanuc Intelligent Platforms Ltd,        |Registered in England and Wales
Tove Valley Business Park, Towcester,      |(3828642) at 100 Barbirolli Square,
Northants, NN12 6PF, UK T:+44(0)1327359444 |Manchester,M2 3AB  VAT:GB 927559189

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

* Re: [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610
  2009-07-02 16:12 ` [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610 Martyn Welch
  2009-11-05 14:10   ` Kumar Gala
@ 2009-11-12 14:03   ` Kumar Gala
  1 sibling, 0 replies; 21+ messages in thread
From: Kumar Gala @ 2009-11-12 14:03 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev


On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:

> This patch enables the NVRAM found on the GE Fanuc SBC610
>
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
> ---
>
> arch/powerpc/boot/dts/gef_sbc610.dts           |    6 ++++++
> arch/powerpc/configs/86xx/gef_sbc610_defconfig |    4 ++--
> arch/powerpc/platforms/86xx/Kconfig            |    1 +
> arch/powerpc/platforms/86xx/gef_sbc610.c       |    5 +++++
> 4 files changed, 14 insertions(+), 2 deletions(-)

applied to next

- k

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

* Re: [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310
  2009-07-02 16:12 ` [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310 Martyn Welch
@ 2009-11-12 14:04   ` Kumar Gala
  0 siblings, 0 replies; 21+ messages in thread
From: Kumar Gala @ 2009-11-12 14:04 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev


On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:

> Add support for NVRAM on GE Fanuc's SBC310.
>
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
> ---
>
> arch/powerpc/boot/dts/gef_sbc310.dts           |    6 ++++++
> arch/powerpc/configs/86xx/gef_sbc310_defconfig |    4 ++--
> arch/powerpc/platforms/86xx/Kconfig            |    1 +
> arch/powerpc/platforms/86xx/gef_sbc310.c       |    5 +++++
> 4 files changed, 14 insertions(+), 2 deletions(-)

applied to next

- k

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

* Re: [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A
  2009-07-02 16:12 ` [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A Martyn Welch
@ 2009-11-12 14:04   ` Kumar Gala
  0 siblings, 0 replies; 21+ messages in thread
From: Kumar Gala @ 2009-11-12 14:04 UTC (permalink / raw)
  To: Martyn Welch; +Cc: linuxppc-dev


On Jul 2, 2009, at 11:12 AM, Martyn Welch wrote:

> Add support for NVRAM on GE Fanuc's PPC9A.
>
> Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
> ---
>
> arch/powerpc/boot/dts/gef_ppc9a.dts           |    6 ++++++
> arch/powerpc/configs/86xx/gef_ppc9a_defconfig |    4 ++--
> arch/powerpc/platforms/86xx/Kconfig           |    1 +
> arch/powerpc/platforms/86xx/gef_ppc9a.c       |    5 +++++
> 4 files changed, 14 insertions(+), 2 deletions(-)

applied to next

- k

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

end of thread, other threads:[~2009-11-12 14:04 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-07-02 16:12 [PATCH 0/5] Generic NVRAM support for large MMIO devices Martyn Welch
2009-07-02 16:12 ` [PATCH 1/5] Allow byte length reads from mmio NVRAM driver Martyn Welch
2009-07-02 16:12 ` [PATCH 2/5] Mechanism to enable use Generic NVRAM driver for different size chips Martyn Welch
2009-07-23  7:43   ` Benjamin Herrenschmidt
2009-07-23 11:31     ` Martyn Welch
2009-08-13  7:15   ` Benjamin Herrenschmidt
2009-08-13  8:03     ` [PATCH v2] " Martyn Welch
2009-08-13  8:05       ` Benjamin Herrenschmidt
2009-07-02 16:12 ` [PATCH 3/5] powerpc/86xx: Enable NVRAM on GE Fanuc's SBC610 Martyn Welch
2009-11-05 14:10   ` Kumar Gala
2009-11-05 14:23     ` Martyn Welch
2009-11-05 14:41       ` Kumar Gala
2009-11-05 14:53         ` Martyn Welch
2009-11-12 14:03   ` Kumar Gala
2009-07-02 16:12 ` [PATCH 4/5] powerpc/86xx: Support for NVRAM on GE Fanuc's SBC310 Martyn Welch
2009-11-12 14:04   ` Kumar Gala
2009-07-02 16:12 ` [PATCH 5/5] powerpc/86xx: Support for NVRAM on GE Fanuc's PPC9A Martyn Welch
2009-11-12 14:04   ` Kumar Gala
2009-07-23  7:44 ` [PATCH 0/5] Generic NVRAM support for large MMIO devices Benjamin Herrenschmidt
2009-07-24  9:25   ` Martyn Welch
2009-07-24 10:35     ` Benjamin Herrenschmidt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).