[PATCH] arm: align shared memory unconditionally to the SHMLBA boundary

Russell King - ARM Linux linux at arm.linux.org.uk
Mon Jul 15 14:08:46 EDT 2013

On Mon, Jul 15, 2013 at 09:32:38PM +0400, Cyrill Gorcunov wrote:
> On Tue, Feb 19, 2013 at 10:11:09AM +0400, Alexander Kartashov wrote:
> > Currently IPC SHM works in a strange way on ARM:
> > the syscall sys_shmat() requires the argument shmaddr
> > be SHMLBA-aligned (ARM has the macro __ARCH_FORCE_SHMLBA
> > unconditionally defined) but allocates memory that
> > isn't SHMLBA-aligned because the value of memory alignment
> > depends on presense of certain cache aliases.
> Hi guys, is there some conclusion on this patch? It has been sent
> almost 5 months back ;)

It's pointless.  The alignment is only required for CPUs which have
aliasing caches.  What the code does in mmap() is correct.  However,
we can't dynamically select this in the SHM code.

More information about the linux-arm-kernel mailing list