diff options
author | Dave Airlie <airlied@redhat.com> | 2018-06-28 23:25:01 +0300 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2018-06-28 23:25:08 +0300 |
commit | 2d8aa4ef6aac566617052640e9bb07ecb9c45183 (patch) | |
tree | 3d351549114b4d8d0e0ed4ed4ee516d7391e9e50 | |
parent | d12bce954e31a23bff71c1f567a3dcfa1a2d7ff6 (diff) | |
parent | 01a9e9493fb3f65c07077d59cf8ba8b6d2e0463e (diff) | |
download | linux-2d8aa4ef6aac566617052640e9bb07ecb9c45183.tar.xz |
Merge tag 'drm-misc-fixes-2018-06-28' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes
drm-misc-fixes for v4.18-rc3:
- A single fix in meson for an unhandled error path in meson_drv_bind_master().
Signed-off-by: Dave Airlie <airlied@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/fa740f31-5a8d-ed45-5e8a-aecd3f6f11b7@linux.intel.com
-rw-r--r-- | drivers/gpu/drm/meson/meson_drv.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/gpu/drm/meson/meson_drv.c b/drivers/gpu/drm/meson/meson_drv.c index 32b1a6cdecfc..d3443125e661 100644 --- a/drivers/gpu/drm/meson/meson_drv.c +++ b/drivers/gpu/drm/meson/meson_drv.c @@ -197,8 +197,10 @@ static int meson_drv_bind_master(struct device *dev, bool has_components) priv->io_base = regs; res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "hhi"); - if (!res) - return -EINVAL; + if (!res) { + ret = -EINVAL; + goto free_drm; + } /* Simply ioremap since it may be a shared register zone */ regs = devm_ioremap(dev, res->start, resource_size(res)); if (!regs) { @@ -215,8 +217,10 @@ static int meson_drv_bind_master(struct device *dev, bool has_components) } res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dmc"); - if (!res) - return -EINVAL; + if (!res) { + ret = -EINVAL; + goto free_drm; + } /* Simply ioremap since it may be a shared register zone */ regs = devm_ioremap(dev, res->start, resource_size(res)); if (!regs) { |