[ELDK] mmap: first byte always wrong
Wolfgang Denk
wd at denx.de
Fri Nov 26 08:53:33 CET 2010
Dear Alberto Caballero,
In message <AANLkTikG-GnFz416=VLG1ByrPkHTF25Qq9om2wD6dJC3 at mail.gmail.com> you wrote:
>
> At my project, I will have a data configuration file stored in the board
> Flash memory using an U-Boot filesystem image. At the initialization stage,
> I read the image from the Flash and store it in the Linux filesystem.
I have to admit that I don't understand what you mean or what you are
trying to acchieve.
> Of course at the U-Boot prompt I am able to check that image header at Flash
> is correctly stored and all the bytes has the right values. I was wondering
> if this has something to do with first access to mapped memory.
I don;t understand this either. What has the operation of U-Boot to
do with any mapped memory? U-boot doesn;t need any such mapping. It
dierectly accesses the physical memory.
> When Linux initializes it creates a series of MTD partitions by its own. Now
No. Linux _never_ does anything "on it's own". It does only what you
instruct it to do. You are responsibe to configure the partitions you
need or want on your system, either as a fixed mapping, or through the
device tree, or using aan appropriate "mtdparts" command line argument
(which then allows you to use the "mtdparts" command in U-Boot to make
sure both U-Boot and Linus have a consistemt view of your MTD
partitions).
> the data in the Flash will be overlapped in two partitions so I will try to
> use just one of them.
Why don't you fix the root cause of the problem? Set up the partitions
as you need them!
> Regarding the mmap usage, I was able to check with another board with
> another PowerPC processor using ELDK also, and in this case there is no
> issue with Flash access.
Of course there are also chances that your kernel port is broken - as
mentioned, your board is unsupported both in mainline and in our tree.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Applying computer technology is simply finding the right wrench to
pound in the correct screw.
More information about the eldk
mailing list