drm: bridge: Mark deprecated operations in drm_bridge_funcs
Subsystems (3)
PATCH 1/1 drm: bridge: Mark deprecated operations in drm_bridge_funcs
drm_bridge_funcs includes several duplicated operations as atomic variants has been added over time.
New bridge drivers shall use the atomic variants - mark the deprecated operations to try to avoid usage in new bridge drivers.
--- include/drm/drm_bridge.h | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-)
include/drm/drm_bridge.h +26 -2
@@ -171,6 +171,11 @@ struct drm_bridge_funcs {* signals) feeding it is still running when this callback is called. * * The @disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_disable. */ void (*disable)(struct drm_bridge *bridge);
@@ -190,6 +195,11 @@ struct drm_bridge_funcs {* called. * * The @post_disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_post_disable. */ void (*post_disable)(struct drm_bridge *bridge);
@@ -213,11 +223,15 @@ struct drm_bridge_funcs {* For atomic drivers the adjusted_mode is the mode stored in * &drm_crtc_state.adjusted_mode. * -* NOTE: -* * If a need arises to store and access modes adjusted for other * locations than the connection between the CRTC and the first bridge, * the DRM framework will have to be extended with DRM bridge states. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall set their mode in &drm_bridge_funcs.atomic_enable +* operation. */ void (*mode_set)(struct drm_bridge *bridge, const struct drm_display_mode *mode,
@@ -239,6 +253,11 @@ struct drm_bridge_funcs {* there is one) when this callback is called. * * The @pre_enable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_pre_enable. */ void (*pre_enable)(struct drm_bridge *bridge);
@@ -259,6 +278,11 @@ struct drm_bridge_funcs {* chain if there is one. * * The @enable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_enable. */ void (*enable)(struct drm_bridge *bridge);
Signature · 1 line
2.30.2
Quoted 5 lines · Sam Ravnborg
drm_bridge_funcsincludes several duplicated operations as atomic variants has been added over time.
New bridge drivers shall use the atomic variants - mark the deprecated operations to try to avoid usage in new bridge drivers.
Quoted 8 lines
Signed-off-by Sam Ravnborg <[email protected]>Cc Laurent Pinchart <[email protected]>Cc Andrzej Hajda <[email protected]>Cc Maarten Lankhorst <[email protected]>Cc Maxime Ripard <[email protected]>Cc Thomas Zimmermann <[email protected]>Cc David Airlie <[email protected]>Cc Daniel Vetter <[email protected]>
Thanks!
Maxime
Hi Sam,
Thank you for the patch.
Quoted 2 lines · Sam Ravnborg
drm_bridge_funcsincludes several duplicated operations as atomic variants has been added over time.
s/has/have/
Quoted 44 lines
New bridge drivers shall use the atomic variants - mark the deprecated operations to try to avoid usage in new bridge drivers.
Signed-off-by Sam Ravnborg <[email protected]>Cc Laurent Pinchart <[email protected]>Cc Andrzej Hajda <[email protected]>Cc Maarten Lankhorst <[email protected]>Cc Maxime Ripard <[email protected]>Cc Thomas Zimmermann <[email protected]>Cc David Airlie <[email protected]>Cc Daniel Vetter <[email protected]>--- include/drm/drm_bridge.h | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-)include/drm/drm_bridge.h +10
-0@@ -171,6 +171,11 @@ struct drm_bridge_funcs {* signals) feeding it is still running when this callback is called. * * The @disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_disable. */ void (*disable)(struct drm_bridge *bridge);@@ -190,6 +195,11 @@ struct drm_bridge_funcs {* called. * * The @post_disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_post_disable. */ void (*post_disable)(struct drm_bridge *bridge);
include/drm/drm_bridge.h struct drm_bridge_funcs { · line 228
Quoted 8 lines
include/drm/drm_bridge.h +0
-2@@ -213,11 +223,15 @@ struct drm_bridge_funcs {* For atomic drivers the adjusted_mode is the mode stored in * &drm_crtc_state.adjusted_mode. * -* NOTE: -* * If a need arises to store and access modes adjusted for other * locations than the connection between the CRTC and the first bridge, * the DRM framework will have to be extended with DRM bridge states.
The DRM framework *has* been extended with DRM bridge states :-) Should this be dropped ?
Quoted 33 lines
include/drm/drm_bridge.h +16
-0+* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall set their mode in &drm_bridge_funcs.atomic_enable +* operation. */ void (*mode_set)(struct drm_bridge *bridge, const struct drm_display_mode *mode,@@ -239,6 +253,11 @@ struct drm_bridge_funcs {* there is one) when this callback is called. * * The @pre_enable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_pre_enable. */ void (*pre_enable)(struct drm_bridge *bridge);@@ -259,6 +278,11 @@ struct drm_bridge_funcs {* chain if there is one. * * The @enable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_enable. */ void (*enable)(struct drm_bridge *bridge);
Signature · 3 lines
Regards, Laurent Pinchart
Hi Laurent,
Quoted 53 lines · Laurent Pinchart
Hi Sam,
Thank you for the patch.
Quoted 2 lines · Sam Ravnborg
drm_bridge_funcsincludes several duplicated operations as atomic variants has been added over time.s/has/have/
Quoted 43 lines
New bridge drivers shall use the atomic variants - mark the deprecated operations to try to avoid usage in new bridge drivers.
Signed-off-by Sam Ravnborg <[email protected]>Cc Laurent Pinchart <[email protected]>Cc Andrzej Hajda <[email protected]>Cc Maarten Lankhorst <[email protected]>Cc Maxime Ripard <[email protected]>Cc Thomas Zimmermann <[email protected]>Cc David Airlie <[email protected]>Cc Daniel Vetter <[email protected]>--- include/drm/drm_bridge.h | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-)include/drm/drm_bridge.h +10
-0@@ -171,6 +171,11 @@ struct drm_bridge_funcs {* signals) feeding it is still running when this callback is called. * * The @disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_disable. */ void (*disable)(struct drm_bridge *bridge);@@ -190,6 +195,11 @@ struct drm_bridge_funcs {* called. * * The @post_disable callback is optional. +* +* NOTE: +* +* This is deprecated, do not use! +* New drivers shall use &drm_bridge_funcs.atomic_post_disable. */ void (*post_disable)(struct drm_bridge *bridge);
Quoted 12 lines
include/drm/drm_bridge.h struct drm_bridge_funcs { · line 228
Quoted 9 lines
include/drm/drm_bridge.h +0
-2@@ -213,11 +223,15 @@ struct drm_bridge_funcs {* For atomic drivers the adjusted_mode is the mode stored in * &drm_crtc_state.adjusted_mode. * -* NOTE: -* * If a need arises to store and access modes adjusted for other * locations than the connection between the CRTC and the first bridge, * the DRM framework will have to be extended with DRM bridge states. The DRM framework *has* been extended with DRM bridge states :-) Should this be dropped ?
I dropped this while applying.
Quoted 2 lines
Reviewed-by Laurent Pinchart <[email protected]>
Tnanks!
Sam