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]
Date:	Wed, 25 May 2011 16:34:48 -0700 (PDT)
From:	David Rientjes <rientjes@...gle.com>
To:	Christoph Lameter <cl@...ux.com>
cc:	Pekka Enberg <penberg@...nel.org>, linux-kernel@...r.kernel.org
Subject: Re: [patch 4/6] slub: avoid compiling SLAB_CACHE_DMA without DMA
 support

On Wed, 25 May 2011, Christoph Lameter wrote:

> > If CONFIG_ZONE_DMA is disabled, SLAB_CACHE_DMA is a no-op.  Avoid
> > compiling support for it on such a configuration.
> 
> Setting SLAB_CACHE_DMA to zero in the !ZONE_DMA case could avoid some of
> the ifdeffery.
> 

That doesn't actually accomplish anything since all SLAB_CACHE_DMA does is 
set SLUB_DMA, which is already 0 in slub_def.h without CONFIG_ZONE_DMA:

	#ifdef CONFIG_ZONE_DMA
	#define SLUB_DMA __GFP_DMA  
	#else
	/* Disable DMA functionality */
	#define SLUB_DMA (__force gfp_t)0
	#endif

So doing the same for SLAB_CACHE_DMA wouldn't do anything.  The point of 
the patchset is to break the build if SLAB_CACHE_DMA is passed to 
kmem_cache_create() and the kernel is not compiled for DMA support.  That 
should result in a build breakage rather than silently not supporting DMA 
slab caches since it needs to be corrected at build.
--
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