This series cleans up dead code in the Greybus audio manager.
gb_audio_manager_get_module() has no in-tree callers. The previously
reported NULL dereference is therefore unreachable. Per review feedback,
the unused function is removed to avoid carrying dead code.
Patch 2 performs a small cleanup in the same area.
Changes in v3:
- Replaced the NULL-deref fix with removal of gb_audio_manager_get_module()
since there are no in-tree callers (per Greg KH).
- No functional changes otherwise.
Thanks for the review.
Signed-off-by: Hardik Phalet <hardik.phalet(a)pm.me>
Hardik Phalet (2):
staging: greybus: audio: remove unused gb_audio_manager_get_module()
staging: greybus: audio: drop stale TODO comment
drivers/staging/greybus/audio_manager.c | 12 ------------
drivers/staging/greybus/audio_manager.h | 7 -------
drivers/staging/greybus/audio_manager_module.c | 1 -
3 files changed, 20 deletions(-)
--
2.53.0
Thank you for the honest feedback. I'm a new contributor and I was
trying to resolve the checkpatch.pl CHECKs to get familiar with the
process, but I see now that vague documentation can be worse than none
at all.
I'll withdraw this patch. Since I'm looking to make my first meaningful
contribution to staging, do you have any suggestions on what types of
issues in Greybus are actually helpful for a beginner to tackle?
regards, jose
Add a comment to the mutex definition in struct gb_camera to
describe what it protects, satisfying a checkpatch.pl CHECK.
Signed-off-by: Jose A. Perez de Azpillaga <azpijr(a)gmail.com>
---
Hi,
I noticed a CHECK for alignment in this file on line 267. However,
fixing it pushed the line over 100 characters. I felt that adding
extreme indentation might add more noise than value, so I've only
included the mutex comment fix here.
I'd appreciate your guidance on whether you prefer strict alignment
even if it breaks the 100-column rule in these specific cases.
---
drivers/staging/greybus/camera.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/greybus/camera.c b/drivers/staging/greybus/camera.c
index 62b55bb28408..a6f3637b8871 100644
--- a/drivers/staging/greybus/camera.c
+++ b/drivers/staging/greybus/camera.c
@@ -53,7 +53,7 @@ struct gb_camera {
struct gb_connection *data_connection;
u16 data_cport_id;
- struct mutex mutex;
+ struct mutex mutex; /* Protects camera state */
enum gb_camera_state state;
struct {
--
2.53.0