linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
@ 2013-04-08  1:44 Magnus Damm
  2013-04-09 12:34 ` Simon Horman
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: Magnus Damm @ 2013-04-08  1:44 UTC (permalink / raw)
  To: linux-arm-kernel

From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>

Add 1GiB of DRAM at 0x2_0000_0000

Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
Signed-off-by: Magnus Damm <damm@opensource.se>
---

 This patch simply updates the DTS to describe the actual board
 hardware. If we want to make use of the memory we also need to
 enable LPAE in the kernel configuration, but that is seen as a
 separate step.

 arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
 1 file changed, 5 insertions(+)

--- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
+++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-04-08 10:27:20.000000000 +0900
@@ -24,6 +24,11 @@
 		reg = <0 0x40000000 0 0x40000000>;
 	};
 
+	memory@200000000 {
+		device_type = "memory";
+		reg = <2 0x00000000 0 0x40000000>;
+	};
+
 	ape6evm_fixed_3v3: fixedregulator@0 {
 		compatible = "regulator-fixed";
 		regulator-name = "3V3";

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-08  1:44 [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM Magnus Damm
@ 2013-04-09 12:34 ` Simon Horman
  2013-04-09 16:14   ` Simon Horman
  2013-10-31  3:15 ` Magnus Damm
  2013-10-31  3:18 ` [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref Magnus Damm
  2 siblings, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-04-09 12:34 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
> From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> 
> Add 1GiB of DRAM at 0x2_0000_0000
> 
> Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> Signed-off-by: Magnus Damm <damm@opensource.se>

Thanks, queued up in the boards-ape6evm branch.

> ---
> 
>  This patch simply updates the DTS to describe the actual board
>  hardware. If we want to make use of the memory we also need to
>  enable LPAE in the kernel configuration, but that is seen as a
>  separate step.
> 
>  arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> --- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
> +++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-04-08 10:27:20.000000000 +0900
> @@ -24,6 +24,11 @@
>  		reg = <0 0x40000000 0 0x40000000>;
>  	};
>  
> +	memory@200000000 {
> +		device_type = "memory";
> +		reg = <2 0x00000000 0 0x40000000>;
> +	};
> +
>  	ape6evm_fixed_3v3: fixedregulator@0 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "3V3";
> 

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-09 12:34 ` Simon Horman
@ 2013-04-09 16:14   ` Simon Horman
  2013-04-09 22:27     ` Magnus Damm
  0 siblings, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-04-09 16:14 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Apr 09, 2013 at 09:34:34PM +0900, Simon Horman wrote:
> On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
> > From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> > 
> > Add 1GiB of DRAM at 0x2_0000_0000
> > 
> > Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> > Signed-off-by: Magnus Damm <damm@opensource.se>
> 
> Thanks, queued up in the boards-ape6evm branch.

I have dropped this patch as it appears to prevent
the board from booting.

> 
> > ---
> > 
> >  This patch simply updates the DTS to describe the actual board
> >  hardware. If we want to make use of the memory we also need to
> >  enable LPAE in the kernel configuration, but that is seen as a
> >  separate step.
> > 
> >  arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
> >  1 file changed, 5 insertions(+)
> > 
> > --- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
> > +++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-04-08 10:27:20.000000000 +0900
> > @@ -24,6 +24,11 @@
> >  		reg = <0 0x40000000 0 0x40000000>;
> >  	};
> >  
> > +	memory@200000000 {
> > +		device_type = "memory";
> > +		reg = <2 0x00000000 0 0x40000000>;
> > +	};
> > +
> >  	ape6evm_fixed_3v3: fixedregulator@0 {
> >  		compatible = "regulator-fixed";
> >  		regulator-name = "3V3";
> > 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-09 16:14   ` Simon Horman
@ 2013-04-09 22:27     ` Magnus Damm
  2013-04-10  0:35       ` Simon Horman
  0 siblings, 1 reply; 17+ messages in thread
From: Magnus Damm @ 2013-04-09 22:27 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Simon,

On Wed, Apr 10, 2013 at 1:14 AM, Simon Horman <horms@verge.net.au> wrote:
> On Tue, Apr 09, 2013 at 09:34:34PM +0900, Simon Horman wrote:
>> On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
>> > From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
>> >
>> > Add 1GiB of DRAM at 0x2_0000_0000
>> >
>> > Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
>> > Signed-off-by: Magnus Damm <damm@opensource.se>
>>
>> Thanks, queued up in the boards-ape6evm branch.
>
> I have dropped this patch as it appears to prevent
> the board from booting.

Is it possible that LPAE=n and HIGHMEM=y in your particular kernel
configuration?

From what I can tell HIGHMEM is broken in cases of large amounts of
memory. Try disabling that as a short-term workaround. Then of course
someone needs to track down why the generic code doesn't work as
expected.

Thanks,

/ magnus

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-09 22:27     ` Magnus Damm
@ 2013-04-10  0:35       ` Simon Horman
  2013-04-10  1:38         ` Magnus Damm
  0 siblings, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-04-10  0:35 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Apr 10, 2013 at 07:27:41AM +0900, Magnus Damm wrote:
> Hi Simon,
> 
> On Wed, Apr 10, 2013 at 1:14 AM, Simon Horman <horms@verge.net.au> wrote:
> > On Tue, Apr 09, 2013 at 09:34:34PM +0900, Simon Horman wrote:
> >> On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
> >> > From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> >> >
> >> > Add 1GiB of DRAM at 0x2_0000_0000
> >> >
> >> > Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> >> > Signed-off-by: Magnus Damm <damm@opensource.se>
> >>
> >> Thanks, queued up in the boards-ape6evm branch.
> >
> > I have dropped this patch as it appears to prevent
> > the board from booting.
> 
> Is it possible that LPAE=n and HIGHMEM=y in your particular kernel
> configuration?

Yes, I have confirmed that is what using the ape6evm_defconfig results in.

> >From what I can tell HIGHMEM is broken in cases of large amounts of
> memory. Try disabling that as a short-term workaround. Then of course
> someone needs to track down why the generic code doesn't work as
> expected.

I have confirmed that disabling HIGHMEM allows the board to boot
with this patch applied.

Should I prepare a patch to the defconfig to accompany this patch?


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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-10  0:35       ` Simon Horman
@ 2013-04-10  1:38         ` Magnus Damm
  2013-04-10  2:09           ` Simon Horman
  0 siblings, 1 reply; 17+ messages in thread
From: Magnus Damm @ 2013-04-10  1:38 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Simon, Arnd,

On Wed, Apr 10, 2013 at 9:35 AM, Simon Horman <horms@verge.net.au> wrote:
> On Wed, Apr 10, 2013 at 07:27:41AM +0900, Magnus Damm wrote:
>> Hi Simon,
>>
>> On Wed, Apr 10, 2013 at 1:14 AM, Simon Horman <horms@verge.net.au> wrote:
>> > On Tue, Apr 09, 2013 at 09:34:34PM +0900, Simon Horman wrote:
>> >> On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
>> >> > From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
>> >> >
>> >> > Add 1GiB of DRAM at 0x2_0000_0000
>> >> >
>> >> > Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
>> >> > Signed-off-by: Magnus Damm <damm@opensource.se>
>> >>
>> >> Thanks, queued up in the boards-ape6evm branch.
>> >
>> > I have dropped this patch as it appears to prevent
>> > the board from booting.
>>
>> Is it possible that LPAE=n and HIGHMEM=y in your particular kernel
>> configuration?
>
> Yes, I have confirmed that is what using the ape6evm_defconfig results in.
>
>> >From what I can tell HIGHMEM is broken in cases of large amounts of
>> memory. Try disabling that as a short-term workaround. Then of course
>> someone needs to track down why the generic code doesn't work as
>> expected.
>
> I have confirmed that disabling HIGHMEM allows the board to boot
> with this patch applied.

Thanks for checking.

So HIGHMEM without LPAE seems busted on boards using more than 32-bits
for memory.

I'd like to help out fixing this issue, but I'd like to make sure that
no one else is working on this.

Arnd, are you aware on any work related to making HIGHMEM work without LPAE?

> Should I prepare a patch to the defconfig to accompany this patch?

I believe that would affect a bunch of boards so I don't think that is
necessary at this point. Thanks anyway.

Would it be possible for you to queue up this change in a APE6EVM topic branch?

Thanks,

/ magnus

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-10  1:38         ` Magnus Damm
@ 2013-04-10  2:09           ` Simon Horman
  0 siblings, 0 replies; 17+ messages in thread
From: Simon Horman @ 2013-04-10  2:09 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Apr 10, 2013 at 10:38:49AM +0900, Magnus Damm wrote:
> Hi Simon, Arnd,
> 
> On Wed, Apr 10, 2013 at 9:35 AM, Simon Horman <horms@verge.net.au> wrote:
> > On Wed, Apr 10, 2013 at 07:27:41AM +0900, Magnus Damm wrote:
> >> Hi Simon,
> >>
> >> On Wed, Apr 10, 2013 at 1:14 AM, Simon Horman <horms@verge.net.au> wrote:
> >> > On Tue, Apr 09, 2013 at 09:34:34PM +0900, Simon Horman wrote:
> >> >> On Mon, Apr 08, 2013 at 10:44:44AM +0900, Magnus Damm wrote:
> >> >> > From: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> >> >> >
> >> >> > Add 1GiB of DRAM at 0x2_0000_0000
> >> >> >
> >> >> > Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
> >> >> > Signed-off-by: Magnus Damm <damm@opensource.se>
> >> >>
> >> >> Thanks, queued up in the boards-ape6evm branch.
> >> >
> >> > I have dropped this patch as it appears to prevent
> >> > the board from booting.
> >>
> >> Is it possible that LPAE=n and HIGHMEM=y in your particular kernel
> >> configuration?
> >
> > Yes, I have confirmed that is what using the ape6evm_defconfig results in.
oup >
> >> >From what I can tell HIGHMEM is broken in cases of large amounts of
> >> memory. Try disabling that as a short-term workaround. Then of course
> >> someone needs to track down why the generic code doesn't work as
> >> expected.
> >
> > I have confirmed that disabling HIGHMEM allows the board to boot
> > with this patch applied.
> 
> Thanks for checking.
> 
> So HIGHMEM without LPAE seems busted on boards using more than 32-bits
> for memory.
> 
> I'd like to help out fixing this issue, but I'd like to make sure that
> no one else is working on this.
> 
> Arnd, are you aware on any work related to making HIGHMEM work without LPAE?
> 
> > Should I prepare a patch to the defconfig to accompany this patch?
> 
> I believe that would affect a bunch of boards so I don't think that is
> necessary at this point. Thanks anyway.
> 
> Would it be possible for you to queue up this change in a APE6EVM topic branch?

Sure, I have pushed topic/ape6evm-2gb.

I also plan to push topic/ape6evm-2gb+renesas-next-20130410v2
once I have finalised renesas-next-20130410v2.

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

* [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-04-08  1:44 [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM Magnus Damm
  2013-04-09 12:34 ` Simon Horman
@ 2013-10-31  3:15 ` Magnus Damm
  2013-10-31  4:20   ` Simon Horman
  2013-11-28  7:56   ` Simon Horman
  2013-10-31  3:18 ` [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref Magnus Damm
  2 siblings, 2 replies; 17+ messages in thread
From: Magnus Damm @ 2013-10-31  3:15 UTC (permalink / raw)
  To: linux-arm-kernel

From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>

Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
of APE6EVM system memory.

Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
Signed-off-by: Magnus Damm <damm@opensource.se>
---

 For correct run time operation regardless of kernel configuration
 ARM patches 7863/1 and 7864/1 are needed.

 arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
 1 file changed, 5 insertions(+)

--- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
+++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-10-31 11:44:53.000000000 +0900
@@ -24,6 +24,11 @@
 		reg = <0 0x40000000 0 0x40000000>;
 	};
 
+	memory@200000000 {
+		device_type = "memory";
+		reg = <2 0x00000000 0 0x40000000>;
+	};
+
 	ape6evm_fixed_3v3: fixedregulator@0 {
 		compatible = "regulator-fixed";
 		regulator-name = "3V3";

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

* [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref
  2013-04-08  1:44 [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM Magnus Damm
  2013-04-09 12:34 ` Simon Horman
  2013-10-31  3:15 ` Magnus Damm
@ 2013-10-31  3:18 ` Magnus Damm
  2013-11-28  7:55   ` Simon Horman
  2 siblings, 1 reply; 17+ messages in thread
From: Magnus Damm @ 2013-10-31  3:18 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
of APE6EVM system memory also in case of DT reference.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 For correct run time operation regardless of kernel configuration
 ARM patches 7863/1 and 7864/1 are needed.

 arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts |    5 +++++
 1 file changed, 5 insertions(+)

--- 0001/arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts
+++ work/arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts	2013-10-31 11:46:51.000000000 +0900
@@ -25,6 +25,11 @@
 		reg = <0 0x40000000 0 0x40000000>;
 	};
 
+	memory@200000000 {
+		device_type = "memory";
+		reg = <2 0x00000000 0 0x40000000>;
+	};
+
 	vcc_mmc0: regulator@0 {
 		compatible = "regulator-fixed";
 		regulator-name = "MMC0 Vcc";

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-10-31  3:15 ` Magnus Damm
@ 2013-10-31  4:20   ` Simon Horman
  2013-10-31  8:02     ` Magnus Damm
  2013-11-28  7:56   ` Simon Horman
  1 sibling, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-10-31  4:20 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> 
> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> of APE6EVM system memory.
> 
> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> Signed-off-by: Magnus Damm <damm@opensource.se>
> ---
> 
>  For correct run time operation regardless of kernel configuration
>  ARM patches 7863/1 and 7864/1 are needed.

I take it that I should wait for those patches before applying this one.

With those two patches and this one applied on top of
renesas-devel-v3.12-rc7-20131030 I was able to successfully
boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
memory. What am I missing.

> 
>  arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> --- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
> +++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-10-31 11:44:53.000000000 +0900
> @@ -24,6 +24,11 @@
>  		reg = <0 0x40000000 0 0x40000000>;
>  	};
>  
> +	memory@200000000 {
> +		device_type = "memory";
> +		reg = <2 0x00000000 0 0x40000000>;
> +	};
> +
>  	ape6evm_fixed_3v3: fixedregulator@0 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "3V3";
> 

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-10-31  4:20   ` Simon Horman
@ 2013-10-31  8:02     ` Magnus Damm
  2013-11-06  1:48       ` Simon Horman
  0 siblings, 1 reply; 17+ messages in thread
From: Magnus Damm @ 2013-10-31  8:02 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Simon,

On Thu, Oct 31, 2013 at 1:20 PM, Simon Horman <horms@verge.net.au> wrote:
> On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
>> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
>>
>> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
>> of APE6EVM system memory.
>>
>> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
>> Signed-off-by: Magnus Damm <damm@opensource.se>
>> ---
>>
>>  For correct run time operation regardless of kernel configuration
>>  ARM patches 7863/1 and 7864/1 are needed.
>
> I take it that I should wait for those patches before applying this one.

That's probably a good idea. RMK has applied them to "git-curr", so I
suppose they are queued up for something at least:

http://www.arm.linux.org.uk/developer/patches/viewpatch.php?idx63/1

> With those two patches and this one applied on top of
> renesas-devel-v3.12-rc7-20131030 I was able to successfully
> boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
> memory. What am I missing.

You probably need to enable HIGHMEM and LPAE to be able to access to
all memory. Same thing on Lager, to get the full 4GiB you need to
select those in your kernel configuration too.

Please note that having memory located on 64-bit addresses may break
some drivers doing bus mastering or using the DMAC. These drivers need
to be fixed both with short term DMA zone workarounds and proper
64-bit address support whenever possible.

So if I could suggest a policy then having LPAE=n in defconfig for the
C board code for default stable operation. This together with LPAE=y
in the case of DT reference and/or Multiplatform where we can be a bit
more experimental. I don't care enough to send defconfig patches, but
if some issue comes up then perhaps adjusting the defconfig to disable
LPAE may work well as a workaround.

Cheers,

/ magnus

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-10-31  8:02     ` Magnus Damm
@ 2013-11-06  1:48       ` Simon Horman
  2013-11-06  9:48         ` Magnus Damm
  0 siblings, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-11-06  1:48 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Oct 31, 2013 at 05:02:13PM +0900, Magnus Damm wrote:
> Hi Simon,
> 
> On Thu, Oct 31, 2013 at 1:20 PM, Simon Horman <horms@verge.net.au> wrote:
> > On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
> >> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> >>
> >> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> >> of APE6EVM system memory.
> >>
> >> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> >> Signed-off-by: Magnus Damm <damm@opensource.se>
> >> ---
> >>
> >>  For correct run time operation regardless of kernel configuration
> >>  ARM patches 7863/1 and 7864/1 are needed.
> >
> > I take it that I should wait for those patches before applying this one.
> 
> That's probably a good idea. RMK has applied them to "git-curr", so I
> suppose they are queued up for something at least:
> 
> http://www.arm.linux.org.uk/developer/patches/viewpatch.php?idx63/1

I have also sighted them in linux-next.
So I expect they will show up in v3.13-rc1 or thereabouts.

> > With those two patches and this one applied on top of
> > renesas-devel-v3.12-rc7-20131030 I was able to successfully
> > boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
> > memory. What am I missing.
> 
> You probably need to enable HIGHMEM and LPAE to be able to access to
> all memory. Same thing on Lager, to get the full 4GiB you need to
> select those in your kernel configuration too.

Thanks, I have been able to successfully test all 4 patches in this
series with those settings enabled.

Tested-by: Simon Horman <horms+renesas@verge.net.au>

> Please note that having memory located on 64-bit addresses may break
> some drivers doing bus mastering or using the DMAC. These drivers need
> to be fixed both with short term DMA zone workarounds and proper
> 64-bit address support whenever possible.
> 
> So if I could suggest a policy then having LPAE=n in defconfig for the
> C board code for default stable operation. This together with LPAE=y
> in the case of DT reference and/or Multiplatform where we can be a bit
> more experimental. I don't care enough to send defconfig patches, but
> if some issue comes up then perhaps adjusting the defconfig to disable
> LPAE may work well as a workaround.

Thanks.

As it stands the defconfig for both APE6EVM and Lager lead to a
configuration with LPAE disabled, although neither explicitly disable LPAE.
I think it is best to leave things as-is in this regards and explicitly
disable LPAE in the defconfigs if the need arises.

While looking over this I noticed that the APE6EVM defconfig selects
HIGHMEM while the Lager defconfig does not and it is not selected in the
resulting config. Would it be worth updating the Lager defconfig to enable
HIGHMEM? If so, I'll make a patch.

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-11-06  1:48       ` Simon Horman
@ 2013-11-06  9:48         ` Magnus Damm
  2013-11-08  6:26           ` Simon Horman
  0 siblings, 1 reply; 17+ messages in thread
From: Magnus Damm @ 2013-11-06  9:48 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Simon,

On Wed, Nov 6, 2013 at 10:48 AM, Simon Horman <horms@verge.net.au> wrote:
> On Thu, Oct 31, 2013 at 05:02:13PM +0900, Magnus Damm wrote:
>> Hi Simon,
>>
>> On Thu, Oct 31, 2013 at 1:20 PM, Simon Horman <horms@verge.net.au> wrote:
>> > On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
>> >> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
>> >>
>> >> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
>> >> of APE6EVM system memory.
>> >>
>> >> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
>> >> Signed-off-by: Magnus Damm <damm@opensource.se>
>> >> ---
>> >>
>> >>  For correct run time operation regardless of kernel configuration
>> >>  ARM patches 7863/1 and 7864/1 are needed.
>> >
>> > I take it that I should wait for those patches before applying this one.
>>
>> That's probably a good idea. RMK has applied them to "git-curr", so I
>> suppose they are queued up for something at least:
>>
>> http://www.arm.linux.org.uk/developer/patches/viewpatch.php?idx63/1
>
> I have also sighted them in linux-next.
> So I expect they will show up in v3.13-rc1 or thereabouts.
>
>> > With those two patches and this one applied on top of
>> > renesas-devel-v3.12-rc7-20131030 I was able to successfully
>> > boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
>> > memory. What am I missing.
>>
>> You probably need to enable HIGHMEM and LPAE to be able to access to
>> all memory. Same thing on Lager, to get the full 4GiB you need to
>> select those in your kernel configuration too.
>
> Thanks, I have been able to successfully test all 4 patches in this
> series with those settings enabled.
>
> Tested-by: Simon Horman <horms+renesas@verge.net.au>
>
>> Please note that having memory located on 64-bit addresses may break
>> some drivers doing bus mastering or using the DMAC. These drivers need
>> to be fixed both with short term DMA zone workarounds and proper
>> 64-bit address support whenever possible.
>>
>> So if I could suggest a policy then having LPAE=n in defconfig for the
>> C board code for default stable operation. This together with LPAE=y
>> in the case of DT reference and/or Multiplatform where we can be a bit
>> more experimental. I don't care enough to send defconfig patches, but
>> if some issue comes up then perhaps adjusting the defconfig to disable
>> LPAE may work well as a workaround.
>
> Thanks.
>
> As it stands the defconfig for both APE6EVM and Lager lead to a
> configuration with LPAE disabled, although neither explicitly disable LPAE.
> I think it is best to leave things as-is in this regards and explicitly
> disable LPAE in the defconfigs if the need arises.
>
> While looking over this I noticed that the APE6EVM defconfig selects
> HIGHMEM while the Lager defconfig does not and it is not selected in the
> resulting config. Would it be worth updating the Lager defconfig to enable
> HIGHMEM? If so, I'll make a patch.

Thanks. I think it mainly makes sense to enable LPAE and HIGHMEM
together, so easiest is probably just to wait with both Lager and
APE6EVM.

Cheers,

/ magnus

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-11-06  9:48         ` Magnus Damm
@ 2013-11-08  6:26           ` Simon Horman
  2013-11-25  2:47             ` Simon Horman
  0 siblings, 1 reply; 17+ messages in thread
From: Simon Horman @ 2013-11-08  6:26 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Nov 06, 2013 at 06:48:45PM +0900, Magnus Damm wrote:
> Hi Simon,
> 
> On Wed, Nov 6, 2013 at 10:48 AM, Simon Horman <horms@verge.net.au> wrote:
> > On Thu, Oct 31, 2013 at 05:02:13PM +0900, Magnus Damm wrote:
> >> Hi Simon,
> >>
> >> On Thu, Oct 31, 2013 at 1:20 PM, Simon Horman <horms@verge.net.au> wrote:
> >> > On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
> >> >> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> >> >>
> >> >> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> >> >> of APE6EVM system memory.
> >> >>
> >> >> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> >> >> Signed-off-by: Magnus Damm <damm@opensource.se>
> >> >> ---
> >> >>
> >> >>  For correct run time operation regardless of kernel configuration
> >> >>  ARM patches 7863/1 and 7864/1 are needed.
> >> >
> >> > I take it that I should wait for those patches before applying this one.
> >>
> >> That's probably a good idea. RMK has applied them to "git-curr", so I
> >> suppose they are queued up for something at least:
> >>
> >> http://www.arm.linux.org.uk/developer/patches/viewpatch.php?idx63/1
> >
> > I have also sighted them in linux-next.
> > So I expect they will show up in v3.13-rc1 or thereabouts.
> >
> >> > With those two patches and this one applied on top of
> >> > renesas-devel-v3.12-rc7-20131030 I was able to successfully
> >> > boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
> >> > memory. What am I missing.
> >>
> >> You probably need to enable HIGHMEM and LPAE to be able to access to
> >> all memory. Same thing on Lager, to get the full 4GiB you need to
> >> select those in your kernel configuration too.
> >
> > Thanks, I have been able to successfully test all 4 patches in this
> > series with those settings enabled.
> >
> > Tested-by: Simon Horman <horms+renesas@verge.net.au>
> >
> >> Please note that having memory located on 64-bit addresses may break
> >> some drivers doing bus mastering or using the DMAC. These drivers need
> >> to be fixed both with short term DMA zone workarounds and proper
> >> 64-bit address support whenever possible.
> >>
> >> So if I could suggest a policy then having LPAE=n in defconfig for the
> >> C board code for default stable operation. This together with LPAE=y
> >> in the case of DT reference and/or Multiplatform where we can be a bit
> >> more experimental. I don't care enough to send defconfig patches, but
> >> if some issue comes up then perhaps adjusting the defconfig to disable
> >> LPAE may work well as a workaround.
> >
> > Thanks.
> >
> > As it stands the defconfig for both APE6EVM and Lager lead to a
> > configuration with LPAE disabled, although neither explicitly disable LPAE.
> > I think it is best to leave things as-is in this regards and explicitly
> > disable LPAE in the defconfigs if the need arises.
> >
> > While looking over this I noticed that the APE6EVM defconfig selects
> > HIGHMEM while the Lager defconfig does not and it is not selected in the
> > resulting config. Would it be worth updating the Lager defconfig to enable
> > HIGHMEM? If so, I'll make a patch.
> 
> Thanks. I think it mainly makes sense to enable LPAE and HIGHMEM
> together, so easiest is probably just to wait with both Lager and
> APE6EVM.

Sure. I will immediately do nothing :)

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-11-08  6:26           ` Simon Horman
@ 2013-11-25  2:47             ` Simon Horman
  0 siblings, 0 replies; 17+ messages in thread
From: Simon Horman @ 2013-11-25  2:47 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Nov 08, 2013 at 03:26:23PM +0900, Simon Horman wrote:
> On Wed, Nov 06, 2013 at 06:48:45PM +0900, Magnus Damm wrote:
> > Hi Simon,
> > 
> > On Wed, Nov 6, 2013 at 10:48 AM, Simon Horman <horms@verge.net.au> wrote:
> > > On Thu, Oct 31, 2013 at 05:02:13PM +0900, Magnus Damm wrote:
> > >> Hi Simon,
> > >>
> > >> On Thu, Oct 31, 2013 at 1:20 PM, Simon Horman <horms@verge.net.au> wrote:
> > >> > On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
> > >> >> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> > >> >>
> > >> >> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> > >> >> of APE6EVM system memory.
> > >> >>
> > >> >> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> > >> >> Signed-off-by: Magnus Damm <damm@opensource.se>
> > >> >> ---
> > >> >>
> > >> >>  For correct run time operation regardless of kernel configuration
> > >> >>  ARM patches 7863/1 and 7864/1 are needed.
> > >> >
> > >> > I take it that I should wait for those patches before applying this one.
> > >>
> > >> That's probably a good idea. RMK has applied them to "git-curr", so I
> > >> suppose they are queued up for something at least:
> > >>
> > >> http://www.arm.linux.org.uk/developer/patches/viewpatch.php?idx63/1
> > >
> > > I have also sighted them in linux-next.
> > > So I expect they will show up in v3.13-rc1 or thereabouts.

v3.13-rc1 is released and I have rebased the branches in the renesas tree
on top of it. Should I go ahead and queue up this patch and its 3 friends:

	ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref
	ARM: shmobile: Include all 4 GiB of memory on Lager
	ARM: shmobile: Include all 4 GiB of memory on Lager DT Ref

> > >
> > >> > With those two patches and this one applied on top of
> > >> > renesas-devel-v3.12-rc7-20131030 I was able to successfully
> > >> > boot an ape6evm board. But /proc/meminfo still indicates only 1Gb of
> > >> > memory. What am I missing.
> > >>
> > >> You probably need to enable HIGHMEM and LPAE to be able to access to
> > >> all memory. Same thing on Lager, to get the full 4GiB you need to
> > >> select those in your kernel configuration too.
> > >
> > > Thanks, I have been able to successfully test all 4 patches in this
> > > series with those settings enabled.
> > >
> > > Tested-by: Simon Horman <horms+renesas@verge.net.au>
> > >
> > >> Please note that having memory located on 64-bit addresses may break
> > >> some drivers doing bus mastering or using the DMAC. These drivers need
> > >> to be fixed both with short term DMA zone workarounds and proper
> > >> 64-bit address support whenever possible.
> > >>
> > >> So if I could suggest a policy then having LPAE=n in defconfig for the
> > >> C board code for default stable operation. This together with LPAE=y
> > >> in the case of DT reference and/or Multiplatform where we can be a bit
> > >> more experimental. I don't care enough to send defconfig patches, but
> > >> if some issue comes up then perhaps adjusting the defconfig to disable
> > >> LPAE may work well as a workaround.
> > >
> > > Thanks.
> > >
> > > As it stands the defconfig for both APE6EVM and Lager lead to a
> > > configuration with LPAE disabled, although neither explicitly disable LPAE.
> > > I think it is best to leave things as-is in this regards and explicitly
> > > disable LPAE in the defconfigs if the need arises.
> > >
> > > While looking over this I noticed that the APE6EVM defconfig selects
> > > HIGHMEM while the Lager defconfig does not and it is not selected in the
> > > resulting config. Would it be worth updating the Lager defconfig to enable
> > > HIGHMEM? If so, I'll make a patch.
> > 
> > Thanks. I think it mainly makes sense to enable LPAE and HIGHMEM
> > together, so easiest is probably just to wait with both Lager and
> > APE6EVM.
> 
> Sure. I will immediately do nothing :)
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref
  2013-10-31  3:18 ` [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref Magnus Damm
@ 2013-11-28  7:55   ` Simon Horman
  0 siblings, 0 replies; 17+ messages in thread
From: Simon Horman @ 2013-11-28  7:55 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Oct 31, 2013 at 12:18:41PM +0900, Magnus Damm wrote:
> From: Magnus Damm <damm@opensource.se>
> 
> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> of APE6EVM system memory also in case of DT reference.
> 
> Signed-off-by: Magnus Damm <damm@opensource.se>

Thanks, I have queued this up.

> ---
> 
>  For correct run time operation regardless of kernel configuration
>  ARM patches 7863/1 and 7864/1 are needed.
> 
>  arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> --- 0001/arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts
> +++ work/arch/arm/boot/dts/r8a73a4-ape6evm-reference.dts	2013-10-31 11:46:51.000000000 +0900
> @@ -25,6 +25,11 @@
>  		reg = <0 0x40000000 0 0x40000000>;
>  	};
>  
> +	memory@200000000 {
> +		device_type = "memory";
> +		reg = <2 0x00000000 0 0x40000000>;
> +	};
> +
>  	vcc_mmc0: regulator@0 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "MMC0 Vcc";
> 

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

* Re: [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM
  2013-10-31  3:15 ` Magnus Damm
  2013-10-31  4:20   ` Simon Horman
@ 2013-11-28  7:56   ` Simon Horman
  1 sibling, 0 replies; 17+ messages in thread
From: Simon Horman @ 2013-11-28  7:56 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Oct 31, 2013 at 12:15:49PM +0900, Magnus Damm wrote:
> From: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> 
> Add 1GiB of DRAM at 0x2_0000_0000 to support the full 2GiB
> of APE6EVM system memory.
> 
> Signed-off-by: Takashi Yoshii <takasi-y@ops.dti.ne.jp>
> Signed-off-by: Magnus Damm <damm@opensource.se>
> ---

Thanks, I have queued this up.

> 
>  For correct run time operation regardless of kernel configuration
>  ARM patches 7863/1 and 7864/1 are needed.
> 
>  arch/arm/boot/dts/r8a73a4-ape6evm.dts |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> --- 0001/arch/arm/boot/dts/r8a73a4-ape6evm.dts
> +++ work/arch/arm/boot/dts/r8a73a4-ape6evm.dts	2013-10-31 11:44:53.000000000 +0900
> @@ -24,6 +24,11 @@
>  		reg = <0 0x40000000 0 0x40000000>;
>  	};
>  
> +	memory@200000000 {
> +		device_type = "memory";
> +		reg = <2 0x00000000 0 0x40000000>;
> +	};
> +
>  	ape6evm_fixed_3v3: fixedregulator@0 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "3V3";
> 

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

end of thread, other threads:[~2013-11-28  7:56 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-08  1:44 [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM Magnus Damm
2013-04-09 12:34 ` Simon Horman
2013-04-09 16:14   ` Simon Horman
2013-04-09 22:27     ` Magnus Damm
2013-04-10  0:35       ` Simon Horman
2013-04-10  1:38         ` Magnus Damm
2013-04-10  2:09           ` Simon Horman
2013-10-31  3:15 ` Magnus Damm
2013-10-31  4:20   ` Simon Horman
2013-10-31  8:02     ` Magnus Damm
2013-11-06  1:48       ` Simon Horman
2013-11-06  9:48         ` Magnus Damm
2013-11-08  6:26           ` Simon Horman
2013-11-25  2:47             ` Simon Horman
2013-11-28  7:56   ` Simon Horman
2013-10-31  3:18 ` [PATCH] ARM: shmobile: Include all 2 GiB of memory on APE6EVM DT Ref Magnus Damm
2013-11-28  7:55   ` Simon Horman

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).