Re: [U-Boot] porting u-boot, MMU question

2014-11-06 Thread DaveKucharczyk
Thank you for the responses guys, much appreciated. We will look into using
the latest release.

Another question...

Can we still use setenv() in the board file?

Before, we setup environment variables in board_late_intit() with setenv,
but it doesn't seem to work in new u-boot

I also tried it in board_early_init_f(), board_init() and checkboard(), to
no avail.

It works if I set it up in the header file, but I have conditionals in the
board file to setup different environments, so just wondering if it's still
possible. 

BTW I'm lobbying for my company to send me to denx for training :)
 



--
View this message in context: 
http://u-boot.10912.n7.nabble.com/porting-u-boot-MMU-question-tp194761p194989.html
Sent from the U-Boot mailing list archive at Nabble.com.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] porting u-boot, MMU question

2014-11-05 Thread DaveKucharczyk
I'm trying to upgrade u-boot-2009.08 to u-boot-2014.07. 

Our board is loosely based on the Freescale mx53loco board. I used the old
board file and config header files and moved them over to new u-boot
directory. Then using the new api to make changes.

I'm now trying to figure out how to port and turn on the MMU part below. I
noticed the below code is not in the new mx53loco board file anymore and
MMU_ON() doesn't exist either, since include/asm-arm/mmu.h is not included
in new u-boot. 

So how do I get the same effect? I see arch/arm/cpu/armv8/cache_v8.c and
arch/arm/lib/cache-cp15.c are the likely candidates?





--
View this message in context: 
http://u-boot.10912.n7.nabble.com/porting-u-boot-MMU-question-tp194761.html
Sent from the U-Boot mailing list archive at Nabble.com.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] porting u-boot, MMU question

2014-11-05 Thread Stefano Babic
Hi David,

On 05/11/2014 17:36, DaveKucharczyk wrote:
 I'm trying to upgrade u-boot-2009.08 to u-boot-2014.07. 
 
 Our board is loosely based on the Freescale mx53loco board. I used the old
 board file and config header files and moved them over to new u-boot
 directory. Then using the new api to make changes.
 
 I'm now trying to figure out how to port and turn on the MMU part below. I
 noticed the below code is not in the new mx53loco board file anymore and
 MMU_ON() doesn't exist either, since include/asm-arm/mmu.h is not included
 in new u-boot. 

Instead of doing this, I think it will be easier if you start from the
current mx53loco nad make the customization for your board. Freescale's
U-Boot (2009.08) and mainline diverged, as well as some internal API.

 
 So how do I get the same effect? I see arch/arm/cpu/armv8/cache_v8.c and
 arch/arm/lib/cache-cp15.c are the likely candidates?

You do not need to care about that. Cache is activated per default with
mx5/mx6, if you do not explicitely deactivate it in your config file.
You do not need to bother about MMU setup in your board files.

Best regards,
Stefano Babic

-- 
=
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sba...@denx.de
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] porting u-boot, MMU question

2014-11-05 Thread DaveKucharczyk
Stefano, thank you for the very fast response. :)

Stefano Babic wrote
 Instead of doing this, I think it will be easier if you start from the
 current mx53loco nad make the customization for your board. Freescale's
 U-Boot (2009.08) and mainline diverged, as well as some internal API.

Initially that's what I wanted to do, but we have too many changes and I was
told to do it this way. Needless to say it's very slow going.  

Stefano Babic wrote
 You do not need to care about that. Cache is activated per default with
 mx5/mx6, if you do not explicitely deactivate it in your config file.
 You do not need to bother about MMU setup in your board files.

Ok thanks. Why did the old U-Boot (2009.08) loco board file have the MMU
stuff and the new U-Boot (2014.07) loco board file doesn't? 



--
View this message in context: 
http://u-boot.10912.n7.nabble.com/porting-u-boot-MMU-question-tp194761p194767.html
Sent from the U-Boot mailing list archive at Nabble.com.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] porting u-boot, MMU question

2014-11-05 Thread Stefano Babic
Hi Dave,

On 05/11/2014 18:16, DaveKucharczyk wrote:

 Stefano Babic wrote
 You do not need to care about that. Cache is activated per default with
 mx5/mx6, if you do not explicitely deactivate it in your config file.
 You do not need to bother about MMU setup in your board files.
 
 Ok thanks. Why did the old U-Boot (2009.08) loco board file have the MMU
 stuff and the new U-Boot (2014.07) loco board file doesn't? 

It is not true. Old mainline U-Boot has never had that MMU stuff. U-Boot
uses flat address space and MMU is setup only for enabling cache.
If you check in mainline tree for the 2009.8 tag, you will find no MMU
stuff at all. Your old U-Boot was delivered by the manufacturer and
not supported by the community.

Best regards,
Stefano Babic


-- 
=
DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sba...@denx.de
=
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] porting u-boot, MMU question

2014-11-05 Thread Otavio Salvador
Hello Dave,

On Wed, Nov 5, 2014 at 7:04 PM, Stefano Babic sba...@denx.de wrote:
 On 05/11/2014 18:16, DaveKucharczyk wrote:
 Stefano Babic wrote
 You do not need to care about that. Cache is activated per default with
 mx5/mx6, if you do not explicitely deactivate it in your config file.
 You do not need to bother about MMU setup in your board files.

 Ok thanks. Why did the old U-Boot (2009.08) loco board file have the MMU
 stuff and the new U-Boot (2014.07) loco board file doesn't?

 It is not true. Old mainline U-Boot has never had that MMU stuff. U-Boot
 uses flat address space and MMU is setup only for enabling cache.
 If you check in mainline tree for the 2009.8 tag, you will find no MMU
 stuff at all. Your old U-Boot was delivered by the manufacturer and
 not supported by the community.

On top of that, I suggest you to use 2014.10 release as it includes a
number of nice new features and bug fixes. It would also easy your
next upgrade as it will reduce the amount of delta for next release,
in case you want to move to it.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot