* Re: 8641D with linux 2.6.29 did'n show second cpu
From: Kumar Gala @ 2009-03-31 13:20 UTC (permalink / raw)
To: Eduard Fuchs; +Cc: linuxppc-dev
In-Reply-To: <200903311215.55237.edfuchs@uni-kassel.de>
On Mar 31, 2009, at 5:15 AM, Eduard Fuchs wrote:
> Hi,
>
> I'm testing the evaluation board from freescale (MPC8641DHPCN) with
> the latest
> linux kernel (2.6.29) and the second core seems disabled. CONFIG_SPM
> is
> enabled but the /proc/cpuinfo shows only one cpu. With original
> 2.6.27 kernel
> both cpu cores appears in /proc/cpuinfo.
>
> Has anyone an idea how can i enable the second core?
Are you using u-boot? I can't remember if you need a newer u-boot to
deal with changes in how we bring up the second core.
- k
^ permalink raw reply
* Re: powerpc/85xx: Add support for the "socrates" board (MPC8544)
From: Grant Likely @ 2009-03-31 13:23 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev
In-Reply-To: <49D1E3E5.3080607@grandegger.com>
On Tue, Mar 31, 2009 at 3:35 AM, Wolfgang Grandegger <wg@grandegger.com> wr=
ote:
> Grant Likely wrote:
>> I agree 100% with David's comments, and I have some additional ones belo=
w.
>>
>> On Thu, Mar 19, 2009 at 9:26 AM, Wolfgang Grandegger <wg@grandegger.com>=
wrote:
>>> + =A0 =A0 =A0 soc8544@e0000000 {
>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #address-cells =3D <1>;
>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #size-cells =3D <1>;
>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 device_type =3D "soc";
>>
>> Drop device_type here too.
>
> Grrr, I just realized that removing the devices type "soc" has broken
> fsl_get_sys_freq(). See:
>
> http://lxr.linux.no/linux+v2.6.29/arch/powerpc/sysdev/fsl_soc.c#L80
>
> We need a quick fix and we could take the occasion to establish a common
> function for the MPC52xx as well, but it's not obvious to me how to find
> the SOC node without the device type property.
SoC node should have a compatible property, just like everything else.
compatible =3D "fsl,mpc8544-immr"; (immr =3D=3D Internally Memory Mapped R=
egisters)
Many other boards already do this.
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* [PATCH] Add hvc_console to MAINTAINERS
From: Josh Boyer @ 2009-03-31 13:29 UTC (permalink / raw)
To: Andrew Morton; +Cc: linuxppc-dev, roel.kluin, linux-kernel
In-Reply-To: <20090330141852.59baaeda.akpm@linux-foundation.org>
Add a MAINTAINERS entry for the hypervisor virtual console support
used on IBM POWER servers.
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
diff --git a/MAINTAINERS b/MAINTAINERS
index c5f4e9d..387ad45 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2176,6 +2176,11 @@ W: http://www.ia64-linux.org/
T: git kernel.org:/pub/scm/linux/kernel/git/aegl/linux-2.6.git
S: Maintained
+IBM HYPERVISOR VIRTUAL CONSOLE
+P: Several
+L: linuxppc-dev@ozlabs.org
+S: Maintained
+
IBM MCA SCSI SUBSYSTEM DRIVER
P: Michael Lang
M: langa2@kph.uni-mainz.de
^ permalink raw reply related
* Re: [PATCH] powerpc: Make LOWMEM_CAM_NUM depend on FSL_BOOKE
From: Kumar Gala @ 2009-03-31 13:32 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev
In-Reply-To: <20090331120550.GA2332@yoda.jdub.homelinux.org>
On Mar 31, 2009, at 7:05 AM, Josh Boyer wrote:
> The recent addition of CONFIG_LOWMEM_CAM_BOOL and
> CONFIG_LOWMEM_CAM_NUM cause the latter to show up in configs
> that do not need it during 'make oldconfig'. Make LOWMEM_CAM_NUM
> depend on FSL_BOOKE.
>
> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
>
> ---
fixed up an applied
- k
^ permalink raw reply
* Re: [PATCH] powerpc: Remove unused symbols from fsl_devices.h
From: Kumar Gala @ 2009-03-31 13:32 UTC (permalink / raw)
To: Grant Likely; +Cc: linuxppc-dev, Kay Sievers, Greg Kroah-Hartmann
In-Reply-To: <20090328210715.27260.66043.stgit@localhost.localdomain>
On Mar 28, 2009, at 4:07 PM, Grant Likely wrote:
> From: Grant Likely <grant.likely@secretlab.ca>
>
> Remove old artifacts leftover from the platform driver gianfar and
> fsl_i2c drivers. These symbols became unused when the drivers
> were migrated over to use the of_platform bus.
>
> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
> ---
>
> include/linux/fsl_devices.h | 22 ----------------------
> 1 files changed, 0 insertions(+), 22 deletions(-)
applied
- k
^ permalink raw reply
* Re: powerpc/85xx: Add support for the "socrates" board (MPC8544)
From: Wolfgang Grandegger @ 2009-03-31 13:36 UTC (permalink / raw)
To: Grant Likely; +Cc: linuxppc-dev
In-Reply-To: <fa686aa40903310623r2b2db0adjb912cfefd3a321e2@mail.gmail.com>
Grant Likely wrote:
> On Tue, Mar 31, 2009 at 3:35 AM, Wolfgang Grandegger <wg@grandegger.com> wrote:
>> Grant Likely wrote:
>>> I agree 100% with David's comments, and I have some additional ones below.
>>>
>>> On Thu, Mar 19, 2009 at 9:26 AM, Wolfgang Grandegger <wg@grandegger.com> wrote:
>>>> + soc8544@e0000000 {
>>>> + #address-cells = <1>;
>>>> + #size-cells = <1>;
>>>> + device_type = "soc";
>>> Drop device_type here too.
>> Grrr, I just realized that removing the devices type "soc" has broken
>> fsl_get_sys_freq(). See:
>>
>> http://lxr.linux.no/linux+v2.6.29/arch/powerpc/sysdev/fsl_soc.c#L80
>>
>> We need a quick fix and we could take the occasion to establish a common
>> function for the MPC52xx as well, but it's not obvious to me how to find
>> the SOC node without the device type property.
>
> SoC node should have a compatible property, just like everything else.
>
> compatible = "fsl,mpc8544-immr"; (immr == Internally Memory Mapped Registers)
>
> Many other boards already do this.
Yes, it does, but searching for the SOC node is not straight-forward
because there is no common compatibility string but many CPU-specific
compatibility strings, e.g. "fsl,mpc8560-immr", etc. Have I missed
something?
Unfortunately, other 85xx functions search for the device type "soc" as
well. Therefore I think we must keep the devices type "soc" for the time
being. Kumar?
Wolfgang.
^ permalink raw reply
* Re: [PATCH 1/2] powerpc: i2c-mpc: preserve I2C clocking
From: Wolfram Sang @ 2009-03-31 13:39 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev, devicetree-discuss, linux-i2c
In-Reply-To: <20090331125451.600446749@denx.de>
[-- Attachment #1: Type: text/plain, Size: 2620 bytes --]
On Tue, Mar 31, 2009 at 02:50:29PM +0200, Wolfgang Grandegger wrote:
> The I2c node property "fsl,preserve-clocking" allows to overtake the
> clock settings from the boot loader and avoids the hard-coded setting.
>
> Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
> ---
> drivers/i2c/busses/i2c-mpc.c | 24 ++++++++++++++++--------
> 1 file changed, 16 insertions(+), 8 deletions(-)
>
> Index: linux-2.6/drivers/i2c/busses/i2c-mpc.c
> ===================================================================
> --- linux-2.6.orig/drivers/i2c/busses/i2c-mpc.c 2009-03-31 13:25:08.000000000 +0200
> +++ linux-2.6/drivers/i2c/busses/i2c-mpc.c 2009-03-31 13:28:03.000000000 +0200
> @@ -318,17 +318,24 @@
> {
> int result = 0;
> struct mpc_i2c *i2c;
> + int set_clock;
>
> i2c = kzalloc(sizeof(*i2c), GFP_KERNEL);
> if (!i2c)
> return -ENOMEM;
>
> - if (of_get_property(op->node, "dfsrr", NULL))
> - i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
> -
> - if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
> - of_device_is_compatible(op->node, "mpc5200-i2c"))
> - i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
> + if (of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
> + set_clock = 0;
> + } else {
> + set_clock = 1;
> +
> + if (of_get_property(op->node, "dfsrr", NULL))
> + i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
> +
> + if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
> + of_device_is_compatible(op->node, "mpc5200-i2c"))
> + i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
> + }
>
> init_waitqueue_head(&i2c->queue);
>
> @@ -348,8 +355,9 @@
> goto fail_request;
> }
> }
> -
> - mpc_i2c_setclock(i2c);
> +
> + if (set_clock)
> + mpc_i2c_setclock(i2c);
Can't we drop 'set_clock' with something like this here?
+ if (!of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
+
+ if (of_get_property(op->node, "dfsrr", NULL))
+ i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
+
+ if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
+ of_device_is_compatible(op->node, "mpc5200-i2c"))
+ i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
+
+ mpc_i2c_setclock(i2c);
+ }
>
> dev_set_drvdata(&op->dev, i2c);
>
>
> _______________________________________________
> devicetree-discuss mailing list
> devicetree-discuss@ozlabs.org
> https://ozlabs.org/mailman/listinfo/devicetree-discuss
Regards,
Wolfram
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]
^ permalink raw reply
* [PATCH 1/2] gianfar: Remove unused header
From: Kumar Gala @ 2009-03-31 13:42 UTC (permalink / raw)
To: David Miller; +Cc: netdev, linuxppc-dev
Now that the driver is exclusively an of_platform driver we no longer
use the structs and #defines in fsl_devices.h
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
drivers/net/gianfar.h | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/drivers/net/gianfar.h b/drivers/net/gianfar.h
index dd499d7..0642d52 100644
--- a/drivers/net/gianfar.h
+++ b/drivers/net/gianfar.h
@@ -45,7 +45,6 @@
#include <linux/crc32.h>
#include <linux/workqueue.h>
#include <linux/ethtool.h>
-#include <linux/fsl_devices.h>
/* The maximum number of packets to be handled in one call of gfar_poll */
#define GFAR_DEV_WEIGHT 64
--
1.5.6.6
^ permalink raw reply related
* [PATCH 2/2] ucc_geth: Remove unused header
From: Kumar Gala @ 2009-03-31 13:42 UTC (permalink / raw)
To: David Miller; +Cc: netdev, linuxppc-dev
In-Reply-To: <1238506979-8678-1-git-send-email-galak@kernel.crashing.org>
Now that the driver is exclusively an of_platform driver we no longer
use the structs and #defines in fsl_devices.h
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
drivers/net/ucc_geth.c | 1 -
drivers/net/ucc_geth.h | 1 -
drivers/net/ucc_geth_ethtool.c | 1 -
3 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c
index 933fcfb..a124615 100644
--- a/drivers/net/ucc_geth.c
+++ b/drivers/net/ucc_geth.c
@@ -24,7 +24,6 @@
#include <linux/spinlock.h>
#include <linux/mm.h>
#include <linux/dma-mapping.h>
-#include <linux/fsl_devices.h>
#include <linux/mii.h>
#include <linux/phy.h>
#include <linux/workqueue.h>
diff --git a/drivers/net/ucc_geth.h b/drivers/net/ucc_geth.h
index e3a25e6..48fde5a 100644
--- a/drivers/net/ucc_geth.h
+++ b/drivers/net/ucc_geth.h
@@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/list.h>
-#include <linux/fsl_devices.h>
#include <asm/immap_qe.h>
#include <asm/qe.h>
diff --git a/drivers/net/ucc_geth_ethtool.c b/drivers/net/ucc_geth_ethtool.c
index a755bea..6fcb500 100644
--- a/drivers/net/ucc_geth_ethtool.c
+++ b/drivers/net/ucc_geth_ethtool.c
@@ -28,7 +28,6 @@
#include <linux/mm.h>
#include <linux/delay.h>
#include <linux/dma-mapping.h>
-#include <linux/fsl_devices.h>
#include <linux/ethtool.h>
#include <linux/mii.h>
#include <linux/phy.h>
--
1.5.6.6
^ permalink raw reply related
* Re: [PATCH 1/2] powerpc: i2c-mpc: preserve I2C clocking
From: Wolfgang Grandegger @ 2009-03-31 13:47 UTC (permalink / raw)
To: Wolfram Sang; +Cc: linuxppc-dev, devicetree-discuss, linux-i2c
In-Reply-To: <20090331133953.GB3044@pengutronix.de>
Wolfram Sang wrote:
> On Tue, Mar 31, 2009 at 02:50:29PM +0200, Wolfgang Grandegger wrote:
>> The I2c node property "fsl,preserve-clocking" allows to overtake the
>> clock settings from the boot loader and avoids the hard-coded setting.
>>
>> Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
>> ---
>> drivers/i2c/busses/i2c-mpc.c | 24 ++++++++++++++++--------
>> 1 file changed, 16 insertions(+), 8 deletions(-)
>>
>> Index: linux-2.6/drivers/i2c/busses/i2c-mpc.c
>> ===================================================================
>> --- linux-2.6.orig/drivers/i2c/busses/i2c-mpc.c 2009-03-31 13:25:08.000000000 +0200
>> +++ linux-2.6/drivers/i2c/busses/i2c-mpc.c 2009-03-31 13:28:03.000000000 +0200
>> @@ -318,17 +318,24 @@
>> {
>> int result = 0;
>> struct mpc_i2c *i2c;
>> + int set_clock;
>>
>> i2c = kzalloc(sizeof(*i2c), GFP_KERNEL);
>> if (!i2c)
>> return -ENOMEM;
>>
>> - if (of_get_property(op->node, "dfsrr", NULL))
>> - i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
>> -
>> - if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
>> - of_device_is_compatible(op->node, "mpc5200-i2c"))
>> - i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
>> + if (of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
>> + set_clock = 0;
>> + } else {
>> + set_clock = 1;
>> +
>> + if (of_get_property(op->node, "dfsrr", NULL))
>> + i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
>> +
>> + if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
>> + of_device_is_compatible(op->node, "mpc5200-i2c"))
>> + i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
>> + }
>>
>> init_waitqueue_head(&i2c->queue);
>>
>> @@ -348,8 +355,9 @@
>> goto fail_request;
>> }
>> }
>> -
>> - mpc_i2c_setclock(i2c);
>> +
>> + if (set_clock)
>> + mpc_i2c_setclock(i2c);
>
> Can't we drop 'set_clock' with something like this here?
>
> + if (!of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
> +
> + if (of_get_property(op->node, "dfsrr", NULL))
> + i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
> +
> + if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
> + of_device_is_compatible(op->node, "mpc5200-i2c"))
> + i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
> +
> + mpc_i2c_setclock(i2c);
> + }
No, because the I2C registers are not yet mapped.
Wolfgang.
^ permalink raw reply
* [PATCH] powerpc/85xx: Use fsl, mpc85.. as prefix for memory ctrl & l2-cache nodes
From: Kumar Gala @ 2009-03-31 13:48 UTC (permalink / raw)
To: linuxppc-dev
Older devices tree's used "fsl,85.." instead of the preferred
"fsl,mpc85.." for the memory controller & l2 cache controller nodes.
The EDAC code is the only use of these and has been updated for some
time to support both "fsl,85.." and "fsl,mpc85.."
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
arch/powerpc/boot/dts/ksi8560.dts | 4 ++--
arch/powerpc/boot/dts/sbc8548.dts | 4 ++--
arch/powerpc/boot/dts/sbc8560.dts | 4 ++--
arch/powerpc/boot/dts/stx_gp3_8560.dts | 4 ++--
arch/powerpc/boot/dts/tqm8540.dts | 4 ++--
arch/powerpc/boot/dts/tqm8541.dts | 4 ++--
arch/powerpc/boot/dts/tqm8555.dts | 4 ++--
arch/powerpc/boot/dts/tqm8560.dts | 4 ++--
8 files changed, 16 insertions(+), 16 deletions(-)
diff --git a/arch/powerpc/boot/dts/ksi8560.dts b/arch/powerpc/boot/dts/ksi8560.dts
index 308fe7c..c9cfd37 100644
--- a/arch/powerpc/boot/dts/ksi8560.dts
+++ b/arch/powerpc/boot/dts/ksi8560.dts
@@ -57,14 +57,14 @@
bus-frequency = <0>; /* Fixed by bootwrapper */
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <0x12 0x2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <0x20>; /* 32 bytes */
cache-size = <0x40000>; /* L2, 256K */
diff --git a/arch/powerpc/boot/dts/sbc8548.dts b/arch/powerpc/boot/dts/sbc8548.dts
index 9c5079f..b1f1416 100644
--- a/arch/powerpc/boot/dts/sbc8548.dts
+++ b/arch/powerpc/boot/dts/sbc8548.dts
@@ -156,14 +156,14 @@
compatible = "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8548-memory-controller";
+ compatible = "fsl,mpc8548-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <0x12 0x2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8548-l2-cache-controller";
+ compatible = "fsl,mpc8548-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <0x20>; // 32 bytes
cache-size = <0x80000>; // L2, 512K
diff --git a/arch/powerpc/boot/dts/sbc8560.dts b/arch/powerpc/boot/dts/sbc8560.dts
index b772405..c4564b8 100644
--- a/arch/powerpc/boot/dts/sbc8560.dts
+++ b/arch/powerpc/boot/dts/sbc8560.dts
@@ -61,14 +61,14 @@
clock-frequency = <0>;
memory-controller@2000 {
- compatible = "fsl,8560-memory-controller";
+ compatible = "fsl,mpc8560-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <0x12 0x2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8560-l2-cache-controller";
+ compatible = "fsl,mpc8560-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <0x20>; // 32 bytes
cache-size = <0x40000>; // L2, 256K
diff --git a/arch/powerpc/boot/dts/stx_gp3_8560.dts b/arch/powerpc/boot/dts/stx_gp3_8560.dts
index 8b17395..ea6b151 100644
--- a/arch/powerpc/boot/dts/stx_gp3_8560.dts
+++ b/arch/powerpc/boot/dts/stx_gp3_8560.dts
@@ -57,14 +57,14 @@
compatible = "fsl,mpc8560-immr", "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <18 2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <32>;
cache-size = <0x40000>; // L2, 256K
diff --git a/arch/powerpc/boot/dts/tqm8540.dts b/arch/powerpc/boot/dts/tqm8540.dts
index ac9413a..231bae7 100644
--- a/arch/powerpc/boot/dts/tqm8540.dts
+++ b/arch/powerpc/boot/dts/tqm8540.dts
@@ -59,14 +59,14 @@
compatible = "fsl,mpc8540-immr", "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <18 2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <32>;
cache-size = <0x40000>; // L2, 256K
diff --git a/arch/powerpc/boot/dts/tqm8541.dts b/arch/powerpc/boot/dts/tqm8541.dts
index c71bb5d..4356a1f 100644
--- a/arch/powerpc/boot/dts/tqm8541.dts
+++ b/arch/powerpc/boot/dts/tqm8541.dts
@@ -58,14 +58,14 @@
compatible = "fsl,mpc8541-immr", "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <18 2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <32>;
cache-size = <0x40000>; // L2, 256K
diff --git a/arch/powerpc/boot/dts/tqm8555.dts b/arch/powerpc/boot/dts/tqm8555.dts
index a133ded..06d366e 100644
--- a/arch/powerpc/boot/dts/tqm8555.dts
+++ b/arch/powerpc/boot/dts/tqm8555.dts
@@ -58,14 +58,14 @@
compatible = "fsl,mpc8555-immr", "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <18 2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <32>;
cache-size = <0x40000>; // L2, 256K
diff --git a/arch/powerpc/boot/dts/tqm8560.dts b/arch/powerpc/boot/dts/tqm8560.dts
index 649e2e5..feff915 100644
--- a/arch/powerpc/boot/dts/tqm8560.dts
+++ b/arch/powerpc/boot/dts/tqm8560.dts
@@ -60,14 +60,14 @@
compatible = "fsl,mpc8560-immr", "simple-bus";
memory-controller@2000 {
- compatible = "fsl,8540-memory-controller";
+ compatible = "fsl,mpc8540-memory-controller";
reg = <0x2000 0x1000>;
interrupt-parent = <&mpic>;
interrupts = <18 2>;
};
L2: l2-cache-controller@20000 {
- compatible = "fsl,8540-l2-cache-controller";
+ compatible = "fsl,mpc8540-l2-cache-controller";
reg = <0x20000 0x1000>;
cache-line-size = <32>;
cache-size = <0x40000>; // L2, 256K
--
1.5.6.6
^ permalink raw reply related
* Re: [PATCH 1/2] powerpc: i2c-mpc: preserve I2C clocking
From: Wolfram Sang @ 2009-03-31 13:56 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev, devicetree-discuss, linux-i2c
In-Reply-To: <49D21EF1.9050200@grandegger.com>
[-- Attachment #1: Type: text/plain, Size: 956 bytes --]
> >> -
> >> - mpc_i2c_setclock(i2c);
> >> +
> >> + if (set_clock)
> >> + mpc_i2c_setclock(i2c);
> >
> > Can't we drop 'set_clock' with something like this here?
> >
> > + if (!of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
> > +
> > + if (of_get_property(op->node, "dfsrr", NULL))
> > + i2c->flags |= FSL_I2C_DEV_SEPARATE_DFSRR;
> > +
> > + if (of_device_is_compatible(op->node, "fsl,mpc5200-i2c") ||
> > + of_device_is_compatible(op->node, "mpc5200-i2c"))
> > + i2c->flags |= FSL_I2C_DEV_CLOCK_5200;
> > +
> > + mpc_i2c_setclock(i2c);
> > + }
>
> No, because the I2C registers are not yet mapped.
Sorry, I used misleading words :) With 'here' I meant 'at this
position', i.e. insert my above block where mpc_i2c_setclock was used
anyway.
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]
^ permalink raw reply
* [PATCH v3] powerpc: Add support for CoreInt delivery of interrupts on MPIC
From: Kumar Gala @ 2009-03-31 14:09 UTC (permalink / raw)
Cc: linuxppc-dev
CoreInt provides a mechansim to deliver the IRQ vector directly
into the core on an interrupt (via the SPR EPR) rather than having
to go IACK on the PIC. This is suppose to provide an improvment
in interrupt latency by reducing the time to get the IRQ vector.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
Ben, this version is pretty much identical to v2 with the following changes.
Please look to pull it into your tree for .30
* Add comment about mode field on FSL mpics
* Fixed build issue on non-booke parts since SPRN_EPR doesn't exist there
arch/powerpc/include/asm/mpic.h | 12 ++++++++++++
arch/powerpc/sysdev/mpic.c | 34 ++++++++++++++++++++++++++++++++++
2 files changed, 46 insertions(+), 0 deletions(-)
diff --git a/arch/powerpc/include/asm/mpic.h b/arch/powerpc/include/asm/mpic.h
index c2ccca5..a002682 100644
--- a/arch/powerpc/include/asm/mpic.h
+++ b/arch/powerpc/include/asm/mpic.h
@@ -22,6 +22,14 @@
#define MPIC_GREG_FEATURE_1 0x00010
#define MPIC_GREG_GLOBAL_CONF_0 0x00020
#define MPIC_GREG_GCONF_RESET 0x80000000
+/* On the FSL mpic implementations the Mode field is expand to be
+ * 2 bits wide:
+ * 0b00 = pass through (interrupts routed to IRQ0)
+ * 0b01 = Mixed mode
+ * 0b10 = reserved
+ * 0b11 = External proxy / coreint
+ */
+#define MPIC_GREG_GCONF_COREINT 0x60000000
#define MPIC_GREG_GCONF_8259_PTHROU_DIS 0x20000000
#define MPIC_GREG_GCONF_NO_BIAS 0x10000000
#define MPIC_GREG_GCONF_BASE_MASK 0x000fffff
@@ -357,6 +365,8 @@ struct mpic
#define MPIC_BROKEN_FRR_NIRQS 0x00000800
/* Destination only supports a single CPU at a time */
#define MPIC_SINGLE_DEST_CPU 0x00001000
+/* Enable CoreInt delivery of interrupts */
+#define MPIC_ENABLE_COREINT 0x00002000
/* MPIC HW modification ID */
#define MPIC_REGSET_MASK 0xf0000000
@@ -470,6 +480,8 @@ extern void mpic_end_irq(unsigned int irq);
extern unsigned int mpic_get_one_irq(struct mpic *mpic);
/* This one gets from the primary mpic */
extern unsigned int mpic_get_irq(void);
+/* This one gets from the primary mpic via CoreInt*/
+extern unsigned int mpic_get_coreint_irq(void);
/* Fetch Machine Check interrupt from primary mpic */
extern unsigned int mpic_get_mcirq(void);
diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c
index 532e205..21b9567 100644
--- a/arch/powerpc/sysdev/mpic.c
+++ b/arch/powerpc/sysdev/mpic.c
@@ -1170,6 +1170,12 @@ struct mpic * __init mpic_alloc(struct device_node *node,
mb();
}
+ /* CoreInt */
+ if (flags & MPIC_ENABLE_COREINT)
+ mpic_write(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0),
+ mpic_read(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0))
+ | MPIC_GREG_GCONF_COREINT);
+
if (flags & MPIC_ENABLE_MCK)
mpic_write(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0),
mpic_read(mpic->gregs, MPIC_INFO(GREG_GLOBAL_CONF_0))
@@ -1525,6 +1531,34 @@ unsigned int mpic_get_irq(void)
return mpic_get_one_irq(mpic);
}
+unsigned int mpic_get_coreint_irq(void)
+{
+#ifdef CONFIG_BOOKE
+ struct mpic *mpic = mpic_primary;
+ u32 src;
+
+ BUG_ON(mpic == NULL);
+
+ src = mfspr(SPRN_EPR);
+
+ if (unlikely(src == mpic->spurious_vec)) {
+ if (mpic->flags & MPIC_SPV_EOI)
+ mpic_eoi(mpic);
+ return NO_IRQ;
+ }
+ if (unlikely(mpic->protected && test_bit(src, mpic->protected))) {
+ if (printk_ratelimit())
+ printk(KERN_WARNING "%s: Got protected source %d !\n",
+ mpic->name, (int)src);
+ return NO_IRQ;
+ }
+
+ return irq_linear_revmap(mpic->irqhost, src);
+#else
+ return NO_IRQ;
+#endif
+}
+
unsigned int mpic_get_mcirq(void)
{
struct mpic *mpic = mpic_primary;
--
1.5.6.6
^ permalink raw reply related
* Re: [PATCH] ucc_geth: Rework the TX logic.
From: Scott Wood @ 2009-03-31 14:37 UTC (permalink / raw)
To: Joakim Tjernlund; +Cc: linuxppc-dev, Li Yang, pku.leo, netdev
In-Reply-To: <OFEAA9D1E3.4B2F3270-ONC125758A.00307236-C125758A.00322239@transmode.se>
Joakim Tjernlund wrote:
> I am a bit confused, what isn't worth it?
Enabling cacheing on MURAM, at least when used for buffer descriptors.
The cache line ping-pong would probably outweigh the cost of the
uncached accesses.
> Currently MURAM isn't used by ucc_geth,
Hmm. I looked in the driver and saw numerous muram allocations, but I
didn't try to follow the driver enough to ensure that they were for the
ring. I'd assumed it was similar to the CPM1/CPM2 driver.
> 3) as gianfar, dma_alloc_coherent(). I presume this is uncacheable memory?
It would be uncacheable on systems without coherent DMA, but I don't
think there are any such systems that use gianfar.
> My guess would be 2 or 3. Do they have the same synchronization
> sematics?
No, unfortunately. PowerPC sync instructions are a bit complicated.
For example, you can use eieio to sync between reading the interrupt
status register and checking the ring buffer, if they're both mapped
I+G, but not if the former is I+G and the latter is cacheable (you need
a full sync in that case).
-Scott
^ permalink raw reply
* Re: Patch: Fix fec_mpc52xx driver to use net_device_ops
From: Stephen Hemminger @ 2009-03-31 14:48 UTC (permalink / raw)
To: Henk Stegeman; +Cc: linuxppc-dev, netdev
In-Reply-To: <ae4f76fd0903310344s2d46edf2l505a1d21a4778d54@mail.gmail.com>
On Tue, 31 Mar 2009 12:44:15 +0200
Henk Stegeman <henk.stegeman@gmail.com> wrote:
> Fix fec_mpc52xx driver to use net_device_ops and to be careful not to
> dereference phy_device if a phy has not yet been connected.
>
> Signed-off-by: Henk Stegeman <henk.stegeman@gmail.com>
>
> diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c
> index cd8e98b..ca76b95 100644
> --- a/drivers/net/fec_mpc52xx.c
> +++ b/drivers/net/fec_mpc52xx.c
> @@ -847,24 +847,40 @@ static void mpc52xx_fec_get_drvinfo(struct
> net_device *dev,
> static int mpc52xx_fec_get_settings(struct net_device *dev, struct
> ethtool_cmd *cmd)
> {
> struct mpc52xx_fec_priv *priv = netdev_priv(dev);
> +
> + if (!priv->phydev)
> + return -ENODEV;
> +
> return phy_ethtool_gset(priv->phydev, cmd);
> }
>
> static int mpc52xx_fec_set_settings(struct net_device *dev, struct
> ethtool_cmd *cmd)
> {
> struct mpc52xx_fec_priv *priv = netdev_priv(dev);
> +
> + if (!priv->phydev)
> + return -ENODEV;
> +
> return phy_ethtool_sset(priv->phydev, cmd);
> }
>
> static u32 mpc52xx_fec_get_msglevel(struct net_device *dev)
> {
> struct mpc52xx_fec_priv *priv = netdev_priv(dev);
> +
> + if (!priv->phydev)
> + return 0;
> +
> return priv->msg_enable;
> }
>
> static void mpc52xx_fec_set_msglevel(struct net_device *dev, u32 level)
> {
> struct mpc52xx_fec_priv *priv = netdev_priv(dev);
> +
> + if (!priv->phydev)
> + return;
> +
> priv->msg_enable = level;
> }
>
> @@ -882,12 +898,31 @@ static int mpc52xx_fec_ioctl(struct net_device
> *dev, struct ifreq *rq, int cmd)
> {
> struct mpc52xx_fec_priv *priv = netdev_priv(dev);
>
> + if (!priv->phydev)
> + return -ENODEV;
> +
> return mpc52xx_fec_phy_mii_ioctl(priv, if_mii(rq), cmd);
> }
>
> /* ======================================================================== */
> /* OF Driver */
> /* ======================================================================== */
> +static const struct net_device_ops mpc52xx_fec_netdev_ops = {
> + .ndo_open = mpc52xx_fec_open,
> + .ndo_stop = mpc52xx_fec_close,
> + .ndo_start_xmit = mpc52xx_fec_hard_start_xmit,
> + .ndo_tx_timeout = mpc52xx_fec_tx_timeout,
> + .ndo_get_stats = mpc52xx_fec_get_stats,
> + .ndo_set_multicast_list = mpc52xx_fec_set_multicast_list,
> + .ndo_validate_addr = eth_validate_addr,
> + .ndo_set_mac_address = mpc52xx_fec_set_mac_address,
> + .ndo_do_ioctl = mpc52xx_fec_ioctl,
>
What about change_mtu? Don't you want:
.ndo_change_mtu = eth_change_mtu,
^ permalink raw reply
* Re: powerpc/85xx: Add support for the "socrates" board (MPC8544)
From: Grant Likely @ 2009-03-31 15:05 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev
In-Reply-To: <49D21C75.7060307@grandegger.com>
On Tue, Mar 31, 2009 at 7:36 AM, Wolfgang Grandegger <wg@grandegger.com> wr=
ote:
> Grant Likely wrote:
>> On Tue, Mar 31, 2009 at 3:35 AM, Wolfgang Grandegger <wg@grandegger.com>=
wrote:
>>> Grant Likely wrote:
>>>> I agree 100% with David's comments, and I have some additional ones be=
low.
>>>>
>>>> On Thu, Mar 19, 2009 at 9:26 AM, Wolfgang Grandegger <wg@grandegger.co=
m> wrote:
>>>>> + =A0 =A0 =A0 soc8544@e0000000 {
>>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #address-cells =3D <1>;
>>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #size-cells =3D <1>;
>>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 device_type =3D "soc";
>>>> Drop device_type here too.
>>> Grrr, I just realized that removing the devices type "soc" has broken
>>> fsl_get_sys_freq(). See:
>>>
>>> http://lxr.linux.no/linux+v2.6.29/arch/powerpc/sysdev/fsl_soc.c#L80
>>>
>>> We need a quick fix and we could take the occasion to establish a commo=
n
>>> function for the MPC52xx as well, but it's not obvious to me how to fin=
d
>>> the SOC node without the device type property.
>>
>> SoC node should have a compatible property, just like everything else.
>>
>> compatible =3D "fsl,mpc8544-immr"; =A0(immr =3D=3D Internally Memory Map=
ped Registers)
>>
>> Many other boards already do this.
>
> Yes, it does, but searching for the SOC node is not straight-forward
> because there is no common compatibility string but many CPU-specific
> compatibility strings, e.g. "fsl,mpc8560-immr", etc. Have I missed
> something?
Choose a new value ("fsl,mpc-immr" perhaps?), document exactly what it
means, and add add it to the end of the compatible list.
> Unfortunately, other 85xx functions search for the device type "soc" as
> well. Therefore I think we must keep the devices type "soc" for the time
> being. Kumar?
Fix them! :-)
Most troublesome places are where of_find_node_by_type() is used (I
see two cases in fsl_soc.c). I added the of_find_matching_node()
function specifically to rework code that was only matching on a
single compatible or type value. See usage of mpc52xx_bus_ids in
arch/powerpc/platforms/52xx/mpc52xx_common.c for an example.
It is a pain, but I think it is important to be reducing device_type
usage as we hit against them.
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: 8641D with linux 2.6.29 did'n show second cpu
From: Eduard Fuchs @ 2009-03-31 15:06 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <446E5D82-7F37-42B5-8AD9-F8F368A5520A@kernel.crashing.org>
Hi,
Am Dienstag 31 M=E4rz 2009 15:20:21 schrieb Kumar Gala:
> On Mar 31, 2009, at 5:15 AM, Eduard Fuchs wrote:
> > Hi,
> >
> > I'm testing the evaluation board from freescale (MPC8641DHPCN) with
> > the latest
> > linux kernel (2.6.29) and the second core seems disabled. CONFIG_SPM
> > is
> > enabled but the /proc/cpuinfo shows only one cpu. With original
> > 2.6.27 kernel
> > both cpu cores appears in /proc/cpuinfo.
> >
> > Has anyone an idea how can i enable the second core?
>
> Are you using u-boot? I can't remember if you need a newer u-boot to
> deal with changes in how we bring up the second core.
Yes. My u-boot version is 2009.03. Are there some additional config keys fo=
r=20
SMP support in u-boot?
Best regard
Eduard
^ permalink raw reply
* Re: [PATCH 5/8] powerpc: i2c-mpc: make I2C bus speed configurable
From: Grant Likely @ 2009-03-31 15:41 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev, devicetree-discuss
In-Reply-To: <20090331124035.908249543@denx.de>
On Tue, Mar 31, 2009 at 6:37 AM, Wolfgang Grandegger <wg@grandegger.com> wr=
ote:
> This patch makes the I2C bus speed configurable by using the I2C node
> property "clock-frequency". If the property is not defined, the old
> fixed clock settings will be used for backward comptibility.
>
> The generic I2C clock properties, especially the CPU-specific source
> clock pre-scaler are defined via the OF match table:
>
> =A0static const struct of_device_id mpc_i2c_of_match[] =3D {
> =A0 =A0 =A0 =A0{.compatible =3D "fsl,mpc5200b-i2c",
> =A0 =A0 =A0 =A0 .data =3D (void *)FSL_I2C_DEV_CLOCK_5200, },
> =A0 =A0 =A0 =A0{.compatible =3D "fsl,mpc5200-i2c",
> =A0 =A0 =A0 =A0 .data =3D (void *)FSL_I2C_DEV_CLOCK_5200, },
> =A0 =A0 =A0 =A0{.compatible =3D "fsl,mpc8313-i2c",
> =A0 =A0 =A0 =A0 .data =3D (void *)FSL_I2C_DEV_SEPARATE_DFSRR, },
> =A0 =A0 =A0 =A0{.compatible =3D "fsl,mpc8543-i2c",
> =A0 =A0 =A0 =A0 .data =3D (void *)(FSL_I2C_DEV_SEPARATE_DFSRR |
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0FSL_I2C_DEV_CLOCK_DIV2=
), },
> =A0 =A0 =A0 =A0{.compatible =3D "fsl,mpc8544-i2c",
> =A0 =A0 =A0 =A0 .data =3D (void *)(FSL_I2C_DEV_SEPARATE_DFSRR |
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0FSL_I2C_DEV_CLOCK_DIV2=
3), },
> =A0 =A0 =A0 =A0/* Backward compatibility */
> =A0 =A0 =A0 =A0{.compatible =3D "fsl-i2c", },
> =A0 =A0 =A0 =A0{},
> =A0};
Instead passing in a flag (and using an ugly cast to do it) which is
then checked inside the mpc_i2c_setclock(), you should do this
instead:
struct fsl_i2c_match_data {
int static void *(setclock)(struct device_node *node, struct
mpc_i2c *i2c, u32 clock);
int flags;
/* Other stuff can go here */
};
static const struct of_device_id mpc_i2c_of_match[] =3D {
{.compatible =3D "fsl,mpc5200b-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock_mpc5200, },
},
{.compatible =3D "fsl,mpc5200-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock_mpc5200, },
},
{.compatible =3D "fsl,mpc8313-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock_separate_dfsrr, },
},
{.compatible =3D "fsl,mpc8543-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock_separate_dfsrr, },
.flags =3D FSL_I2C_DEV_CLOCK_DIV2,
},
{.compatible =3D "fsl,mpc8544-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock_separate_dfsrr, },
.flags =3D FSL_I2C_DEV_CLOCK_DIV23,
},
/* Backward compatibility */
{.compatible =3D "fsl-i2c",
.data =3D (struct fsl_i2c_match_data[]) { .setclock =3D
mpc_i2c_setclock, },
},
{},
};
The table definition is more verbose this way, but I think it results
in more understandable and easier to extend code. It also adds lets
the compiler do more type checking for you.
Also, this ...
> --- linux-2.6.orig/arch/powerpc/sysdev/fsl_soc.c =A0 =A0 =A0 =A02009-03-3=
1 13:25:08.000000000 +0200
> +++ linux-2.6/arch/powerpc/sysdev/fsl_soc.c =A0 =A0 2009-03-31 13:34:40.5=
31721011 +0200
> +int fsl_i2c_get_fdr(struct device_node *node, u32 i2c_clock, u32 i2c_fla=
gs)
> +{
> [...]
> +}
> +EXPORT_SYMBOL(fsl_i2c_get_fdr);
... and this ...
> --- linux-2.6.orig/arch/powerpc/platforms/52xx/mpc52xx_common.c 2009-03-3=
1 13:25:08.000000000 +0200
> +++ linux-2.6/arch/powerpc/platforms/52xx/mpc52xx_common.c =A0 =A0 =A0200=
9-03-31 13:28:54.309718526 +0200
> +int fsl_i2c_get_fdr(struct device_node *node, u32 i2c_clock, u32 i2c_fla=
gs)
> +{
> [...]
> +}
> +EXPORT_SYMBOL(fsl_i2c_get_fdr);
does not work on a multiplatform kernel. Both 8xxx and 52xx support
can be selected at the same time.
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: [PATCH 1/2] powerpc: i2c-mpc: preserve I2C clocking
From: Grant Likely @ 2009-03-31 15:44 UTC (permalink / raw)
To: Wolfram Sang; +Cc: linuxppc-dev, devicetree-discuss, linux-i2c
In-Reply-To: <20090331135629.GC3044@pengutronix.de>
2009/3/31 Wolfram Sang <w.sang@pengutronix.de>:
>
>> >> -
>> >> - =A0mpc_i2c_setclock(i2c);
>> >> +
>> >> + =A0if (set_clock)
>> >> + =A0 =A0 =A0 =A0 =A0mpc_i2c_setclock(i2c);
>> >
>> > Can't we drop 'set_clock' with something like this here?
>> >
>> > + =A0 if (!of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
>> > +
>> > + =A0 =A0 =A0 =A0 =A0 if (of_get_property(op->node, "dfsrr", NULL))
>> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 i2c->flags |=3D FSL_I2C_DEV_SEPA=
RATE_DFSRR;
>> > +
>> > + =A0 =A0 =A0 =A0 =A0 if (of_device_is_compatible(op->node, "fsl,mpc52=
00-i2c") ||
>> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 of_device_is_compatible(op->node, "mpc52=
00-i2c"))
>> > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 i2c->flags |=3D FSL_I2C_DEV_CLOC=
K_5200;
>> > +
>> > + =A0 =A0 =A0 =A0 =A0 mpc_i2c_setclock(i2c);
>> > + =A0 }
>>
>> No, because the I2C registers are not yet mapped.
>
> Sorry, I used misleading words :) With 'here' I meant 'at this
> position', i.e. insert my above block where mpc_i2c_setclock was used
> anyway.
I agree. The extra flag makes the flow more complex. The code block
should be moved down.
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: powerpc/85xx: Add support for the "socrates" board (MPC8544)
From: Anton Vorontsov @ 2009-03-31 15:54 UTC (permalink / raw)
To: Grant Likely; +Cc: Scott Wood, linuxppc-dev
In-Reply-To: <fa686aa40903310805k794b9df0s4d21a8080907a767@mail.gmail.com>
On Tue, Mar 31, 2009 at 09:05:28AM -0600, Grant Likely wrote:
[...]
> >>>>> + soc8544@e0000000 {
> >>>>> + #address-cells = <1>;
> >>>>> + #size-cells = <1>;
> >>>>> + device_type = "soc";
> >>>> Drop device_type here too.
> >>> Grrr, I just realized that removing the devices type "soc" has broken
> >>> fsl_get_sys_freq(). See:
> >>>
> >>> http://lxr.linux.no/linux+v2.6.29/arch/powerpc/sysdev/fsl_soc.c#L80
> >>>
> >>> We need a quick fix and we could take the occasion to establish a common
> >>> function for the MPC52xx as well, but it's not obvious to me how to find
> >>> the SOC node without the device type property.
> >>
> >> SoC node should have a compatible property, just like everything else.
> >>
> >> compatible = "fsl,mpc8544-immr"; (immr == Internally Memory Mapped Registers)
> >>
> >> Many other boards already do this.
> >
> > Yes, it does, but searching for the SOC node is not straight-forward
> > because there is no common compatibility string but many CPU-specific
> > compatibility strings, e.g. "fsl,mpc8560-immr", etc. Have I missed
> > something?
>
> Choose a new value ("fsl,mpc-immr" perhaps?), document exactly what it
> means, and add add it to the end of the compatible list.
As Scott Wood once pointed out, IMMR does not exists for MPC85xx
parts. There it's called CCSR.
See this thread:
http://www.mail-archive.com/linuxppc-dev@ozlabs.org/msg12665.html
I still think that
"fsl,mpc83NN-immr", "fsl,soc", "simple-bus" for 83xx
and
"fsl,mpc85NN-ccsr", "fsl,soc", "simple-bus" for 85xx
would be OK, at least to start with. We can always deprecate "fsl,soc"
compatible in favour of something more elegant, but "fsl,soc" should be
just fine to replace device_type = "soc".
Also, there is another good thing about "fsl,soc" -- U-Boot already
finds it for 83xx CPUs. ;-)
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: [PATCH 3/8] powerpc/85xx: Add support for the "socrates" board (MPC8544).
From: Grant Likely @ 2009-03-31 15:57 UTC (permalink / raw)
To: Wolfgang Grandegger
Cc: Sergei Poselenov, devicetree-discuss, Ilya Yanok, Dmitry Rakhchev,
linuxppc-dev, Anatolij Gustschin
In-Reply-To: <20090331124035.594457231@denx.de>
On Tue, Mar 31, 2009 at 6:37 AM, Wolfgang Grandegger <wg@grandegger.com> wr=
ote:
> Supported are Ethernet, serial console, I2C, I2C-based RTC and
> temperature sensors, NOR and NAND flash, PCI, USB, CAN and Lime
> display controller.
>
> The multiplexing of FPGA interrupts onto PowerPC interrupt lines is
> supported through our own fpga_pic interrupt controller driver.
>
> For example the SJA1000 controller is level low sensitive connected to
> fpga_pic line 2 and is routed to the second (of three) irq lines to
> the CPU:
>
> =A0 =A0can@3,100 {
> =A0 =A0 =A0 =A0 =A0 =A0compatible =3D "philips,sja1000";
> =A0 =A0 =A0 =A0 =A0 =A0reg =3D <3 0x100 0x80>;
> =A0 =A0 =A0 =A0 =A0 =A0interrupts =3D <2 2>;
> =A0 =A0 =A0 =A0 =A0 =A0interrupts =3D <2 8 1>; =A0 // number, type, routi=
ng
> =A0 =A0 =A0 =A0 =A0 =A0interrupt-parent =3D <&fpga_pic>;
> =A0 =A0};
>
> Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
> Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
> Signed-off-by: Ilya Yanok <yanok@emcraft.com>
> Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
> Signed-off-by: Anatolij Gustschin <agust@denx.de>
> Signed-off-by: Dmitry Rakhchev <rda@emcraft.com>
> ---
> =A0arch/powerpc/boot/dts/socrates.dts =A0 =A0 =A0 =A0 =A0 =A0 =A0| =A0338=
+++++
> =A0arch/powerpc/configs/85xx/socrates_defconfig =A0 =A0| 1410 +++++++++++=
+++++++++++++
I always ask this question: Do you really need a board specific
defconfig file? We are multiplatform now.
> =A0arch/powerpc/platforms/85xx/Kconfig =A0 =A0 =A0 =A0 =A0 =A0 | =A0 =A06
> =A0arch/powerpc/platforms/85xx/Makefile =A0 =A0 =A0 =A0 =A0 =A0| =A0 =A01
> =A0arch/powerpc/platforms/85xx/socrates.c =A0 =A0 =A0 =A0 =A0| =A0133 ++
> =A0arch/powerpc/platforms/85xx/socrates_fpga_pic.c | =A0327 +++++
> =A0arch/powerpc/platforms/85xx/socrates_fpga_pic.h | =A0 16
socrates_fpga_pic is only ever going to be used by socrates.c. I'd
roll the two socrates.c files into one and eliminate the header file.
> Index: linux-2.6/arch/powerpc/platforms/85xx/socrates_fpga_pic.c
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> --- /dev/null
> +++ linux-2.6/arch/powerpc/platforms/85xx/socrates_fpga_pic.c
[...]
> +struct socrates_fpga_irq_info {
> + =A0 =A0 =A0 unsigned int irq_line;
> + =A0 =A0 =A0 int type;
> +};
> +
> +/*
> + * Interrupt routing and type table
> + *
> + * IRQ_TYPE_NONE means the interrupt type is configurable,
> + * otherwise it's fixed to the specified value.
> + */
> +static struct socrates_fpga_irq_info fpga_irqs[SOCRATES_FPGA_NUM_IRQS] =
=3D {
> + =A0 =A0 =A0 [0] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [1] =3D {0, IRQ_TYPE_LEVEL_HIGH},
> + =A0 =A0 =A0 [2] =3D {0, IRQ_TYPE_LEVEL_LOW},
> + =A0 =A0 =A0 [3] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [4] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [5] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [6] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [7] =3D {0, IRQ_TYPE_NONE},
> + =A0 =A0 =A0 [8] =3D {0, IRQ_TYPE_LEVEL_HIGH},
> +};
It is good practice to use named elements in initializers: {.type =3D
IRQ_TYPE_LEVEL_HIGH},
Static variables are initialized to zero. Everything that is 0 can be
dropped from this initializer (lines 0 and 3-7, and the irq_line
field).
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: powerpc/85xx: Add support for the "socrates" board (MPC8544)
From: Grant Likely @ 2009-03-31 16:02 UTC (permalink / raw)
To: avorontsov; +Cc: Scott Wood, linuxppc-dev
In-Reply-To: <20090331155443.GA28242@oksana.dev.rtsoft.ru>
On Tue, Mar 31, 2009 at 9:54 AM, Anton Vorontsov
<avorontsov@ru.mvista.com> wrote:
> On Tue, Mar 31, 2009 at 09:05:28AM -0600, Grant Likely wrote:
> [...]
>> >>>>> + =A0 =A0 =A0 soc8544@e0000000 {
>> >>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #address-cells =3D <1>;
>> >>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 #size-cells =3D <1>;
>> >>>>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 device_type =3D "soc";
>> >>>> Drop device_type here too.
>> >>> Grrr, I just realized that removing the devices type "soc" has broke=
n
>> >>> fsl_get_sys_freq(). See:
>> >>>
>> >>> http://lxr.linux.no/linux+v2.6.29/arch/powerpc/sysdev/fsl_soc.c#L80
>> >>>
>> >>> We need a quick fix and we could take the occasion to establish a co=
mmon
>> >>> function for the MPC52xx as well, but it's not obvious to me how to =
find
>> >>> the SOC node without the device type property.
>> >>
>> >> SoC node should have a compatible property, just like everything else=
.
>> >>
>> >> compatible =3D "fsl,mpc8544-immr"; =A0(immr =3D=3D Internally Memory =
Mapped Registers)
>> >>
>> >> Many other boards already do this.
>> >
>> > Yes, it does, but searching for the SOC node is not straight-forward
>> > because there is no common compatibility string but many CPU-specific
>> > compatibility strings, e.g. "fsl,mpc8560-immr", etc. Have I missed
>> > something?
>>
>> Choose a new value ("fsl,mpc-immr" perhaps?), document exactly what it
>> means, and add add it to the end of the compatible list.
>
> As Scott Wood once pointed out, IMMR does not exists for MPC85xx
> parts. There it's called CCSR.
>
> See this thread:
>
> http://www.mail-archive.com/linuxppc-dev@ozlabs.org/msg12665.html
>
> I still think that
> "fsl,mpc83NN-immr", "fsl,soc", "simple-bus" for 83xx
> and
> "fsl,mpc85NN-ccsr", "fsl,soc", "simple-bus" for 85xx
>
> would be OK, at least to start with. We can always deprecate "fsl,soc"
> compatible in favour of something more elegant, but "fsl,soc" should be
> just fine to replace device_type =3D "soc".
>
> Also, there is another good thing about "fsl,soc" -- U-Boot already
> finds it for 83xx CPUs. ;-)
I'm totally fine with fsl,soc *providing* that it is documented as to
exactly what it describes, what properties are expected, and how they
are used. Since fsl,soc is not tied to a specific piece of silicon I
want to guard against the definition of "fsl,soc" drifting over time.
g.
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: [PATCH] linux-next remove wmb() from ide-dma-sff.c and scc_pata.c
From: Atsushi Nemoto @ 2009-03-31 15:26 UTC (permalink / raw)
To: Geert.Uytterhoeven
Cc: linux-mips, bzolnier, linuxppc-dev, linux-ide, grundler,
linux-kernel
In-Reply-To: <alpine.LRH.2.00.0903310950040.9551@vixen.sonytel.be>
On Tue, 31 Mar 2009 09:51:53 +0200 (CEST), Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> wrote:
> > Followup to "[PATCH 03/10] ide: destroy DMA mappings after ending DMA"
> > email on March 14th:
> > http://lkml.org/lkml/2009/3/14/17
> >
> > No maintainer is listed for "Toshiba CELL Reference Set IDE" (BLK_DEV_CELLEB)
> > or tx4939ide.c in MAINTAINERS. I've CC'd "Ishizaki Kou" @Toshiba (Maintainer for
> > "Spidernet Network Driver for CELL") and linuxppc-dev list in the hope
> > someone else
> > would know or would be able to ACK this patch.
>
> tx49xx is MIPS, for Nemoto-san.
>
> > This patch:
> > o replaces "mask" variable in ide_dma_end() with #define.
> > o removes use of wmb() in ide-dma-sff.c and scc_pata.c.
> > o is not tested - I don't have (or want) the HW.
> >
> > I did NOT remove wmb() use in tx4939ide.c. tx4939ide.c __raw_writeb()
> > for MMIO transactions. __raw_writeb() does NOT guarantee memory
> > transaction ordering.
The wmb() in tx4939ide.c was just copied from ide_dma_end(). On this
MIPS core memory operations are strictly ordered so that the wmb() can
be removed.
And on MIPS __raw_writeb() and writeb() do same thing except for
endian conversion.
I will send a patch just for tx4939ide.c. Thank you for suggestion.
> > tx4939ide also uses mmiowb(). AFAIK, mmiowb() only has an effect on
> > SGI IA64 NUMA machines. I'm not going to guess how this driver might work.
On MIPS mmiowb() can be (ab)used to flush write buffer. Please do not
drop this mmiowb().
---
Atsushi Nemoto
^ permalink raw reply
* Re: [PATCH 0/8] powerpc: i2c-mpc: make I2C bus speed configurable
From: Grant Likely @ 2009-03-31 16:23 UTC (permalink / raw)
To: Wolfgang Grandegger; +Cc: linuxppc-dev, devicetree-discuss
In-Reply-To: <49D21145.3060400@grandegger.com>
On Tue, Mar 31, 2009 at 6:49 AM, Wolfgang Grandegger <wg@grandegger.com> wrote:
> Please *FORGET* this series of patches. Only the I2C related patches are
> relevant but I accidentally sent out the complete patch stack :-(. I
> will resent them in a second.
>
> Sorry for any inconvenience this has caused.
Heh, no worries. At least this way you get a bonus round of review. :-)
g.
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* kexec: proc/device-tree/chosen/linux,kernel-end: No such file or directory
From: Geert Uytterhoeven @ 2009-03-31 16:25 UTC (permalink / raw)
To: Linux/PPC Development
With today's kernel, I can no longer kexec any kernel on PS3:
| /proc/device-tree/chosen/linux,kernel-end: No such file or directory
| Could not get memory layout
Today's bad version: 15f7176eb1cccec0a332541285ee752b935c1c85
Yesterday's good version: 0d34fb8e93ceba7b6dad0062dbb4a0813bacd75b
Before I start bisecting (tomorrow or the day thereafter), anyone with an idea?
Thanks!
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Techsoft Centre Europe
The Corporate Village · Da Vincilaan 7-D1 · B-1935 Zaventem · Belgium
Phone: +32 (0)2 700 8453
Fax: +32 (0)2 700 8622
E-mail: Geert.Uytterhoeven@sonycom.com
Internet: http://www.sony-europe.com/
A division of Sony Europe (Belgium) N.V.
VAT BE 0413.825.160 · RPR Brussels
Fortis · BIC GEBABEBB · IBAN BE41293037680010
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox