disp: msm: sde: remove sde_hw_blk

The sde_hw_blk was meant to be a generic base object for all
SDE HW blocks, however, it enforces using a common set of ops
which is not practical when blocks have different capabilities.
Since this object was never used as intended and is not doing
anything functional today, remove the dead weight.

Change-Id: If76006c1ae5c62e8d7d77b100837dbaf6c661bd3
Signed-off-by: Steve Cohen <quic_cohens@quicinc.com>
Este commit está contenido en:
Steve Cohen
2021-06-07 19:51:37 -04:00
cometido por Jeykumar Sankaran
padre 5fe7c2f8a0
commit d9794d82cd
Se han modificado 36 ficheros con 190 adiciones y 620 borrados

Ver fichero

@@ -212,29 +212,21 @@ static void _setup_dsc_ops(struct sde_hw_dsc_ops *ops,
ops->bind_pingpong_blk = sde_hw_dsc_bind_pingpong_blk;
};
static struct sde_hw_blk_ops sde_hw_ops = {
.start = NULL,
.stop = NULL,
};
struct sde_hw_dsc *sde_hw_dsc_init(enum sde_dsc idx,
struct sde_hw_blk_reg_map *sde_hw_dsc_init(enum sde_dsc idx,
void __iomem *addr,
struct sde_mdss_cfg *m)
{
struct sde_hw_dsc *c;
struct sde_dsc_cfg *cfg;
u32 dsc_ctl_offset;
int rc = -EINVAL;
c = kzalloc(sizeof(*c), GFP_KERNEL);
if (!c)
return ERR_PTR(-ENOMEM);
cfg = _dsc_offset(idx, m, addr, &c->hw);
if (IS_ERR_OR_NULL(cfg)) {
kfree(c);
return ERR_PTR(-EINVAL);
}
if (IS_ERR_OR_NULL(cfg))
goto error_inv;
c->idx = idx;
c->caps = cfg;
@@ -286,28 +278,19 @@ struct sde_hw_dsc *sde_hw_dsc_init(enum sde_dsc idx,
c->hw.xin_id);
} else {
SDE_ERROR("failed to setup ops\n");
goto blk_init_error;
goto error_inv;
}
rc = sde_hw_blk_init(&c->base, SDE_HW_BLK_DSC, idx, &sde_hw_ops);
if (rc) {
SDE_ERROR("failed to init hw blk %d\n", rc);
goto blk_init_error;
}
return &c->hw;
return c;
blk_init_error:
error_inv:
kfree(c);
return ERR_PTR(rc);
return ERR_PTR(-EINVAL);
}
void sde_hw_dsc_destroy(struct sde_hw_dsc *dsc)
void sde_hw_dsc_destroy(struct sde_hw_blk_reg_map *hw)
{
if (dsc)
sde_hw_blk_destroy(&dsc->base);
kfree(dsc);
if (hw)
kfree(to_sde_hw_dsc(hw));
}