summaryrefslogtreecommitdiff
path: root/arch/loongarch
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@linaro.org>2023-06-29 20:58:42 +0800
committerHuacai Chen <chenhuacai@loongson.cn>2023-06-29 20:58:42 +0800
commitd7c24960975b02211c53afe97c36acde5c8ff933 (patch)
tree15bab77a3a1c44cc82a4d3f28306f65e5679b6a9 /arch/loongarch
parent872b368b2282604aafbc8af1275e0b28a73b8636 (diff)
LoongArch: Delete unnecessary debugfs checking
Debugfs functions are not supposed to be checked for errors. This is sort of unusual but it is described in the comments for the debugfs_create_dir() function. Also debugfs_create_dir() can never return NULL. Reviewed-by: WANG Xuerui <git@xen0n.name> Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Diffstat (limited to 'arch/loongarch')
-rw-r--r--arch/loongarch/kernel/unaligned.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/loongarch/kernel/unaligned.c b/arch/loongarch/kernel/unaligned.c
index 85fae3d2d71a..3abf163dda05 100644
--- a/arch/loongarch/kernel/unaligned.c
+++ b/arch/loongarch/kernel/unaligned.c
@@ -485,8 +485,6 @@ static int __init debugfs_unaligned(void)
struct dentry *d;
d = debugfs_create_dir("loongarch", NULL);
- if (IS_ERR_OR_NULL(d))
- return -ENOMEM;
debugfs_create_u32("unaligned_instructions_user",
S_IRUGO, d, &unaligned_instructions_user);