diff options
author | Rob Clark <robdclark@chromium.org> | 2020-10-19 14:10:52 -0700 |
---|---|---|
committer | Rob Clark <robdclark@chromium.org> | 2020-11-01 10:13:32 -0800 |
commit | ffe71111f4ab5aa670502f190d0b7fe10edd1784 (patch) | |
tree | 0dac0d56ccdf3ea7c05886fa3d6538676535d929 /drivers/gpu/drm/msm/disp/mdp5 | |
parent | 7e688294c61bdcb7468a71f7bb5a9c2d42fbd2a8 (diff) | |
download | linux-stable-ffe71111f4ab5aa670502f190d0b7fe10edd1784.tar.gz linux-stable-ffe71111f4ab5aa670502f190d0b7fe10edd1784.tar.bz2 linux-stable-ffe71111f4ab5aa670502f190d0b7fe10edd1784.zip |
drm/msm/kms: Update msm_kms_init/destroy
Add msm_kms_destroy() and add err return from msm_kms_init(). Prep work
for next patch.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Diffstat (limited to 'drivers/gpu/drm/msm/disp/mdp5')
-rw-r--r-- | drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c b/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c index e193865ce9a2..b3eecf869477 100644 --- a/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c +++ b/drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c @@ -232,6 +232,8 @@ static void mdp5_kms_destroy(struct msm_kms *kms) aspace->mmu->funcs->detach(aspace->mmu); msm_gem_address_space_put(aspace); } + + mdp_kms_destroy(&mdp5_kms->base); } #ifdef CONFIG_DEBUG_FS @@ -592,11 +594,14 @@ struct msm_kms *mdp5_kms_init(struct drm_device *dev) return NULL; mdp5_kms = to_mdp5_kms(to_mdp_kms(kms)); - - mdp_kms_init(&mdp5_kms->base, &kms_funcs); - pdev = mdp5_kms->pdev; + ret = mdp_kms_init(&mdp5_kms->base, &kms_funcs); + if (ret) { + DRM_DEV_ERROR(&pdev->dev, "failed to init kms\n"); + goto fail; + } + irq = irq_of_parse_and_map(pdev->dev.of_node, 0); if (irq < 0) { ret = irq; |