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
| ||
|
Message-ID: <20151009080835.GC2302@esperanza> Date: Fri, 9 Oct 2015 11:08:36 +0300 From: Vladimir Davydov <vdavydov@...tuozzo.com> To: Andrew Morton <akpm@...ux-foundation.org> CC: Christoph Lameter <cl@...ux.com>, Pekka Enberg <penberg@...nel.org>, David Rientjes <rientjes@...gle.com>, Joonsoo Kim <iamjoonsoo.kim@....com>, <linux-mm@...ck.org>, <linux-kernel@...r.kernel.org> Subject: Re: [PATCH 2/3] slab_common: clear pointers to per memcg caches on destroy On Thu, Oct 08, 2015 at 02:17:35PM -0700, Andrew Morton wrote: > On Thu, 8 Oct 2015 19:02:40 +0300 Vladimir Davydov <vdavydov@...tuozzo.com> wrote: > > > Currently, we do not clear pointers to per memcg caches in the > > memcg_params.memcg_caches array when a global cache is destroyed with > > kmem_cache_destroy. It is fine if the global cache does get destroyed. > > However, a cache can be left on the list if it still has active objects > > when kmem_cache_destroy is called (due to a memory leak). If this > > happens, the entries in the array will point to already freed areas, > > which is likely to result in data corruption when the cache is reused > > (via slab merging). > > It's important that we report these leaks so the kernel bug can get > fixed. The patch doesn't add such detection and reporting, but it > could do so? Reporting individual leaks is up to the slab implementation, we simply can't do it from the generic code, so we just warn that there is a leak there. SLUB already dumps addresses of all leaked objects to the log (see kmem_cache_close -> free_partial -> list_slab_objects). Thanks, Vladimir -- 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