From: Heiko Carstens <heiko.carstens@de.ibm.com>
To: Christoph Lameter <clameter@sgi.com>
Cc: Pekka J Enberg <penberg@cs.helsinki.fi>,
akpm@osdl.org, manfred@colorfullife.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] slab: respect architecture and caller mandated alignment
Date: Fri, 28 Jul 2006 08:20:28 +0200 [thread overview]
Message-ID: <20060728062028.GA9559@osiris.boeblingen.de.ibm.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0607271909580.15840@schroedinger.engr.sgi.com>
On Thu, Jul 27, 2006 at 07:25:56PM -0700, Christoph Lameter wrote:
> On Thu, 27 Jul 2006, Pekka J Enberg wrote:
>
> > As explained by Heiko, on s390 (32-bit) ARCH_KMALLOC_MINALIGN is set to eight
> > because their common I/O layer allocates data structures that need to have an
> > eight byte alignment. This does not work when CONFIG_SLAB_DEBUG is enabled
> > because kmem_cache_create will override alignment to BYTES_PER_WORD which is
> > four.
> >
> > So change kmem_cache_create to ensure cache alignment is always at minimum
> > what the architecture or caller mandates even if slab debugging is enabled.
>
> Note that this will disable SLAB_RED_ZONE and SLAB_STORE_USER
> for the following SLAB_DEBUG cases:
>
> 1. For all slabs if an arch sets ARCH_SLAB_MINALIGN > BYTES_PER_WORD
> [...]
> 2. For all general (kmalloc) slabs if an arch sets
> ARCH_KMALLOC_MINALIGN > BYTES_PER_WORD
> [...]
> F.e. S/390 will not be able to use slab debug for the general slabs.
>
> You may want to document that change somewhere.
It is already documented (see top of slab.c). The only thing that was wrong was
that ARCH_SLAB_MINALIGN and ARCH_KMALLOC_MINALIGN didn't have the effect like
one would expect from the documentation.
next prev parent reply other threads:[~2006-07-28 6:22 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-27 12:15 Pekka J Enberg
2006-07-28 2:25 ` Christoph Lameter
2006-07-28 6:20 ` Heiko Carstens [this message]
2006-07-28 15:19 ` Christoph Lameter
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=20060728062028.GA9559@osiris.boeblingen.de.ibm.com \
--to=heiko.carstens@de.ibm.com \
--cc=akpm@osdl.org \
--cc=clameter@sgi.com \
--cc=linux-kernel@vger.kernel.org \
--cc=manfred@colorfullife.com \
--cc=penberg@cs.helsinki.fi \
/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
all inboxes | Powered by JetHome®