From: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 2/2] OMAP: disable unaligned access when building the IFT
Date: Wed, 05 Dec 2012 14:25:54 +0100 [thread overview]
Message-ID: <lytxs08wbh.fsf@ensc-virt.intern.sigma-chemnitz.de> (raw)
In-Reply-To: <20121205121513.GG10369@pengutronix.de> (Sascha Hauer's message of "Wed, 5 Dec 2012 13:15:13 +0100")
Sascha Hauer <s.hauer@pengutronix.de> writes:
>> Coupling the -mno-unaligned-access to the TEXT_BASE and the used processor
>> might be a better solution.
>
> No, unaligned accesses are handled by the cache. They won't work when
> the MMU is disabled, but barebox has to work with MMU disabled.
ok; this stuff seems to be really processor dependent then. E.g. unaligned
access works on Cortex-M3 which is ARMv7 but has neither an MMU nor an MPU.
Perhaps 'CONFIG_ARM_NOUNALIGNED' should default to yes when !MMU, and/or
it should be selected by other problematic configurations. Of course,
there is still the problem that some C code is executed before MMU will
be enabled and unaligned access can happen there.
While thinking about it... cause of the core problem (unaligned access
exception when executed in SRAM) might be that SRAM memory mapped as
strongly ordered memory:
| :/ mmuinfo 0x40300000
| ...
| Inner mem. attr. [6:4]: 0x1 (0b001 Strongly-ordered)
Perhaps, this memory can be remapped as normal memory.
Enrico
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2012-12-05 13:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-04 12:02 [PATCH 1/2] ARM: added Kconfig option for -mno-unaligned compiler flag Enrico Scholz
2012-12-04 12:02 ` [PATCH 2/2] OMAP: disable unaligned access when building the IFT Enrico Scholz
2012-12-05 10:46 ` Sascha Hauer
2012-12-05 11:33 ` Enrico Scholz
2012-12-05 11:43 ` Enrico Scholz
2012-12-05 12:15 ` Sascha Hauer
2012-12-05 13:25 ` Enrico Scholz [this message]
2012-12-05 14:43 ` Enrico Scholz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=lytxs08wbh.fsf@ensc-virt.intern.sigma-chemnitz.de \
--to=enrico.scholz@sigma-chemnitz.de \
--cc=barebox@lists.infradead.org \
--cc=s.hauer@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox