From b1114df674ba3812117c607cb7958659883ba07a Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Thu, 11 Nov 2010 12:53:47 +0000 Subject: [PATCH] --- yaml --- r: 222181 b: refs/heads/master c: 04e4bd1c67f941d81bff78a3b6b94194f081b7df h: refs/heads/master i: 222179: fa9842722e349c6c9c3e83ad30de01f7e103682b v: v3 --- [refs] | 2 +- trunk/fs/nfs/dir.c | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index d4ba7adf87b4..9819717d4dc3 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 94f58df8e545657f0b2d16eca1ac7a4ec39ed6be +refs/heads/master: 04e4bd1c67f941d81bff78a3b6b94194f081b7df diff --git a/trunk/fs/nfs/dir.c b/trunk/fs/nfs/dir.c index c9196c9cf5a6..662df2a5fad5 100644 --- a/trunk/fs/nfs/dir.c +++ b/trunk/fs/nfs/dir.c @@ -34,6 +34,7 @@ #include #include #include +#include #include "delegation.h" #include "iostat.h" @@ -238,6 +239,11 @@ int nfs_readdir_make_qstr(struct qstr *string, const char *name, unsigned int le string->name = kmemdup(name, len, GFP_KERNEL); if (string->name == NULL) return -ENOMEM; + /* + * Avoid a kmemleak false positive. The pointer to the name is stored + * in a page cache page which kmemleak does not scan. + */ + kmemleak_not_leak(string->name); string->hash = full_name_hash(name, len); return 0; }