Merge "disp: msm: dsi: adding prefix for logs"
此提交包含在:
@@ -4,7 +4,6 @@
|
||||
*/
|
||||
|
||||
|
||||
#define pr_fmt(fmt) "dsi-drm:[%s] " fmt, __func__
|
||||
#include <drm/drm_atomic_helper.h>
|
||||
#include <drm/drm_atomic.h>
|
||||
|
||||
@@ -151,11 +150,11 @@ static int dsi_bridge_attach(struct drm_bridge *bridge)
|
||||
struct dsi_bridge *c_bridge = to_dsi_bridge(bridge);
|
||||
|
||||
if (!bridge) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
pr_debug("[%d] attached\n", c_bridge->id);
|
||||
DSI_DEBUG("[%d] attached\n", c_bridge->id);
|
||||
|
||||
return 0;
|
||||
|
||||
@@ -167,12 +166,12 @@ static void dsi_bridge_pre_enable(struct drm_bridge *bridge)
|
||||
struct dsi_bridge *c_bridge = to_dsi_bridge(bridge);
|
||||
|
||||
if (!bridge) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return;
|
||||
}
|
||||
|
||||
if (!c_bridge || !c_bridge->display || !c_bridge->display->panel) {
|
||||
pr_err("Incorrect bridge details\n");
|
||||
DSI_ERR("Incorrect bridge details\n");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -182,7 +181,7 @@ static void dsi_bridge_pre_enable(struct drm_bridge *bridge)
|
||||
rc = dsi_display_set_mode(c_bridge->display,
|
||||
&(c_bridge->dsi_mode), 0x0);
|
||||
if (rc) {
|
||||
pr_err("[%d] failed to perform a mode set, rc=%d\n",
|
||||
DSI_ERR("[%d] failed to perform a mode set, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
return;
|
||||
}
|
||||
@@ -190,14 +189,14 @@ static void dsi_bridge_pre_enable(struct drm_bridge *bridge)
|
||||
if (c_bridge->dsi_mode.dsi_mode_flags &
|
||||
(DSI_MODE_FLAG_SEAMLESS | DSI_MODE_FLAG_VRR |
|
||||
DSI_MODE_FLAG_DYN_CLK)) {
|
||||
pr_debug("[%d] seamless pre-enable\n", c_bridge->id);
|
||||
DSI_DEBUG("[%d] seamless pre-enable\n", c_bridge->id);
|
||||
return;
|
||||
}
|
||||
|
||||
SDE_ATRACE_BEGIN("dsi_display_prepare");
|
||||
rc = dsi_display_prepare(c_bridge->display);
|
||||
if (rc) {
|
||||
pr_err("[%d] DSI display prepare failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display prepare failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
SDE_ATRACE_END("dsi_display_prepare");
|
||||
return;
|
||||
@@ -207,7 +206,7 @@ static void dsi_bridge_pre_enable(struct drm_bridge *bridge)
|
||||
SDE_ATRACE_BEGIN("dsi_display_enable");
|
||||
rc = dsi_display_enable(c_bridge->display);
|
||||
if (rc) {
|
||||
pr_err("[%d] DSI display enable failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display enable failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
(void)dsi_display_unprepare(c_bridge->display);
|
||||
}
|
||||
@@ -215,7 +214,7 @@ static void dsi_bridge_pre_enable(struct drm_bridge *bridge)
|
||||
|
||||
rc = dsi_display_splash_res_cleanup(c_bridge->display);
|
||||
if (rc)
|
||||
pr_err("Continuous splash pipeline cleanup failed, rc=%d\n",
|
||||
DSI_ERR("Continuous splash pipeline cleanup failed, rc=%d\n",
|
||||
rc);
|
||||
}
|
||||
|
||||
@@ -226,21 +225,21 @@ static void dsi_bridge_enable(struct drm_bridge *bridge)
|
||||
struct dsi_display *display;
|
||||
|
||||
if (!bridge) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return;
|
||||
}
|
||||
|
||||
if (c_bridge->dsi_mode.dsi_mode_flags &
|
||||
(DSI_MODE_FLAG_SEAMLESS | DSI_MODE_FLAG_VRR |
|
||||
DSI_MODE_FLAG_DYN_CLK)) {
|
||||
pr_debug("[%d] seamless enable\n", c_bridge->id);
|
||||
DSI_DEBUG("[%d] seamless enable\n", c_bridge->id);
|
||||
return;
|
||||
}
|
||||
display = c_bridge->display;
|
||||
|
||||
rc = dsi_display_post_enable(display);
|
||||
if (rc)
|
||||
pr_err("[%d] DSI display post enabled failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display post enabled failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
|
||||
if (display && display->drm_conn)
|
||||
@@ -254,7 +253,7 @@ static void dsi_bridge_disable(struct drm_bridge *bridge)
|
||||
struct dsi_bridge *c_bridge = to_dsi_bridge(bridge);
|
||||
|
||||
if (!bridge) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return;
|
||||
}
|
||||
display = c_bridge->display;
|
||||
@@ -274,7 +273,7 @@ static void dsi_bridge_disable(struct drm_bridge *bridge)
|
||||
|
||||
rc = dsi_display_pre_disable(c_bridge->display);
|
||||
if (rc) {
|
||||
pr_err("[%d] DSI display pre disable failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display pre disable failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
}
|
||||
}
|
||||
@@ -285,7 +284,7 @@ static void dsi_bridge_post_disable(struct drm_bridge *bridge)
|
||||
struct dsi_bridge *c_bridge = to_dsi_bridge(bridge);
|
||||
|
||||
if (!bridge) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -293,7 +292,7 @@ static void dsi_bridge_post_disable(struct drm_bridge *bridge)
|
||||
SDE_ATRACE_BEGIN("dsi_display_disable");
|
||||
rc = dsi_display_disable(c_bridge->display);
|
||||
if (rc) {
|
||||
pr_err("[%d] DSI display disable failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display disable failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
SDE_ATRACE_END("dsi_display_disable");
|
||||
return;
|
||||
@@ -302,7 +301,7 @@ static void dsi_bridge_post_disable(struct drm_bridge *bridge)
|
||||
|
||||
rc = dsi_display_unprepare(c_bridge->display);
|
||||
if (rc) {
|
||||
pr_err("[%d] DSI display unprepare failed, rc=%d\n",
|
||||
DSI_ERR("[%d] DSI display unprepare failed, rc=%d\n",
|
||||
c_bridge->id, rc);
|
||||
SDE_ATRACE_END("dsi_bridge_post_disable");
|
||||
return;
|
||||
@@ -317,7 +316,7 @@ static void dsi_bridge_mode_set(struct drm_bridge *bridge,
|
||||
struct dsi_bridge *c_bridge = to_dsi_bridge(bridge);
|
||||
|
||||
if (!bridge || !mode || !adjusted_mode) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -328,7 +327,7 @@ static void dsi_bridge_mode_set(struct drm_bridge *bridge,
|
||||
c_bridge->dsi_mode.timing.clk_rate_hz =
|
||||
dsi_drm_find_bit_clk_rate(c_bridge->display, adjusted_mode);
|
||||
|
||||
pr_debug("clk_rate: %llu\n", c_bridge->dsi_mode.timing.clk_rate_hz);
|
||||
DSI_DEBUG("clk_rate: %llu\n", c_bridge->dsi_mode.timing.clk_rate_hz);
|
||||
}
|
||||
|
||||
static bool dsi_bridge_mode_fixup(struct drm_bridge *bridge,
|
||||
@@ -345,13 +344,13 @@ static bool dsi_bridge_mode_fixup(struct drm_bridge *bridge,
|
||||
crtc_state = container_of(mode, struct drm_crtc_state, mode);
|
||||
|
||||
if (!bridge || !mode || !adjusted_mode) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
display = c_bridge->display;
|
||||
if (!display) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -385,7 +384,7 @@ static bool dsi_bridge_mode_fixup(struct drm_bridge *bridge,
|
||||
rc = dsi_display_validate_mode(c_bridge->display, &dsi_mode,
|
||||
DSI_VALIDATE_FLAG_ALLOW_ADJUST);
|
||||
if (rc) {
|
||||
pr_err("[%d] mode is not valid, rc=%d\n", c_bridge->id, rc);
|
||||
DSI_ERR("[%d] mode is not valid, rc=%d\n", c_bridge->id, rc);
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -400,7 +399,7 @@ static bool dsi_bridge_mode_fixup(struct drm_bridge *bridge,
|
||||
rc = dsi_display_validate_mode_change(c_bridge->display,
|
||||
&cur_dsi_mode, &dsi_mode);
|
||||
if (rc) {
|
||||
pr_err("[%s] seamless mode mismatch failure rc=%d\n",
|
||||
DSI_ERR("[%s] seamless mode mismatch failure rc=%d\n",
|
||||
c_bridge->display->name, rc);
|
||||
return false;
|
||||
}
|
||||
@@ -547,12 +546,12 @@ int dsi_conn_set_info_blob(struct drm_connector *connector,
|
||||
"split ext bridge");
|
||||
break;
|
||||
default:
|
||||
pr_debug("invalid display type:%d\n", dsi_display->type);
|
||||
DSI_DEBUG("invalid display type:%d\n", dsi_display->type);
|
||||
break;
|
||||
}
|
||||
|
||||
if (!dsi_display->panel) {
|
||||
pr_debug("invalid panel data\n");
|
||||
DSI_DEBUG("invalid panel data\n");
|
||||
goto end;
|
||||
}
|
||||
|
||||
@@ -573,7 +572,7 @@ int dsi_conn_set_info_blob(struct drm_connector *connector,
|
||||
panel->qsync_min_fps ? "true" : "false");
|
||||
break;
|
||||
default:
|
||||
pr_debug("invalid panel type:%d\n", panel->panel_mode);
|
||||
DSI_DEBUG("invalid panel type:%d\n", panel->panel_mode);
|
||||
break;
|
||||
}
|
||||
sde_kms_info_add_keystr(info, "dfps support",
|
||||
@@ -604,7 +603,7 @@ int dsi_conn_set_info_blob(struct drm_connector *connector,
|
||||
"horz & vert flip");
|
||||
break;
|
||||
default:
|
||||
pr_debug("invalid panel rotation:%d\n",
|
||||
DSI_DEBUG("invalid panel rotation:%d\n",
|
||||
panel->phy_props.rotation);
|
||||
break;
|
||||
}
|
||||
@@ -620,7 +619,7 @@ int dsi_conn_set_info_blob(struct drm_connector *connector,
|
||||
sde_kms_info_add_keystr(info, "backlight type", "dcs");
|
||||
break;
|
||||
default:
|
||||
pr_debug("invalid panel backlight type:%d\n",
|
||||
DSI_DEBUG("invalid panel backlight type:%d\n",
|
||||
panel->bl_config.type);
|
||||
break;
|
||||
}
|
||||
@@ -668,7 +667,7 @@ enum drm_connector_status dsi_conn_detect(struct drm_connector *conn,
|
||||
memset(&info, 0x0, sizeof(info));
|
||||
rc = dsi_display_get_info(conn, &info, display);
|
||||
if (rc) {
|
||||
pr_err("failed to get display info, rc=%d\n", rc);
|
||||
DSI_ERR("failed to get display info, rc=%d\n", rc);
|
||||
return connector_status_disconnected;
|
||||
}
|
||||
|
||||
@@ -814,13 +813,13 @@ int dsi_connector_get_modes(struct drm_connector *connector, void *data,
|
||||
|
||||
rc = dsi_display_get_mode_count(display, &count);
|
||||
if (rc) {
|
||||
pr_err("failed to get num of modes, rc=%d\n", rc);
|
||||
DSI_ERR("failed to get num of modes, rc=%d\n", rc);
|
||||
goto end;
|
||||
}
|
||||
|
||||
rc = dsi_display_get_modes(display, &modes);
|
||||
if (rc) {
|
||||
pr_err("failed to get modes, rc=%d\n", rc);
|
||||
DSI_ERR("failed to get modes, rc=%d\n", rc);
|
||||
count = 0;
|
||||
goto end;
|
||||
}
|
||||
@@ -832,7 +831,7 @@ int dsi_connector_get_modes(struct drm_connector *connector, void *data,
|
||||
dsi_convert_to_drm_mode(&modes[i], &drm_mode);
|
||||
m = drm_mode_duplicate(connector->dev, &drm_mode);
|
||||
if (!m) {
|
||||
pr_err("failed to add mode %ux%u\n",
|
||||
DSI_ERR("failed to add mode %ux%u\n",
|
||||
drm_mode.hdisplay,
|
||||
drm_mode.vdisplay);
|
||||
count = -ENOMEM;
|
||||
@@ -861,7 +860,7 @@ int dsi_connector_get_modes(struct drm_connector *connector, void *data,
|
||||
if (rc)
|
||||
count = 0;
|
||||
end:
|
||||
pr_debug("MODE COUNT =%d\n\n", count);
|
||||
DSI_DEBUG("MODE COUNT =%d\n\n", count);
|
||||
return count;
|
||||
}
|
||||
|
||||
@@ -873,7 +872,7 @@ enum drm_mode_status dsi_conn_mode_valid(struct drm_connector *connector,
|
||||
int rc;
|
||||
|
||||
if (!connector || !mode) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return MODE_ERROR;
|
||||
}
|
||||
|
||||
@@ -882,7 +881,7 @@ enum drm_mode_status dsi_conn_mode_valid(struct drm_connector *connector,
|
||||
rc = dsi_display_validate_mode(display, &dsi_mode,
|
||||
DSI_VALIDATE_FLAG_ALLOW_ADJUST);
|
||||
if (rc) {
|
||||
pr_err("mode not supported, rc=%d\n", rc);
|
||||
DSI_ERR("mode not supported, rc=%d\n", rc);
|
||||
return MODE_BAD;
|
||||
}
|
||||
|
||||
@@ -894,7 +893,7 @@ int dsi_conn_pre_kickoff(struct drm_connector *connector,
|
||||
struct msm_display_kickoff_params *params)
|
||||
{
|
||||
if (!connector || !display || !params) {
|
||||
pr_err("Invalid params\n");
|
||||
DSI_ERR("Invalid params\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
@@ -925,13 +924,13 @@ int dsi_conn_post_kickoff(struct drm_connector *connector)
|
||||
int i, rc = 0;
|
||||
|
||||
if (!connector || !connector->state) {
|
||||
pr_err("invalid connector or connector state\n");
|
||||
DSI_ERR("invalid connector or connector state\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
encoder = connector->state->best_encoder;
|
||||
if (!encoder) {
|
||||
pr_debug("best encoder is not available\n");
|
||||
DSI_DEBUG("best encoder is not available\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -943,7 +942,7 @@ int dsi_conn_post_kickoff(struct drm_connector *connector)
|
||||
m_ctrl = &display->ctrl[display->clk_master_idx];
|
||||
rc = dsi_ctrl_timing_db_update(m_ctrl->ctrl, false);
|
||||
if (rc) {
|
||||
pr_err("[%s] failed to dfps update rc=%d\n",
|
||||
DSI_ERR("[%s] failed to dfps update rc=%d\n",
|
||||
display->name, rc);
|
||||
return -EINVAL;
|
||||
}
|
||||
@@ -956,7 +955,7 @@ int dsi_conn_post_kickoff(struct drm_connector *connector)
|
||||
|
||||
rc = dsi_ctrl_timing_db_update(ctrl->ctrl, false);
|
||||
if (rc) {
|
||||
pr_err("[%s] failed to dfps update rc=%d\n",
|
||||
DSI_ERR("[%s] failed to dfps update rc=%d\n",
|
||||
display->name, rc);
|
||||
return -EINVAL;
|
||||
}
|
||||
@@ -990,7 +989,7 @@ struct dsi_bridge *dsi_drm_bridge_init(struct dsi_display *display,
|
||||
|
||||
rc = drm_bridge_attach(encoder, &bridge->base, NULL);
|
||||
if (rc) {
|
||||
pr_err("failed to attach bridge, rc=%d\n", rc);
|
||||
DSI_ERR("failed to attach bridge, rc=%d\n", rc);
|
||||
goto error_free_bridge;
|
||||
}
|
||||
|
||||
|
新增問題並參考
封鎖使用者