* [PATCH] media: atomisp: Remove redundant return statements
@ 2026-10-30 19:33 Avishek Chaulagain
2026-10-31 8:40 ` Andy Shevchenko
0 siblings, 1 reply; 2+ messages in thread
From: Avishek Chaulagain @ 2026-10-30 19:33 UTC (permalink / raw)
To: hansg, mchehab
Cc: sakari.ailus, andy, gregkh, linux-media, linux-staging,
linux-kernel, Avishek Chaulagain
A return statement at the end of a void function is redundant; control
returns to the caller once the closing brace is reached. Remove the two
such 'return;' statements in hmm_bo_release() and hmm_bo_vunmap(), as
reported by checkpatch.pl.
Signed-off-by: Avishek Chaulagain <chaulagainavishek14@gmail.com>
---
drivers/staging/media/atomisp/pci/hmm/hmm_bo.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/hmm/hmm_bo.c b/drivers/staging/media/atomisp/pci/hmm/hmm_bo.c
index 0a8f401a1..4ceb8cb41 100644
--- a/drivers/staging/media/atomisp/pci/hmm/hmm_bo.c
+++ b/drivers/staging/media/atomisp/pci/hmm/hmm_bo.c
@@ -483,7 +483,6 @@ void hmm_bo_release(struct hmm_buffer_object *bo)
__bo_insert_to_free_rbtree(&bdev->free_rbtree, bo);
mutex_unlock(&bdev->rbtree_mutex);
- return;
}
void hmm_bo_device_exit(struct hmm_bo_device *bdev)
@@ -957,7 +956,6 @@ void hmm_bo_vunmap(struct hmm_buffer_object *bo)
}
mutex_unlock(&bo->mutex);
- return;
}
void hmm_bo_ref(struct hmm_buffer_object *bo)
--
2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] media: atomisp: Remove redundant return statements
2026-10-30 19:33 [PATCH] media: atomisp: Remove redundant return statements Avishek Chaulagain
@ 2026-10-31 8:40 ` Andy Shevchenko
0 siblings, 0 replies; 2+ messages in thread
From: Andy Shevchenko @ 2026-10-31 8:40 UTC (permalink / raw)
To: Avishek Chaulagain
Cc: hansg, mchehab, sakari.ailus, andy, gregkh, linux-media,
linux-staging, linux-kernel
On Fri, Oct 30, 2026 at 07:33:04PM +0000, Avishek Chaulagain wrote:
> A return statement at the end of a void function is redundant; control
> returns to the caller once the closing brace is reached. Remove the two
> such 'return;' statements in hmm_bo_release() and hmm_bo_vunmap(), as
> reported by checkpatch.pl.
Usually we expect deeper cleanups for this driver, see [1] for the best
(so far) example how somebody can help with it without having deep knowledge
on the particular hardware.
This type of change has been appeared many times in the mailing list, you
can study the case why it's still not in the upstream.
[1]: https://lore.kernel.org/linux-media/20261027230807.2407261-1-vladurares@gmail.com/
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-10-31 8:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-30 19:33 [PATCH] media: atomisp: Remove redundant return statements Avishek Chaulagain
2026-10-31 8:40 ` Andy Shevchenko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®