Skip to content

Commit a99076e

Browse files
committed
drm/client: Change drm_client_panel_rotation name
The drm_client_panel_rotation function has been used so far to set the default rotation based on the panel orientation. However, we can have more sources of information to make that decision, starting with the command line that we will introduce later in this series. Change the name to remove the panel mention. Reviewed-by: Noralf Trønnes <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/8cb0f0d9569d41685bbf30a1538da6578cd2769b.1560783090.git-series.maxime.ripard@bootlin.com
1 parent 307696d commit a99076e

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

drivers/gpu/drm/drm_client_modeset.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -804,19 +804,19 @@ int drm_client_modeset_probe(struct drm_client_dev *client, unsigned int width,
804804
EXPORT_SYMBOL(drm_client_modeset_probe);
805805

806806
/**
807-
* drm_client_panel_rotation() - Check panel orientation
807+
* drm_client_rotation() - Check the initial rotation value
808808
* @modeset: DRM modeset
809809
* @rotation: Returned rotation value
810810
*
811-
* This function checks if the primary plane in @modeset can hw rotate to match
812-
* the panel orientation on its connector.
811+
* This function checks if the primary plane in @modeset can hw rotate
812+
* to match the rotation needed on its connector.
813813
*
814814
* Note: Currently only 0 and 180 degrees are supported.
815815
*
816816
* Return:
817817
* True if the plane can do the rotation, false otherwise.
818818
*/
819-
bool drm_client_panel_rotation(struct drm_mode_set *modeset, unsigned int *rotation)
819+
bool drm_client_rotation(struct drm_mode_set *modeset, unsigned int *rotation)
820820
{
821821
struct drm_connector *connector = modeset->connectors[0];
822822
struct drm_plane *plane = modeset->crtc->primary;
@@ -857,7 +857,7 @@ bool drm_client_panel_rotation(struct drm_mode_set *modeset, unsigned int *rotat
857857

858858
return true;
859859
}
860-
EXPORT_SYMBOL(drm_client_panel_rotation);
860+
EXPORT_SYMBOL(drm_client_rotation);
861861

862862
static int drm_client_modeset_commit_atomic(struct drm_client_dev *client, bool active)
863863
{
@@ -902,7 +902,7 @@ static int drm_client_modeset_commit_atomic(struct drm_client_dev *client, bool
902902
struct drm_plane *primary = mode_set->crtc->primary;
903903
unsigned int rotation;
904904

905-
if (drm_client_panel_rotation(mode_set, &rotation)) {
905+
if (drm_client_rotation(mode_set, &rotation)) {
906906
struct drm_plane_state *plane_state;
907907

908908
/* Cannot fail as we've already gotten the plane state above */

drivers/gpu/drm/drm_fb_helper.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1722,7 +1722,7 @@ static void drm_setup_crtcs_fb(struct drm_fb_helper *fb_helper)
17221722

17231723
modeset->fb = fb_helper->fb;
17241724

1725-
if (drm_client_panel_rotation(modeset, &rotation))
1725+
if (drm_client_rotation(modeset, &rotation))
17261726
/* Rotating in hardware, fbcon should not rotate */
17271727
sw_rotations |= DRM_MODE_ROTATE_0;
17281728
else

include/drm/drm_client.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ void drm_client_framebuffer_delete(struct drm_client_buffer *buffer);
153153
int drm_client_modeset_create(struct drm_client_dev *client);
154154
void drm_client_modeset_free(struct drm_client_dev *client);
155155
int drm_client_modeset_probe(struct drm_client_dev *client, unsigned int width, unsigned int height);
156-
bool drm_client_panel_rotation(struct drm_mode_set *modeset, unsigned int *rotation);
156+
bool drm_client_rotation(struct drm_mode_set *modeset, unsigned int *rotation);
157157
int drm_client_modeset_commit_force(struct drm_client_dev *client);
158158
int drm_client_modeset_commit(struct drm_client_dev *client);
159159
int drm_client_modeset_dpms(struct drm_client_dev *client, int mode);

0 commit comments

Comments
 (0)