Skip to contentSkip to conversation

drm/msm/dp: add displayPort driver support

PATCH Superseded Tanmay Shah 2 participants 2 messages Jun 9, 2020

Subsystems (2)

v6 of 12 Superseded Latest is v12 →

lore
Share & tools
lore
#0 lore raw

PATCH v6 3/5 drm/msm/dp: add displayPort driver support

From: Chandan Uddaraju <[email protected]>

Add the needed displayPort files to enable DP driver on msm target.

"dp_display" module is the main module that calls into other sub-modules. "dp_drm" file represents the interface between DRM framework and DP driver.

changes in v2:
-- Update copyright markings on all relevant files.
-- Change pr_err() to DRM_ERROR()
-- Use APIs directly instead of function pointers.
-- Use drm_display_mode structure to store link parameters. -- Use macros for register definitions instead of hardcoded values. -- Replace writel_relaxed/readl_relaxed with writel/readl
and remove memory barriers.
-- Remove unnecessary NULL checks.
-- Use drm helper functions for dpcd read/write.
-- Use DRM_DEBUG_DP for debug msgs.

changes in V3:
-- Removed changes in dpu_io_util.[ch]
-- Added locking around "is_connected" flag and removed atomic_set() -- Removed the argument validation checks in all the static functions
except initialization functions and few API across msm/dp files.
-- Removed hardcoded values for register reads/writes
-- Removed vreg related generic structures.
-- Added return values where ever necessary.
-- Updated dp_ctrl_on function.
-- Calling the ctrl specific catalog functions directly instead of
function pointers.
-- Added separate change that adds standard value in drm_dp_helper file. -- Added separate change in this list that is used to initialize DP. -- Added change to use drm_dp_get_adjust_request_voltage() function.

changes in V4:
-- Fix mvid, nvid calculation.
-- Shift video timings to align to bottom right. -- Fix register offsets for pixel_m and pixel_n. -- Fix TPG programming sequence.
-- Update DP ack override register to recommended value. -- Added code to log displayport registers.
-- Update aux setup with recommended settings. -- Fix TU calculations for all resolutions.
-- Limit linkrate to HBR2 until HBR3 support is added. -- Update DPCD read sequence.
-- Update code comments in dp_power_init() of V3. -- Remove extcon dependencies.
-- Move drm helper functions locally.

changes in V5:
-- Addressed comments from Jordan.

Changes in v6

-- Access DP as one big register region.
Access DP modules using offsets from one base address derived from dts.
-- Use default value of pixel clock instead of reading from dts. -- Add default value of AUX LUT settings, however, override
them if relative property is defined in dts.
-- Access data-lane property as an array instead of integer
using "data-lanes" name.
-- Remove redundant IO and pinctrl code.
-- Access clock names without _clk suffix
-- Rename pixel clock to stream_pixel
-- Use new API for edid quirks and use new constant name
DP_PHY_TEST_PATTERN.
-- Remove pll references from base driver change

---
 drivers/gpu/drm/msm/Kconfig                        |    8 +
 drivers/gpu/drm/msm/Makefile                       |   12 +
 drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c        |   21 +
 .../gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c   |    8 +
 drivers/gpu/drm/msm/dp/dp_aux.c                    |  530 ++++++
 drivers/gpu/drm/msm/dp/dp_aux.h                    |   35 +
 drivers/gpu/drm/msm/dp/dp_catalog.c                |  999 ++++++++++++
 drivers/gpu/drm/msm/dp/dp_catalog.h                |   86 +
 drivers/gpu/drm/msm/dp/dp_ctrl.c                   | 1709 ++++++++++++++++++++
 drivers/gpu/drm/msm/dp/dp_ctrl.h                   |   35 +
 drivers/gpu/drm/msm/dp/dp_display.c                |  897 ++++++++++
 drivers/gpu/drm/msm/dp/dp_display.h                |   28 +
 drivers/gpu/drm/msm/dp/dp_drm.c                    |  170 ++
 drivers/gpu/drm/msm/dp/dp_drm.h                    |   18 +
 drivers/gpu/drm/msm/dp/dp_hpd.c                    |   69 +
 drivers/gpu/drm/msm/dp/dp_hpd.h                    |   79 +
 drivers/gpu/drm/msm/dp/dp_link.c                   | 1216 ++++++++++++++
 drivers/gpu/drm/msm/dp/dp_link.h                   |  132 ++
 drivers/gpu/drm/msm/dp/dp_panel.c                  |  490 ++++++
 drivers/gpu/drm/msm/dp/dp_panel.h                  |   95 ++
 drivers/gpu/drm/msm/dp/dp_parser.c                 |  417 +++++
 drivers/gpu/drm/msm/dp/dp_parser.h                 |  207 +++
 drivers/gpu/drm/msm/dp/dp_power.c                  |  412 +++++
 drivers/gpu/drm/msm/dp/dp_power.h                  |   46 +
 drivers/gpu/drm/msm/dp/dp_reg.h                    |  489 ++++++
 drivers/gpu/drm/msm/msm_drv.c                      |    2 +
 drivers/gpu/drm/msm/msm_drv.h                      |   53 +-
 27 files changed, 8260 insertions(+), 3 deletions(-)
 create mode 100644 drivers/gpu/drm/msm/dp/dp_aux.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_aux.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_catalog.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_catalog.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_ctrl.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_ctrl.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_display.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_display.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_drm.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_drm.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_hpd.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_hpd.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_link.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_link.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_panel.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_panel.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_parser.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_parser.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_power.c
 create mode 100644 drivers/gpu/drm/msm/dp/dp_power.h
 create mode 100644 drivers/gpu/drm/msm/dp/dp_reg.h
drivers/gpu/drm/msm/Kconfig +8 -0
index 6deaa7d..ea3c4d0 100644
@@ -57,6 +57,14 @@ config DRM_MSM_HDMI_HDCP
 	help
 	  Choose this option to enable HDCP state machine
 
+config DRM_MSM_DP
+	bool "Enable DP support in MSM DRM driver"
+	depends on DRM_MSM
+	help
+	  Compile in support for DP driver in msm drm driver. DP external
+	  display support is enabled through this config option. It can
+	  be primary or secondary display on device.
+
 config DRM_MSM_DSI
 	bool "Enable DSI support in MSM DRM driver"
 	depends on DRM_MSM
drivers/gpu/drm/msm/Makefile +12 -0
index 42f8aae..af868e7 100644
@@ -2,6 +2,7 @@
 ccflags-y := -I $(srctree)/$(src)
 ccflags-y += -I $(srctree)/$(src)/disp/dpu1
 ccflags-$(CONFIG_DRM_MSM_DSI) += -I $(srctree)/$(src)/dsi
+ccflags-$(CONFIG_DRM_MSM_DP) += -I $(srctree)/$(src)/dp
 
 msm-y := \
 	adreno/adreno_device.o \
@@ -99,6 +100,17 @@ msm-$(CONFIG_DEBUG_FS) += adreno/a5xx_debugfs.o
 
 msm-$(CONFIG_DRM_MSM_GPU_STATE)	+= adreno/a6xx_gpu_state.o
 
+msm-$(CONFIG_DRM_MSM_DP)+= dp/dp_aux.o \
+	dp/dp_catalog.o \
+	dp/dp_ctrl.o \
+	dp/dp_display.o \
+	dp/dp_drm.o \
+	dp/dp_hpd.o \
+	dp/dp_link.o \
+	dp/dp_panel.o \
+	dp/dp_parser.o \
+	dp/dp_power.o
+
 msm-$(CONFIG_DRM_FBDEV_EMULATION) += msm_fbdev.o
 msm-$(CONFIG_COMMON_CLK) += disp/mdp4/mdp4_lvds_pll.o
 msm-$(CONFIG_COMMON_CLK) += hdmi/hdmi_pll_8960.o
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c +21 -0
index 63976dc..d796710 100644
@@ -988,6 +988,9 @@ static void dpu_encoder_virt_mode_set(struct drm_encoder *drm_enc,
 
 	trace_dpu_enc_mode_set(DRMID(drm_enc));
 
+	if (drm_enc->encoder_type == DRM_MODE_ENCODER_TMDS && priv->dp)
+		msm_dp_display_mode_set(priv->dp, drm_enc, mode, adj_mode);
+
 	list_for_each_entry(conn_iter, connector_list, head)
 		if (conn_iter->encoder == drm_enc)
 			conn = conn_iter;
@@ -1130,6 +1133,7 @@ static void dpu_encoder_virt_enable(struct drm_encoder *drm_enc)
 {
 	struct dpu_encoder_virt *dpu_enc = NULL;
 	int ret = 0;
+	struct msm_drm_private *priv;
 	struct drm_display_mode *cur_mode = NULL;
 
 	if (!drm_enc) {
@@ -1140,6 +1144,7 @@ static void dpu_encoder_virt_enable(struct drm_encoder *drm_enc)
 
 	mutex_lock(&dpu_enc->enc_lock);
 	cur_mode = &dpu_enc->base.crtc->state->adjusted_mode;
+	priv = drm_enc->dev->dev_private;
 
 	trace_dpu_enc_enable(DRMID(drm_enc), cur_mode->hdisplay,
 			     cur_mode->vdisplay);
@@ -1160,6 +1165,15 @@ static void dpu_encoder_virt_enable(struct drm_encoder *drm_enc)
 
 	_dpu_encoder_virt_enable_helper(drm_enc);
 
+	if (drm_enc->encoder_type == DRM_MODE_ENCODER_TMDS && priv->dp) {
+		ret = msm_dp_display_enable(priv->dp,
+						drm_enc);
+		if (ret) {
+			DPU_ERROR_ENC(dpu_enc, "dp display enable failed: %d\n",
+				ret);
+			goto out;
+		}
+	}
 	dpu_enc->enabled = true;
 
 out:
@@ -1192,6 +1206,13 @@ static void dpu_encoder_virt_disable(struct drm_encoder *drm_enc)
 	dpu_kms = to_dpu_kms(priv->kms);
 	global_state = dpu_kms_get_existing_global_state(dpu_kms);
 
+	if (drm_enc->encoder_type == DRM_MODE_ENCODER_TMDS && priv->dp) {
+		if (msm_dp_display_disable(priv->dp, drm_enc)) {
+			DPU_ERROR_ENC(dpu_enc, "dp display disable failed\n");
+			return;
+		}
+	}
+
 	trace_dpu_enc_disable(DRMID(drm_enc));
 
 	/* wait for idle */
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c +8 -0
index b5a4905..be11a0c 100644
@@ -100,6 +100,14 @@ static void drm_mode_to_intf_timing_params(
 	 * display_v_end -= mode->hsync_start - mode->hdisplay;
 	 * }
 	 */
+	/* for DP/EDP, Shift timings to align it to bottom right */
+	if ((phys_enc->hw_intf->cap->type == INTF_DP) ||
+		(phys_enc->hw_intf->cap->type == INTF_EDP)) {
+		timing->h_back_porch += timing->h_front_porch;
+		timing->h_front_porch = 0;
+		timing->v_back_porch += timing->v_front_porch;
+		timing->v_front_porch = 0;
+	}
 }
 
 static u32 get_horizontal_total(const struct intf_timing_params *timing)
drivers/gpu/drm/msm/dp/dp_aux.c new file +530 -0

530 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_aux.h new file +35 -0
new file mode 100644
index 0000000..18f560b
@@ -0,0 +1,35 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+/*
+ * Copyright (c) 2012-2020, The Linux Foundation. All rights reserved.
+ */
+
+#ifndef _DP_AUX_H_
+#define _DP_AUX_H_
+
+#include "dp_catalog.h"
+#include <drm/drm_dp_helper.h>
+
+#define DP_AUX_ERR_NONE		0
+#define DP_AUX_ERR_ADDR		-1
+#define DP_AUX_ERR_TOUT		-2
+#define DP_AUX_ERR_NACK		-3
+#define DP_AUX_ERR_DEFER	-4
+#define DP_AUX_ERR_NACK_DEFER	-5
+
+struct dp_aux {
+	struct drm_dp_aux *drm_aux;
+	struct dp_aux_cfg *cfg;
+};
+
+int dp_aux_register(struct dp_aux *aux);
+void dp_aux_unregister(struct dp_aux *aux);
+void dp_aux_isr(struct dp_aux *aux);
+void dp_aux_init(struct dp_aux *aux, struct dp_aux_cfg *aux_cfg);
+void dp_aux_deinit(struct dp_aux *aux);
+void dp_aux_reconfig(struct dp_aux *aux);
+
+struct dp_aux *dp_aux_get(struct device *dev, struct dp_catalog *catalog,
+			  struct dp_aux_cfg *aux_cfg);
+void dp_aux_put(struct dp_aux *aux);
+
+#endif /*__DP_AUX_H_*/
drivers/gpu/drm/msm/dp/dp_catalog.c new file +999 -0

999 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_catalog.h new file +86 -0

86 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_ctrl.c new file +1709 -0

1,247 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_ctrl.h new file +35 -0
new file mode 100644
index 0000000..63681e82

Lines of this file are not shown. View the raw message.

drivers/gpu/drm/msm/dp/dp_display.c new file +897 -0

897 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_display.h new file +28 -0
new file mode 100644
index 0000000..dad8610

Lines of this file are not shown. View the raw message.

drivers/gpu/drm/msm/dp/dp_drm.c new file +170 -0

170 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_drm.h new file +18 -0
new file mode 100644
index 0000000..c27bfce

Lines of this file are not shown. View the raw message.

drivers/gpu/drm/msm/dp/dp_hpd.c new file +69 -0

69 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_hpd.h new file +79 -0

79 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_link.c new file +1216 -0

1,216 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_link.h new file +132 -0

132 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_panel.c new file +490 -0

490 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_panel.h new file +95 -0

95 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_parser.c new file +417 -0

417 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_parser.h new file +207 -0

207 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_power.c new file +412 -0

412 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_power.h new file +46 -0

46 lines not on this page · raw message

drivers/gpu/drm/msm/dp/dp_reg.h new file +489 -0

489 lines not on this page · raw message

drivers/gpu/drm/msm/msm_drv.c +2 -0
index f6ce40b..266de1d 100644

Lines of this file are not shown. View the raw message.

drivers/gpu/drm/msm/msm_drv.h +50 -3

53 lines not on this page · raw message

The rest of this diff is not shown. View the raw message.

Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project

Part of the diff is not shown here. View the raw message.

#1 lore raw
Thank you for the patch! Perhaps something to improve:

Hi Tanmay,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on robh/for-next]
[also build test WARNING on drm-intel/for-linux-next linus/master v5.7 next-20200608] [cannot apply to robclark/msm-next]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Tanmay-Shah/dt-bindings-msm-dp-add-bindings-of-DP-DP-PLL-driver-for-Snapdragon/20200609-115137
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm-allyesconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0

reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm

If you fix the issue, kindly add following tag as appropriate

All warnings (new ones prefixed by >>, old ones prefixed by <<):

>> drivers/gpu/drm/msm/dp/dp_aux.c:35:8: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]
35 | static const char * const dp_aux_get_error(u32 aux_error)
|        ^~~~~
--
>> drivers/gpu/drm/msm/dp/dp_catalog.c:352:6: warning: no previous prototype for 'dump_regs' [-Wmissing-prototypes]

352 | void dump_regs(void * __iomem *base, int len)
| ^~~~~~~~~
In file included from include/linux/printk.h:7, from include/linux/kernel.h:15,
from include/linux/delay.h:22,
from drivers/gpu/drm/msm/dp/dp_catalog.c:8:
drivers/gpu/drm/msm/dp/dp_catalog.c: In function 'dump_regs':

>> include/linux/kern_levels.h:5:18: warning: format '%x' expects argument of type 'unsigned int', but argument 3 has type 'void **' [-Wformat=]

5 | #define KERN_SOH "001" /* ASCII Start Of Header */
| ^~~~~~
include/linux/kern_levels.h:14:19: note: in expansion of macro 'KERN_SOH' 14 | #define KERN_INFO KERN_SOH "6" /* informational */
| ^~~~~~~~
include/linux/printk.h:305:9: note: in expansion of macro 'KERN_INFO' 305 | printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~

>> drivers/gpu/drm/msm/dp/dp_catalog.c:364:3: note: in expansion of macro 'pr_info'

364 | pr_info("%08x: %08x %08x %08x %08x", base, x0, x4, x8, xc);
| ^~~~~~~
drivers/gpu/drm/msm/dp/dp_catalog.c:364:15: note: format string is defined here
364 | pr_info("%08x: %08x %08x %08x %08x", base, x0, x4, x8, xc);

|            ~~~^
|               |
|               unsigned int

At top level:
drivers/gpu/drm/msm/dp/dp_catalog.c:76:17: warning: 'vm_voltage_swing_hbr3_hbr2' defined but not used [-Wunused-const-variable=] 76 | static u8 const vm_voltage_swing_hbr3_hbr2[4][4] = {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/dp/dp_catalog.c:69:17: warning: 'vm_pre_emphasis_hbr3_hbr2' defined but not used [-Wunused-const-variable=] 69 | static u8 const vm_pre_emphasis_hbr3_hbr2[4][4] = {
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/dp/dp_catalog.c:62:17: warning: 'vm_voltage_swing' defined but not used [-Wunused-const-variable=] 62 | static u8 const vm_voltage_swing[4][4] = {
| ^~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/dp/dp_catalog.c:54:17: warning: 'vm_pre_emphasis' defined but not used [-Wunused-const-variable=] 54 | static u8 const vm_pre_emphasis[4][4] = {
| ^~~~~~~~~~~~~~~
--
drivers/gpu/drm/msm/dp/dp_ctrl.c: In function '_tu_param_compare':

>> drivers/gpu/drm/msm/dp/dp_ctrl.c:254:13: warning: variable 'b_frac' set but not used [-Wunused-but-set-variable]
254 |  u32 b_int, b_frac, b_sign;
|             ^~~~~~
>> drivers/gpu/drm/msm/dp/dp_ctrl.c:254:6: warning: variable 'b_int' set but not used [-Wunused-but-set-variable]
254 |  u32 b_int, b_frac, b_sign;
|      ^~~~~
>> drivers/gpu/drm/msm/dp/dp_ctrl.c:253:13: warning: variable 'a_frac' set but not used [-Wunused-but-set-variable]
253 |  u32 a_int, a_frac, a_sign;
|             ^~~~~~
>> drivers/gpu/drm/msm/dp/dp_ctrl.c:253:6: warning: variable 'a_int' set but not used [-Wunused-but-set-variable]
253 |  u32 a_int, a_frac, a_sign;
|      ^~~~~
drivers/gpu/drm/msm/dp/dp_ctrl.c: In function 'dp_panel_update_tu_timings':
>> drivers/gpu/drm/msm/dp/dp_ctrl.c:301:6: warning: variable 'overhead_dsc' set but not used [-Wunused-but-set-variable]

301 | s64 overhead_dsc;
| ^~~~~~~~~~~~
--
drivers/gpu/drm/msm/dp/dp_link.c: In function 'dp_link_parse_phy_test_params':
drivers/gpu/drm/msm/dp/dp_link.c:576:47: error: 'DP_PHY_TEST_PATTERN' undeclared (first use in this function); did you mean 'DP_NO_TEST_PATTERN'? 576 | rlen = drm_dp_dpcd_readb(link->aux->drm_aux, DP_PHY_TEST_PATTERN,

|                                               ^~~~~~~~~~~~~~~~~~~
|                                               DP_NO_TEST_PATTERN
drivers/gpu/drm/msm/dp/dp_link.c:576:47: note: each undeclared identifier is reported only once for each function it appears in
drivers/gpu/drm/msm/dp/dp_link.c: In function 'dp_link_adjust_levels':
>> drivers/gpu/drm/msm/dp/dp_link.c:1106:26: warning: variable 'link' set but not used [-Wunused-but-set-variable]

1106 | struct dp_link_private *link;
| ^~~~
--
drivers/gpu/drm/msm/dp/dp_panel.c: In function 'dp_panel_read_dpcd':

>> drivers/gpu/drm/msm/dp/dp_panel.c:39:11: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits]
39 |  if (rlen < 0) {
|           ^
drivers/gpu/drm/msm/dp/dp_panel.c: At top level:
>> drivers/gpu/drm/msm/dp/dp_panel.c:283:4: warning: no previous prototype for 'dp_panel_get_edid_checksum' [-Wmissing-prototypes]
283 | u8 dp_panel_get_edid_checksum(struct edid *edid)
|    ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/msm/dp/dp_panel.c: In function 'dp_panel_put':
>> drivers/gpu/drm/msm/dp/dp_panel.c:482:27: warning: variable 'panel' set but not used [-Wunused-but-set-variable]

482 | struct dp_panel_private *panel;
| ^~~~~
--
drivers/gpu/drm/msm/dp/dp_parser.c: In function 'dp_parser_init_clk_data':

>> drivers/gpu/drm/msm/dp/dp_parser.c:251:26: warning: variable 'rc' set but not used [-Wunused-but-set-variable]

251 | int num_clk = 0, i = 0, rc = 0;
| ^~
--
drivers/gpu/drm/msm/dp/dp_power.c: In function 'dp_power_clk_enable':

>> drivers/gpu/drm/msm/dp/dp_power.c:172:27: warning: variable 'mp' set but not used [-Wunused-but-set-variable]

172 | struct dss_module_power *mp;
| ^~

vim +35 drivers/gpu/drm/msm/dp/dp_aux.c

    34	
  > 35	static const char * const dp_aux_get_error(u32 aux_error)
    36	{
    37		switch (aux_error) {
    38		case DP_AUX_ERR_NONE:
    39			return DP_AUX_ENUM_STR(DP_AUX_ERR_NONE);
    40		case DP_AUX_ERR_ADDR:
    41			return DP_AUX_ENUM_STR(DP_AUX_ERR_ADDR);
    42		case DP_AUX_ERR_TOUT:
    43			return DP_AUX_ENUM_STR(DP_AUX_ERR_TOUT);
    44		case DP_AUX_ERR_NACK:
    45			return DP_AUX_ENUM_STR(DP_AUX_ERR_NACK);
    46		case DP_AUX_ERR_DEFER:
    47			return DP_AUX_ENUM_STR(DP_AUX_ERR_DEFER);
    48		case DP_AUX_ERR_NACK_DEFER:
    49			return DP_AUX_ENUM_STR(DP_AUX_ERR_NACK_DEFER);
    50		default:
    51			return "unknown";
    52		}
    53	}
    54	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org