Re: [PATCH for-3.6] debugfs: change parameter check indebugfs_remove() functions

From: Greg Kroah-Hartman
Date: Wed May 23 2012 - 09:29:18 EST


On Wed, May 23, 2012 at 03:13:07PM +0200, Arend van Spriel wrote:
> The dentry parameter in debugfs_remove() and debugfs_remove_recursive()
> is checked being a NULL pointer. To make cleanup by callers easier this
> check is extended using the IS_ERR_OR_NULL macro instead because the
> debugfs_create_... functions can return a ERR_PTR() value.
>
> Signed-off-by: Arend van Spriel <arend@xxxxxxxxxxxx>
> ---
> I was adding the check in driver code before calling the recursive remove,
> but considered it might be a better idea to do it in debugfs itself.

Yes, nice change, thanks.

I'll queue it up after 3.5-rc1 is out.

thanks,

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