On Wed, Apr 27, 2022 at 10:21:51AM -0700, Minchan Kim wrote:
kernfs_remove supported NULL kernfs_node param to bail out but revent
^ typo
per-fs lock change introduced regression that dereferencing the param without NULL check so kernel goes crash.
This patch checks the NULL kernfs_node in kernfs_remove and if so, just return.
...
Cc: stable@vger.kernel.org Link: https://bugzilla.kernel.org/show_bug.cgi?id=215696 Link: https://lore.kernel.org/lkml/CAE4VaGDZr_4wzRn2___eDYRtmdPaGGJdzu_LCSkJYuY9BE... Fixes: 393c3714081a (kernfs: switch global kernfs_rwsem lock to per-fs lock) Reported-by: Jirka Hladky jhladky@redhat.com Tested-by: Jirka Hladky jhladky@redhat.com Signed-off-by: Minchan Kim minchan@kernel.org
Acked-by: Tejun Heo tj@kernel.org
Thanks.