setcmap_legacy() does not call drm_modeset_unlock_all() in some exits,
add the missed unlocks with goto to fix it.
Fixes: 964c60063bff ("drm/fb-helper: separate the fb_setcmap helper into atomic
and legacy paths")
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/drm_fb_hel
Although gx1fb_probe() has handled the failure of gx1fb_map_video_memory()
partly, it does not call pci_disable_device() as gx1fb_map_video_memory()
calls pci_enable_device().
Add the missed function call to fix the bug.
Fixes: 53eed4ec8bcd ("[PATCH] fbdev: geode updates]")
Signed-off-b
Although gx1fb_probe() has handled the failure of gx1fb_map_video_memory()
partly, it does not call pci_disable_device() as gx1fb_map_video_memory()
calls pci_enable_device().
Add the missed function call to fix the bug.
Fixes: 53eed4ec8bcd ("[PATCH] fbdev: geode updates]")
Signed-off-b
on" is not null.
Signed-off-by: Chuhong Yuan
---
Changes in v4:
- Add a field in vesafb_par to represent whether request_region() succeeds.
- Only call release_region() when request_region() succeeds.
- Adjust the order in the error handler of probe.
- Modify commit message.
drivers/
The driver calls register_framebuffer() in probe but does not call
unregister_framebuffer() in remove.
Rename current remove to __s1d13xxxfb_remove() for error handler.
Then add a new remove to call unregister_framebuffer().
Signed-off-by: Chuhong Yuan
---
Changes in v3:
- Fix code style
The driver forgets to free irq in remove which is requested in
probe.
Add the missed call to fix it.
Also, the position of request_irq() in probe should be put before
register_framebuffer().
Signed-off-by: Chuhong Yuan
---
Changes in v4:
- Use info->par->irq instead of par->irq
On Fri, Mar 20, 2020 at 8:01 PM Bartlomiej Zolnierkiewicz
wrote:
>
>
> On 3/10/20 3:35 AM, Chuhong Yuan wrote:
> > The driver forgets to free the I/O region in remove and probe
> > failure.
> > Add the missed calls to fix it.
> >
> > Signed-off-by:
The driver calls register_framebuffer() in probe but does not call
unregister_framebuffer() in remove.
Rename current remove to __s1d13xxxfb_remove() for error handler.
Then add a new remove to call unregister_framebuffer().
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Rename the existing
The driver forgets to free irq in remove which is requested in
probe.
Add the missed call to fix it.
Also, the position of request_irq() in probe should be put before
register_framebuffer().
Signed-off-by: Chuhong Yuan
---
Changes in v3:
- Add missed variable par in remove.
drivers/video
The driver forgets to free the I/O region in remove and probe
failure.
Add the missed calls to fix it.
Signed-off-by: Chuhong Yuan
---
Changes in v3:
- Revise the commit message.
- Add an error handler to suit the "goto error" before request_region().
- Revise the order of ope
The driver forgets to free irq in remove which is requested in
probe.
Add the missed call to fix it.
Also, the position of request_irq() in probe should be put before
register_framebuffer().
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Modify the commit message.
- Adjust the order of
nv50_msto_disable() does not call nv50_outp_release() to match
nv50_outp_acquire() like other disable().
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Fix the subject prefix.
drivers/gpu/drm/nouveau/dispnv50/disp.c | 4 +++-
1 file changed, 3 insertions
oaktrail_lvds_mode_set() misses a gma_power_end() in an error path.
Add the call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/gma500/oaktrail_lvds.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/gma500/oaktrail_lvds.c
b/drivers/gpu/drm/gma500/oaktrail_lvds.c
nv50_msto_disable() does not call nv50_outp_release() to match
nv50_outp_acquire() like other disable().
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/nouveau/dispnv50/disp.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm
The driver uses kfree() to release the resource allocated by
framebuffer_alloc(), which does not match.
Use framebuffer_release() instead to fix it.
Fixes: 638772c7553f ("fb: add support of LCD display controller on pxa168/910
(base layer)")
Signed-off-by: Chuhong Yuan
---
drivers/v
The driver forgets to free the requested irq in remove and probe
failure.
Add the missed calls to fix it.
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Modify commit message.
drivers/video/fbdev/vesafb.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/video/fbdev/vesafb.c b
The driver forgets to call component_del in remove to match component_add
in probe.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/exynos/exynos_drm_gsc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c
b/drivers/gpu
The driver forgets to call component_del in remove to match component_add
in probe.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/exynos/exynos_drm_gsc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gsc.c
b/drivers/gpu
The driver forgets to disable the regulator in remove like what is done
in probe failure.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/ssd1307fb.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/video/fbdev/ssd1307fb.c b/drivers/video/fbdev
The driver calls register_framebuffer in probe but does not call
unregister_framebuffer in remove.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/s1d13xxxfb.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/video/fbdev/s1d13xxxfb.c b/drivers/video
This driver forgets to call pm_runtime_disable and clk_disable_unprepare
in remove.
Add the calls to fix it.
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Add the missed pm_runtime_disable.
drivers/gpu/ipu-v3/ipu-prg.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/ipu
The driver forgets to call pm_runtime_disable in probe failure
and remove.
Add the missed calls to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/v3d/v3d_drv.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/v3d/v3d_drv.c b/drivers/gpu/drm/v3d/v3d_drv.c
index
The driver forgets to free irq in remove which is requested in
probe.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/arcfb.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/video/fbdev/arcfb.c b/drivers/video/fbdev/arcfb.c
index a48741aab240
This driver calls request_region in probe but forgets to call
release_region in probe failure and remove.
Add the missed calls to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/vesafb.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/video/fbdev/vesafb.c b/drivers
On Tue, Nov 12, 2019 at 5:40 PM Daniel Vetter wrote:
>
> On Sat, Nov 09, 2019 at 03:54:17PM +0800, Chuhong Yuan wrote:
> > drm_put_dev also calls drm_dev_unregister, so dev will be unregistered
> > twice.
> > Replace it with drm_dev_put to fix it.
> >
> > S
drm_put_dev also calls drm_dev_unregister, so dev will be unregistered
twice.
Replace it with drm_dev_put to fix it.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/virtio/virtgpu_drv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/virtio/virtgpu_drv.c
b
The driver forgets to disable and unprepare clks when remove.
Add the calls to clk_disable_unprepare to fix the problem.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/ipu-v3/ipu-prg.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/gpu/ipu-v3/ipu-prg.c b/drivers/gpu/ipu-v3/ipu-prg.c
lp855x forgets to disable enable regulator when remove.
Add a call to regulator_disable in remove just like what is done to
supply regulator.
Signed-off-by: Chuhong Yuan
---
drivers/video/backlight/lp855x_bl.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/video/backlight
strncpy(dest, src, strlen(src)) leads to unterminated
dest, which is dangerous.
Fix it by using strscpy.
Signed-off-by: Chuhong Yuan
---
Changes in v2:
- Check whether mode_end + 1 exceeds
the size of mode->name.
drivers/gpu/drm/drm_modes.c | 4 +++-
1 file changed, 3 inserti
strncpy(dest, src, strlen(src)) leads to unterminated
dest, which is dangerous.
Fix it by using strscpy.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/drm_modes.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/sm712fb.c | 8 ++--
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/drivers/video/fbdev/sm712fb.c b/drivers/video/fbdev/sm712fb.c
index
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/video/fbdev/aty/radeon_base.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/video/fbdev/aty/radeon_base.c
b/drivers/video/fbdev
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
b
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/radeon/radeon_drv.c | 15 +--
1 file changed, 5 insertions(+), 10 deletions(-)
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c
b/drivers/gpu
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 27 +
1 file changed, 10 insertions(+), 17 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
b/drivers/gpu/drm/vmwgfx
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/nouveau/nouveau_drm.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c
b/drivers/gpu/drm
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/gma500/power.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/gma500/power.c b/drivers/gpu/drm/gma500/power.c
index
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/qxl/qxl_drv.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/qxl/qxl_drv.c b/drivers/gpu/drm/qxl/qxl_drv.c
index
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/i915/i915_drv.c | 12
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_drv.c
b
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/bochs/bochs_drv.c | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/bochs/bochs_drv.c
b/drivers/gpu/drm/bochs
Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/ast/ast_drv.c | 12
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/ast/ast_drv.c b/drivers/gpu/drm/ast/ast_drv.c
dev_get_drvdata is a simpler implementation comparing
to to_platform_device + platform_get_drvdata.
This makes the code simpler.
Signed-off-by: Chuhong Yuan
---
drivers/gpu/drm/exynos/exynos_drm_fimc.c | 2 +-
drivers/gpu/drm/exynos/exynos_drm_gsc.c | 2 +-
2 files changed, 2 insertions(+), 2
44 matches
Mail list logo