On Wed May 6 19:54:38 2026 +0300, Laurent Pinchart wrote:
> The media_entity_cleanup() function is defined in media-entity.h as a
> static inline no-op when CONFIG_MEDIA_CONTROLLER is enabled, and as a
> no-op macro otherwise. This complexity is unneeded. Use a static inline
> function in all cases.
>
> Reviewed-by: Jacopo Mondi <[email protected]>
> Link:
> https://patch.msgid.link/[email protected]
> Signed-off-by: Laurent Pinchart <[email protected]>
> Signed-off-by: Hans Verkuil <[email protected]>
Patch committed.
Thanks,
Hans Verkuil
include/media/media-entity.h | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
---
diff --git a/include/media/media-entity.h b/include/media/media-entity.h
index 904f61c14dc1..d9b72cd87d52 100644
--- a/include/media/media-entity.h
+++ b/include/media/media-entity.h
@@ -729,11 +729,9 @@ int media_entity_pads_init(struct media_entity *entity,
u16 num_pads,
* zeroed but that has not been initialized with media_entity_pads_init() is
* valid and is a no-op.
*/
-#if IS_ENABLED(CONFIG_MEDIA_CONTROLLER)
-static inline void media_entity_cleanup(struct media_entity *entity) {}
-#else
-#define media_entity_cleanup(entity) do { } while (false)
-#endif
+static inline void media_entity_cleanup(struct media_entity *entity)
+{
+}
/**
* media_get_pad_index() - retrieves a pad index from an entity
_______________________________________________
linuxtv-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]