linux-stable/drivers/media/common/siano
Jinjie Ruan 8cd08e3651 media: siano: Drop unnecessary error check for debugfs_create_dir/file()
Both debugfs_create_dir() and debugfs_create_file() return ERR_PTR
and never return NULL.

As Hans suggested, this patch removes the error checking for both
debugfs_create_dir() and debugfs_create_file() in smsdvb_debugfs_create().
This is because the DebugFS kernel API is developed in a way that the
caller can safely ignore the errors that occur during the creation of
DebugFS nodes. The debugfs APIs have a IS_ERR() judge in start_creating()
which can handle it gracefully. So these checks are unnecessary.

And as Hans pointed out, it's much better to first allocate debug_data
before calling debugfs_create_dir, which need not to clean anything up in
that case.

Fixes: 503efe5cfc ("[media] siano: split debugfs code into a separate file")
Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2023-10-13 11:33:22 +02:00
..
Kconfig
Makefile
sms-cards.c media: siano: rename a duplicated card string 2020-10-02 14:25:12 +02:00
sms-cards.h
smscoreapi.c media: siano: use DEFINE_MUTEX() for mutex lock 2021-09-30 10:07:43 +02:00
smscoreapi.h media: siano: Fix out-of-bounds warnings in smscore_load_firmware_family2() 2021-06-07 14:11:47 -05:00
smsdvb-debugfs.c media: siano: Drop unnecessary error check for debugfs_create_dir/file() 2023-10-13 11:33:22 +02:00
smsdvb-main.c media: siano: fix device register error path 2021-06-17 09:27:08 +02:00
smsdvb.h
smsendian.c drivers/media/common/siano/smsendian.c : eliminate unnecessary type conversions 2023-07-19 12:57:46 +02:00
smsendian.h
smsir.c media: rc: harmonize infrared durations to microseconds 2020-09-03 16:18:55 +02:00
smsir.h media: siano: Use the correct style for SPDX License Identifier 2019-11-10 17:46:45 +01:00