drm/amd/amdgpu_dm/mst: Remove useless sideband tracing
authorLyude Paul <lyude@redhat.com>
Tue, 31 Mar 2020 21:22:23 +0000 (17:22 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 1 Apr 2020 18:44:56 +0000 (14:44 -0400)
We already trace DPCD reads/writes on both MST and SST, there's no
reason to have this code here (plus, toggling these things with a
define at the top of the file isn't how we do things in the kernel).

Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c

index e8208df..7f22930 100644 (file)
 #include "amdgpu_dm_debugfs.h"
 #endif
 
-
 #if defined(CONFIG_DRM_AMD_DC_DCN)
 #include "dc/dcn20/dcn20_resource.h"
 #endif
 
-/* #define TRACE_DPCD */
-
-#ifdef TRACE_DPCD
-#define SIDE_BAND_MSG(address) (address >= DP_SIDEBAND_MSG_DOWN_REQ_BASE && address < DP_SINK_COUNT_ESI)
-
-static inline char *side_band_msg_type_to_str(uint32_t address)
-{
-       static char str[10] = {0};
-
-       if (address < DP_SIDEBAND_MSG_UP_REP_BASE)
-               strcpy(str, "DOWN_REQ");
-       else if (address < DP_SIDEBAND_MSG_DOWN_REP_BASE)
-               strcpy(str, "UP_REP");
-       else if (address < DP_SIDEBAND_MSG_UP_REQ_BASE)
-               strcpy(str, "DOWN_REP");
-       else
-               strcpy(str, "UP_REQ");
-
-       return str;
-}
-
-static void log_dpcd(uint8_t type,
-                    uint32_t address,
-                    uint8_t *data,
-                    uint32_t size,
-                    bool res)
-{
-       DRM_DEBUG_KMS("Op: %s, addr: %04x, SideBand Msg: %s, Op res: %s\n",
-                       (type == DP_AUX_NATIVE_READ) ||
-                       (type == DP_AUX_I2C_READ) ?
-                                       "Read" : "Write",
-                       address,
-                       SIDE_BAND_MSG(address) ?
-                                       side_band_msg_type_to_str(address) : "Nop",
-                       res ? "OK" : "Fail");
-
-       if (res) {
-               print_hex_dump(KERN_INFO, "Body: ", DUMP_PREFIX_NONE, 16, 1, data, size, false);
-       }
-}
-#endif
-
 static ssize_t dm_dp_aux_transfer(struct drm_dp_aux *aux,
                                  struct drm_dp_aux_msg *msg)
 {