This is a note to let you know that I've just added the patch titled LoongArch: Fix debugfs_create_dir() error checking to the 6.3-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: loongarch-fix-debugfs_create_dir-error-checking.patch and it can be found in the queue-6.3 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 41efbb682de1231c3f6361039f46ad149e3ff5b9 Mon Sep 17 00:00:00 2001 From: Immad Mir <mirimmad17@xxxxxxxxx> Date: Thu, 15 Jun 2023 14:35:56 +0800 Subject: LoongArch: Fix debugfs_create_dir() error checking From: Immad Mir <mirimmad17@xxxxxxxxx> commit 41efbb682de1231c3f6361039f46ad149e3ff5b9 upstream. The debugfs_create_dir() returns ERR_PTR in case of an error and the correct way of checking it is using the IS_ERR_OR_NULL inline function rather than the simple null comparision. This patch fixes the issue. Cc: stable@xxxxxxxxxxxxxxx Suggested-By: Ivan Orlov <ivan.orlov0322@xxxxxxxxx> Signed-off-by: Immad Mir <mirimmad17@xxxxxxxxx> Signed-off-by: Huacai Chen <chenhuacai@xxxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- arch/loongarch/kernel/unaligned.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/loongarch/kernel/unaligned.c +++ b/arch/loongarch/kernel/unaligned.c @@ -485,7 +485,7 @@ static int __init debugfs_unaligned(void struct dentry *d; d = debugfs_create_dir("loongarch", NULL); - if (!d) + if (IS_ERR_OR_NULL(d)) return -ENOMEM; debugfs_create_u32("unaligned_instructions_user", Patches currently in stable-queue which might be from mirimmad17@xxxxxxxxx are queue-6.3/loongarch-fix-debugfs_create_dir-error-checking.patch