msm: mdss: debugfs: xlog: add support to dump registers by ranges
Current xlog dumps the entire registers ranges mapped in memory. This entire range can be reduced to only the meaningful offsets to help in debugging and avoid overflows in the debug buffers. This change adds support to only dump the registers ranges specified. Change-Id: Iecf7f5eaa909b0365ea599ae094c7f184c0ae8b8 Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org> (cherry picked from commit 899cf5dbc528b13bd488038215356c5bea5b591c) [veeras@codeaurora.org: Resolve merge conflict in mdss_dsi.c] Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
This commit is contained in:
parent
ebba7cddde
commit
76dae5e544
10 changed files with 287 additions and 53 deletions
|
@ -362,6 +362,22 @@ Optional properties:
|
|||
The offsets are calculated from the "mdp_phys" base address
|
||||
specified. The number of offsets should match the
|
||||
number of ping pong buffers available in the hardware.
|
||||
- qcom,regs-dump-mdp: This array represents the registers offsets that
|
||||
will be dumped from the mdp when the debug logging
|
||||
is enabled; each entry in the table is an start and
|
||||
end offset from the MDP addres "mdp_phys", the
|
||||
format of each entry is as follows:
|
||||
<start_offset end_offset>
|
||||
Ex:
|
||||
<0x01000 0x01404>
|
||||
Will dump the MDP registers
|
||||
from the address: "mdp_phys + 0x01000"
|
||||
to the address: "mdp_phys + 0x01404"
|
||||
- qcom,regs-dump-names-mdp: This array represents the tag that will be used
|
||||
for each of the entries defined within regs-dump.
|
||||
Note that each tag matches with one of the
|
||||
regs-dump entries in the same order as they
|
||||
are defined.
|
||||
|
||||
Fudge Factors: Fudge factors are used to boost demand for
|
||||
resources like bus bandswidth, clk rate etc. to
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* Copyright (c) 2012-2014, The Linux Foundation. All rights reserved.
|
||||
/* Copyright (c) 2012-2015, The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 and
|
||||
|
@ -1444,7 +1444,8 @@ static int msm_dsi_debug_init(void)
|
|||
|
||||
rc = mdss_debug_register_base("dsi0",
|
||||
dsi_host_private->dsi_base,
|
||||
dsi_host_private->dsi_reg_size);
|
||||
dsi_host_private->dsi_reg_size,
|
||||
NULL);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
|
@ -1767,7 +1767,7 @@ static int mdp3_debug_init(struct platform_device *pdev)
|
|||
&mdp3_debug_dump_stats_fops);
|
||||
|
||||
rc = mdss_debug_register_base(NULL, mdp3_res->mdp_base ,
|
||||
mdp3_res->mdp_reg_size);
|
||||
mdp3_res->mdp_reg_size, NULL);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
|
@ -233,7 +233,7 @@ static const struct file_operations mdss_reg_fops = {
|
|||
};
|
||||
|
||||
int mdss_debug_register_base(const char *name, void __iomem *base,
|
||||
size_t max_offset)
|
||||
size_t max_offset, struct mdss_debug_base **dbg_blk)
|
||||
{
|
||||
struct mdss_data_type *mdata = mdss_res;
|
||||
struct mdss_debug_data *mdd;
|
||||
|
@ -242,6 +242,9 @@ int mdss_debug_register_base(const char *name, void __iomem *base,
|
|||
char dn[80] = "";
|
||||
int prefix_len = 0;
|
||||
|
||||
if (dbg_blk)
|
||||
(*dbg_blk) = NULL;
|
||||
|
||||
if (!mdata || !mdata->debug_inf.debug_data)
|
||||
return -ENODEV;
|
||||
|
||||
|
@ -276,8 +279,14 @@ int mdss_debug_register_base(const char *name, void __iomem *base,
|
|||
goto reg_fail;
|
||||
}
|
||||
|
||||
/* Initialize list to make sure check for null list will be valid */
|
||||
INIT_LIST_HEAD(&dbg->dump_list);
|
||||
|
||||
list_add(&dbg->head, &mdd->base_list);
|
||||
|
||||
if (dbg_blk)
|
||||
(*dbg_blk) = dbg;
|
||||
|
||||
return 0;
|
||||
reg_fail:
|
||||
debugfs_remove(ent_off);
|
||||
|
@ -286,6 +295,87 @@ off_fail:
|
|||
return -ENODEV;
|
||||
}
|
||||
|
||||
static void parse_dump_range_name(struct device_node *node,
|
||||
int total_names, int index, char *range_name, u32 range_size,
|
||||
const char *name_prop)
|
||||
{
|
||||
int rc = 0;
|
||||
const char *st = NULL;
|
||||
|
||||
if ((total_names > 0) && (index < total_names)) {
|
||||
rc = of_property_read_string_index(node,
|
||||
name_prop, index, &st);
|
||||
if (rc) {
|
||||
pr_err("%s: error reading name. index=%d, rc=%d\n",
|
||||
__func__, index, rc);
|
||||
goto error;
|
||||
}
|
||||
snprintf(range_name, range_size, "%s", st);
|
||||
return;
|
||||
}
|
||||
|
||||
error:
|
||||
snprintf(range_name, range_size, "%s", "<no named range>");
|
||||
}
|
||||
|
||||
static int parse_dt_xlog_dump_list(const u32 *arr, int count,
|
||||
struct list_head *xlog_dump_list, int total_names,
|
||||
struct platform_device *pdev, const char *name_prop)
|
||||
{
|
||||
struct range_dump_node *xlog_node;
|
||||
u32 len;
|
||||
int i;
|
||||
|
||||
for (i = 0, len = count * 2; i < len; i += 2) {
|
||||
xlog_node = kzalloc(sizeof(*xlog_node), GFP_KERNEL);
|
||||
if (!xlog_node)
|
||||
return -ENOMEM;
|
||||
|
||||
xlog_node->offset.start = be32_to_cpu(arr[i]);
|
||||
xlog_node->offset.end = be32_to_cpu(arr[i + 1]);
|
||||
parse_dump_range_name(pdev->dev.of_node, total_names, i/2,
|
||||
xlog_node->range_name,
|
||||
ARRAY_SIZE(xlog_node->range_name), name_prop);
|
||||
|
||||
list_add_tail(&xlog_node->head, xlog_dump_list);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void mdss_debug_register_dump_range(struct platform_device *pdev,
|
||||
struct mdss_debug_base *blk_base, const char *ranges_prop,
|
||||
const char *name_prop)
|
||||
{
|
||||
int total_dump_names, mdp_len;
|
||||
const u32 *mdp_arr;
|
||||
|
||||
if (!blk_base || !ranges_prop || !name_prop)
|
||||
return;
|
||||
|
||||
/* Get the property with the name of the ranges */
|
||||
total_dump_names = of_property_count_strings(pdev->dev.of_node,
|
||||
name_prop);
|
||||
if (total_dump_names < 0) {
|
||||
pr_warn("%s: dump names not found. rc=%d\n", __func__,
|
||||
total_dump_names);
|
||||
total_dump_names = 0;
|
||||
}
|
||||
|
||||
mdp_arr = of_get_property(pdev->dev.of_node, ranges_prop,
|
||||
&mdp_len);
|
||||
if (!mdp_arr) {
|
||||
pr_warn("No xlog range dump found, continue\n");
|
||||
mdp_len = 0;
|
||||
} else {
|
||||
/* 2 is the number of entries per row to calculate the rows */
|
||||
mdp_len /= 2 * sizeof(u32);
|
||||
parse_dt_xlog_dump_list(mdp_arr, mdp_len,
|
||||
&blk_base->dump_list, total_dump_names, pdev,
|
||||
name_prop);
|
||||
}
|
||||
}
|
||||
|
||||
static ssize_t mdss_debug_factor_write(struct file *file,
|
||||
const char __user *user_buf, size_t count, loff_t *ppos)
|
||||
{
|
||||
|
|
|
@ -67,7 +67,12 @@ enum mdss_dbg_xlog_flag {
|
|||
trace_mdp_trace_counter(current->tgid, name, value)
|
||||
|
||||
#ifdef CONFIG_DEBUG_FS
|
||||
|
||||
#define MDSS_DEBUG_BASE_MAX 10
|
||||
|
||||
struct mdss_debug_base {
|
||||
struct list_head head; /* head of this node */
|
||||
struct list_head dump_list; /* head to the list with dump ranges */
|
||||
struct mdss_debug_data *mdd;
|
||||
char name[80];
|
||||
void __iomem *base;
|
||||
|
@ -76,8 +81,7 @@ struct mdss_debug_base {
|
|||
size_t max_offset;
|
||||
char *buf;
|
||||
size_t buf_len;
|
||||
struct list_head head;
|
||||
u32 *reg_dump;
|
||||
u32 *reg_dump; /* address for the mem dump if no ranges used */
|
||||
};
|
||||
|
||||
struct mdss_debug_data {
|
||||
|
@ -86,6 +90,18 @@ struct mdss_debug_data {
|
|||
struct list_head base_list;
|
||||
};
|
||||
|
||||
struct dump_offset {
|
||||
u32 start;
|
||||
u32 end;
|
||||
};
|
||||
|
||||
struct range_dump_node {
|
||||
struct list_head head; /* head of this node */
|
||||
u32 *reg_dump; /* address for the mem dump */
|
||||
char range_name[40]; /* name of this range */
|
||||
struct dump_offset offset; /* range to dump */
|
||||
};
|
||||
|
||||
#define DEFINE_MDSS_DEBUGFS_SEQ_FOPS(__prefix) \
|
||||
static int __prefix ## _open(struct inode *inode, struct file *file) \
|
||||
{ \
|
||||
|
@ -102,7 +118,10 @@ static const struct file_operations __prefix ## _fops = { \
|
|||
int mdss_debugfs_init(struct mdss_data_type *mdata);
|
||||
int mdss_debugfs_remove(struct mdss_data_type *mdata);
|
||||
int mdss_debug_register_base(const char *name, void __iomem *base,
|
||||
size_t max_offset);
|
||||
size_t max_offset, struct mdss_debug_base **dbg_blk);
|
||||
void mdss_debug_register_dump_range(struct platform_device *pdev,
|
||||
struct mdss_debug_base *blk_base, const char *ranges_prop,
|
||||
const char *name_prop);
|
||||
int mdss_misr_set(struct mdss_data_type *mdata, struct mdp_misr *req,
|
||||
struct mdss_mdp_ctl *ctl);
|
||||
int mdss_misr_get(struct mdss_data_type *mdata, struct mdp_misr *resp,
|
||||
|
@ -121,7 +140,10 @@ static inline int mdss_debugfs_remove(struct mdss_data_type *mdata)
|
|||
return 0;
|
||||
}
|
||||
static inline int mdss_debug_register_base(const char *name, void __iomem *base,
|
||||
size_t max_offset) { return 0; }
|
||||
size_t max_offset, struct mdss_debug_base **dbg_blk) { return 0; }
|
||||
static inline void mdss_debug_register_dump_range(struct platform_device *pdev,
|
||||
struct mdss_debug_base *blk_base, const char *ranges_prop,
|
||||
const char *name_prop) { return 0; }
|
||||
static inline int mdss_misr_set(struct mdss_data_type *mdata,
|
||||
struct mdp_misr *req,
|
||||
struct mdss_mdp_ctl *ctl)
|
||||
|
@ -143,9 +165,10 @@ static inline int mdss_xlog_tout_handler_iommu(struct iommu_domain *domain,
|
|||
#endif
|
||||
|
||||
static inline int mdss_debug_register_io(const char *name,
|
||||
struct dss_io_data *io_data)
|
||||
struct dss_io_data *io_data, struct mdss_debug_base **dbg_blk)
|
||||
{
|
||||
return mdss_debug_register_base(name, io_data->base, io_data->len);
|
||||
return mdss_debug_register_base(name, io_data->base, io_data->len,
|
||||
dbg_blk);
|
||||
}
|
||||
|
||||
#endif /* MDSS_DEBUG_H */
|
||||
|
|
|
@ -45,6 +45,7 @@ struct mdss_dbg_xlog {
|
|||
u32 xlog_enable;
|
||||
u32 panic_on_err;
|
||||
u32 enable_reg_dump;
|
||||
struct mdss_debug_base *blk_arr[MDSS_DEBUG_BASE_MAX];
|
||||
} mdss_dbg_xlog;
|
||||
|
||||
static inline bool mdss_xlog_is_enabled(u32 flag)
|
||||
|
@ -175,45 +176,50 @@ static void mdss_xlog_dump_all(void)
|
|||
}
|
||||
}
|
||||
|
||||
static void mdss_dump_reg(struct mdss_debug_base *dbg, u32 reg_dump_flag)
|
||||
u32 get_dump_range(struct dump_offset *range_node, size_t max_offset)
|
||||
{
|
||||
char *addr;
|
||||
u32 *dump_addr = NULL;
|
||||
int len;
|
||||
int i;
|
||||
bool in_log, in_mem;
|
||||
u32 length = 0;
|
||||
|
||||
if (!dbg || !dbg->base) {
|
||||
pr_err("dbg base is null!\n");
|
||||
return;
|
||||
if ((range_node->start > range_node->end) ||
|
||||
(range_node->end > max_offset) || (range_node->start == 0
|
||||
&& range_node->end == 0)) {
|
||||
length = max_offset;
|
||||
} else {
|
||||
length = range_node->end - range_node->start;
|
||||
}
|
||||
|
||||
return length;
|
||||
}
|
||||
|
||||
static void mdss_dump_reg(u32 reg_dump_flag,
|
||||
char *addr, int len, u32 *dump_mem)
|
||||
{
|
||||
bool in_log, in_mem;
|
||||
u32 *dump_addr = NULL;
|
||||
int i;
|
||||
|
||||
in_log = (reg_dump_flag & MDSS_REG_DUMP_IN_LOG);
|
||||
in_mem = (reg_dump_flag & MDSS_REG_DUMP_IN_MEM);
|
||||
|
||||
addr = dbg->base;
|
||||
len = dbg->max_offset;
|
||||
pr_info("reg_dump_flag=%d in_log=%d in_mem=%d\n", reg_dump_flag, in_log,
|
||||
in_mem);
|
||||
|
||||
if (len % 16)
|
||||
len += 16;
|
||||
len /= 16;
|
||||
|
||||
pr_info("reg_dump_flag=%d in_log=%d in_mem=%d\n", reg_dump_flag, in_log,
|
||||
in_mem);
|
||||
pr_info("%s:=========%s DUMP=========\n", __func__, dbg->name);
|
||||
|
||||
if (in_mem) {
|
||||
if (!dbg->reg_dump)
|
||||
dbg->reg_dump = kzalloc(len * 16, GFP_KERNEL);
|
||||
if (!dump_mem)
|
||||
dump_mem = kzalloc(len * 16, GFP_KERNEL);
|
||||
|
||||
if (dbg->reg_dump) {
|
||||
dump_addr = dbg->reg_dump;
|
||||
if (dump_mem) {
|
||||
dump_addr = dump_mem;
|
||||
pr_info("start_addr:%p end_addr:%p reg_addr=%p\n",
|
||||
dump_addr, dump_addr + (u32)len * 16,
|
||||
addr);
|
||||
} else {
|
||||
in_mem = false;
|
||||
pr_err("reg_dump: kzalloc fails!\n");
|
||||
pr_err("dump_mem: kzalloc fails!\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -242,6 +248,44 @@ static void mdss_dump_reg(struct mdss_debug_base *dbg, u32 reg_dump_flag)
|
|||
mdss_mdp_clk_ctrl(MDP_BLOCK_POWER_OFF);
|
||||
}
|
||||
|
||||
static void mdss_dump_reg_by_ranges(struct mdss_debug_base *dbg,
|
||||
u32 reg_dump_flag)
|
||||
{
|
||||
char *addr;
|
||||
int len;
|
||||
struct range_dump_node *xlog_node, *xlog_tmp;
|
||||
|
||||
if (!dbg || !dbg->base) {
|
||||
pr_err("dbg base is null!\n");
|
||||
return;
|
||||
}
|
||||
|
||||
pr_info("%s:=========%s DUMP=========\n", __func__, dbg->name);
|
||||
|
||||
/* If there is a list to dump the registers by ranges, use the ranges */
|
||||
if (!list_empty(&dbg->dump_list)) {
|
||||
list_for_each_entry_safe(xlog_node, xlog_tmp,
|
||||
&dbg->dump_list, head) {
|
||||
len = get_dump_range(&xlog_node->offset,
|
||||
dbg->max_offset);
|
||||
addr = dbg->base + xlog_node->offset.start;
|
||||
pr_info("%s: range_base=0x%p start=0x%x end=0x%x\n",
|
||||
xlog_node->range_name,
|
||||
addr, xlog_node->offset.start,
|
||||
xlog_node->offset.end);
|
||||
mdss_dump_reg(reg_dump_flag, addr, len,
|
||||
xlog_node->reg_dump);
|
||||
}
|
||||
} else {
|
||||
/* If there is no list to dump ranges, dump all registers */
|
||||
pr_info("Ranges not found, will dump full registers");
|
||||
pr_info("base:0x%p len:0x%zu\n", dbg->base, dbg->max_offset);
|
||||
addr = dbg->base;
|
||||
len = dbg->max_offset;
|
||||
mdss_dump_reg(reg_dump_flag, addr, len, dbg->reg_dump);
|
||||
}
|
||||
}
|
||||
|
||||
static void mdss_dump_reg_by_blk(const char *blk_name)
|
||||
{
|
||||
struct mdss_data_type *mdata = mdss_mdp_get_mdata();
|
||||
|
@ -254,7 +298,8 @@ static void mdss_dump_reg_by_blk(const char *blk_name)
|
|||
list_for_each_entry_safe(blk_base, tmp, &mdd->base_list, head) {
|
||||
if (blk_base->name &&
|
||||
!strcmp(blk_base->name, blk_name)) {
|
||||
mdss_dump_reg(blk_base, mdss_dbg_xlog.enable_reg_dump);
|
||||
mdss_dump_reg_by_ranges(blk_base,
|
||||
mdss_dbg_xlog.enable_reg_dump);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -271,37 +316,90 @@ static void mdss_dump_reg_all(void)
|
|||
|
||||
list_for_each_entry_safe(blk_base, tmp, &mdd->base_list, head) {
|
||||
if (blk_base->name)
|
||||
mdss_dump_reg(blk_base,
|
||||
mdss_dump_reg_by_blk(blk_base->name);
|
||||
}
|
||||
}
|
||||
|
||||
static void clear_dump_blk_arr(struct mdss_debug_base *blk_arr[],
|
||||
u32 blk_len)
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i < blk_len; i++)
|
||||
blk_arr[i] = NULL;
|
||||
}
|
||||
|
||||
struct mdss_debug_base *get_dump_blk_addr(const char *blk_name)
|
||||
{
|
||||
struct mdss_data_type *mdata = mdss_mdp_get_mdata();
|
||||
struct mdss_debug_data *mdd = mdata->debug_inf.debug_data;
|
||||
struct mdss_debug_base *blk_base, *tmp;
|
||||
|
||||
if (!mdd)
|
||||
return NULL;
|
||||
|
||||
list_for_each_entry_safe(blk_base, tmp, &mdd->base_list, head) {
|
||||
if (blk_base->name &&
|
||||
!strcmp(blk_base->name, blk_name))
|
||||
return blk_base;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void mdss_xlog_dump_array(struct mdss_debug_base *blk_arr[],
|
||||
u32 len, bool dead, const char *name)
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i < len; i++) {
|
||||
if (blk_arr[i] != NULL)
|
||||
mdss_dump_reg_by_ranges(blk_arr[i],
|
||||
mdss_dbg_xlog.enable_reg_dump);
|
||||
}
|
||||
|
||||
mdss_xlog_dump_all();
|
||||
|
||||
if (dead && mdss_dbg_xlog.panic_on_err)
|
||||
panic(name);
|
||||
}
|
||||
|
||||
void mdss_xlog_tout_handler_default(const char *name, ...)
|
||||
{
|
||||
int i, dead = 0;
|
||||
int i, index = 0;
|
||||
bool dead = false;
|
||||
va_list args;
|
||||
char *blk_name = NULL;
|
||||
struct mdss_debug_base *blk_base = NULL;
|
||||
struct mdss_debug_base **blk_arr;
|
||||
u32 blk_len;
|
||||
|
||||
if (!mdss_xlog_is_enabled(MDSS_XLOG_DEFAULT))
|
||||
return;
|
||||
|
||||
blk_arr = &mdss_dbg_xlog.blk_arr[0];
|
||||
blk_len = ARRAY_SIZE(mdss_dbg_xlog.blk_arr);
|
||||
|
||||
clear_dump_blk_arr(blk_arr, blk_len);
|
||||
|
||||
va_start(args, name);
|
||||
for (i = 0; i < MDSS_XLOG_MAX_DATA; i++) {
|
||||
blk_name = va_arg(args, char*);
|
||||
if (IS_ERR_OR_NULL(blk_name))
|
||||
break;
|
||||
|
||||
mdss_dump_reg_by_blk(blk_name);
|
||||
blk_base = get_dump_blk_addr(blk_name);
|
||||
if (blk_base && (index < blk_len)) {
|
||||
blk_arr[index] = blk_base;
|
||||
index++;
|
||||
}
|
||||
|
||||
if (!strcmp(blk_name, "panic"))
|
||||
dead = 1;
|
||||
dead = true;
|
||||
}
|
||||
va_end(args);
|
||||
|
||||
mdss_xlog_dump_all();
|
||||
|
||||
if (dead && mdss_dbg_xlog.panic_on_err)
|
||||
panic(name);
|
||||
mdss_xlog_dump_array(blk_arr, blk_len, dead, name);
|
||||
}
|
||||
|
||||
int mdss_xlog_tout_handler_iommu(struct iommu_domain *domain,
|
||||
|
|
|
@ -2059,18 +2059,20 @@ int dsi_panel_device_register(struct device_node *pan_node,
|
|||
}
|
||||
|
||||
if (pinfo->pdest == DISPLAY_1) {
|
||||
mdss_debug_register_io("dsi0_ctrl", &ctrl_pdata->ctrl_io);
|
||||
mdss_debug_register_io("dsi0_phy", &ctrl_pdata->phy_io);
|
||||
mdss_debug_register_io("dsi0_ctrl", &ctrl_pdata->ctrl_io, NULL);
|
||||
mdss_debug_register_io("dsi0_phy", &ctrl_pdata->phy_io, NULL);
|
||||
if (ctrl_pdata->shared_ctrl_data->phy_regulator_io.len)
|
||||
mdss_debug_register_io("dsi0_phy_regulator",
|
||||
&ctrl_pdata->shared_ctrl_data->phy_regulator_io);
|
||||
&ctrl_pdata->shared_ctrl_data->phy_regulator_io,
|
||||
NULL);
|
||||
ctrl_pdata->ndx = 0;
|
||||
} else {
|
||||
mdss_debug_register_io("dsi1_ctrl", &ctrl_pdata->ctrl_io);
|
||||
mdss_debug_register_io("dsi1_phy", &ctrl_pdata->phy_io);
|
||||
mdss_debug_register_io("dsi1_ctrl", &ctrl_pdata->ctrl_io, NULL);
|
||||
mdss_debug_register_io("dsi1_phy", &ctrl_pdata->phy_io, NULL);
|
||||
if (ctrl_pdata->shared_ctrl_data->phy_regulator_io.len)
|
||||
mdss_debug_register_io("dsi1_phy_regulator",
|
||||
&ctrl_pdata->shared_ctrl_data->phy_regulator_io);
|
||||
&ctrl_pdata->shared_ctrl_data->phy_regulator_io,
|
||||
NULL);
|
||||
ctrl_pdata->ndx = 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -832,7 +832,7 @@ static int mdss_edp_get_base_address(struct mdss_edp_drv_pdata *edp_drv)
|
|||
(int)edp_drv, (int)edp_drv->base, edp_drv->base_size);
|
||||
|
||||
mdss_debug_register_base("edp",
|
||||
edp_drv->base, edp_drv->base_size);
|
||||
edp_drv->base, edp_drv->base_size, NULL);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -4571,9 +4571,8 @@ static int hdmi_tx_probe(struct platform_device *pdev)
|
|||
DEV_DBG("%s: Add child devices.\n", __func__);
|
||||
}
|
||||
|
||||
if (mdss_debug_register_base("hdmi",
|
||||
hdmi_ctrl->pdata.io[HDMI_TX_CORE_IO].base,
|
||||
hdmi_ctrl->pdata.io[HDMI_TX_CORE_IO].len))
|
||||
if (mdss_debug_register_io("hdmi",
|
||||
&hdmi_ctrl->pdata.io[HDMI_TX_CORE_IO], NULL))
|
||||
DEV_WARN("%s: hdmi_tx debugfs register failed\n", __func__);
|
||||
|
||||
if (hdmi_ctrl->panel_data.panel_info.cont_splash_enabled) {
|
||||
|
|
|
@ -978,9 +978,11 @@ static void mdss_debug_enable_clock(int on)
|
|||
mdss_mdp_clk_ctrl(MDP_BLOCK_POWER_OFF);
|
||||
}
|
||||
|
||||
static int mdss_mdp_debug_init(struct mdss_data_type *mdata)
|
||||
static int mdss_mdp_debug_init(struct platform_device *pdev,
|
||||
struct mdss_data_type *mdata)
|
||||
{
|
||||
int rc;
|
||||
struct mdss_debug_base *dbg_blk;
|
||||
|
||||
mdata->debug_inf.debug_enable_clock = mdss_debug_enable_clock;
|
||||
|
||||
|
@ -994,8 +996,11 @@ static int mdss_mdp_debug_init(struct mdss_data_type *mdata)
|
|||
return rc;
|
||||
}
|
||||
|
||||
mdss_debug_register_io("mdp", &mdata->mdss_io);
|
||||
mdss_debug_register_io("vbif", &mdata->vbif_io);
|
||||
mdss_debug_register_io("mdp", &mdata->mdss_io, &dbg_blk);
|
||||
mdss_debug_register_dump_range(pdev, dbg_blk, "qcom,regs-dump-mdp",
|
||||
"qcom,regs-dump-names-mdp");
|
||||
|
||||
mdss_debug_register_io("vbif", &mdata->vbif_io, NULL);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -1499,7 +1504,7 @@ static int mdss_mdp_probe(struct platform_device *pdev)
|
|||
goto probe_done;
|
||||
}
|
||||
|
||||
rc = mdss_mdp_debug_init(mdata);
|
||||
rc = mdss_mdp_debug_init(pdev, mdata);
|
||||
if (rc) {
|
||||
pr_err("unable to initialize mdp debugging\n");
|
||||
goto probe_done;
|
||||
|
|
Loading…
Add table
Reference in a new issue