Loading drivers/gpu/drm/msm/sde_dbg.c +12 −0 Original line number Diff line number Diff line Loading @@ -2723,6 +2723,9 @@ static ssize_t sde_dbg_reg_base_offset_write(struct file *file, if (off > dbg->max_offset) return -EINVAL; if (off % sizeof(u32)) return -EINVAL; if (cnt > (dbg->max_offset - off)) cnt = dbg->max_offset - off; Loading Loading @@ -2754,6 +2757,9 @@ static ssize_t sde_dbg_reg_base_offset_read(struct file *file, if (*ppos) return 0; /* the end */ if (dbg->off % sizeof(u32)) return -EFAULT; len = snprintf(buf, sizeof(buf), "0x%08zx %zx\n", dbg->off, dbg->cnt); if (len < 0 || len >= sizeof(buf)) return 0; Loading Loading @@ -2797,6 +2803,9 @@ static ssize_t sde_dbg_reg_base_reg_write(struct file *file, if (cnt < 2) return -EFAULT; if (off % sizeof(u32)) return -EFAULT; if (off >= dbg->max_offset) return -EFAULT; Loading Loading @@ -2841,6 +2850,9 @@ static ssize_t sde_dbg_reg_base_reg_read(struct file *file, if (!dbg->buf) return -ENOMEM; if (dbg->off % sizeof(u32)) return -EFAULT; ptr = dbg->base + dbg->off; tot = 0; Loading Loading
drivers/gpu/drm/msm/sde_dbg.c +12 −0 Original line number Diff line number Diff line Loading @@ -2723,6 +2723,9 @@ static ssize_t sde_dbg_reg_base_offset_write(struct file *file, if (off > dbg->max_offset) return -EINVAL; if (off % sizeof(u32)) return -EINVAL; if (cnt > (dbg->max_offset - off)) cnt = dbg->max_offset - off; Loading Loading @@ -2754,6 +2757,9 @@ static ssize_t sde_dbg_reg_base_offset_read(struct file *file, if (*ppos) return 0; /* the end */ if (dbg->off % sizeof(u32)) return -EFAULT; len = snprintf(buf, sizeof(buf), "0x%08zx %zx\n", dbg->off, dbg->cnt); if (len < 0 || len >= sizeof(buf)) return 0; Loading Loading @@ -2797,6 +2803,9 @@ static ssize_t sde_dbg_reg_base_reg_write(struct file *file, if (cnt < 2) return -EFAULT; if (off % sizeof(u32)) return -EFAULT; if (off >= dbg->max_offset) return -EFAULT; Loading Loading @@ -2841,6 +2850,9 @@ static ssize_t sde_dbg_reg_base_reg_read(struct file *file, if (!dbg->buf) return -ENOMEM; if (dbg->off % sizeof(u32)) return -EFAULT; ptr = dbg->base + dbg->off; tot = 0; Loading