lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0607230558560.15651@schroedinger.engr.sgi.com>
Date:	Sun, 23 Jul 2006 06:03:09 -0700 (PDT)
From:	Christoph Lameter <clameter@....com>
To:	Heiko Carstens <heiko.carstens@...ibm.com>
cc:	Andrew Morton <akpm@...l.org>, linux-kernel@...r.kernel.org,
	Pekka Enberg <penberg@...helsinki.fi>
Subject: Re: [patch] slab: always follow arch requested alignments

On Sun, 23 Jul 2006, Heiko Carstens wrote:

> > 
> > See kmem_cache_create():
> >       /* 2) arch mandated alignment: disables debug if necessary */
> >         if (ralign < ARCH_SLAB_MINALIGN) {
> >                 ralign = ARCH_SLAB_MINALIGN;
> >                 if (ralign > BYTES_PER_WORD)
> >                         flags &= ~(SLAB_RED_ZONE | SLAB_STORE_USER);
> >         }
> 
> That is because if kmem_cache_create gets called with SLAB_HWCACHE_ALIGN set
> in flags then ralign will be greater or equal to ARCH_SLAB_MINALIGN:
> 
>         /* 1) arch recommendation: can be overridden for debug */ 
>         if (flags & SLAB_HWCACHE_ALIGN) { 
> 	        [...]
>                 ralign = cache_line_size(); 
> 	        [...]

Ok. Then you do not have a problem because ralign is greater than
ARCH_SLAB_MINALIGN.
 
> Therefore the test above will be passed and SLAB_RED_ZONE and SLAB_STORE_USER
> will stay in flags.
> cache_line_size() will return 256 on s390.

Looks as if you would have the correct alignment then. I still do not 
understand where the problem is since you want to align on an 8 byte 
boundary.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ