[PATCH] drm/vmwgfx: make vmw_pt_sys_placement static

2022-02-23 Thread Wambui Karuga
Converts the variable vmw_pt_sys_placement to static to fix the following Sparse warning: warning: symbol 'vmw_pt_sys_placement' was not declared. Should it be static? Signed-off-by: Wambui Karuga --- drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c | 2 +- 1 file changed, 1 insertion(+),

[Outreachy][PATCH] drm: use DIV_ROUND_UP helper macro for calculations

2019-10-28 Thread Wambui Karuga
Replace open coded divisor calculations with the DIV_ROUND_UP kernel macro for better readability. Issue found using coccinelle: @@ expression n,d; @@ ( - ((n + d - 1) / d) + DIV_ROUND_UP(n,d) | - ((n + (d - 1)) / d) + DIV_ROUND_UP(n,d) ) Signed-off-by: Wambui Karuga --- drivers/gpu/drm

[Outreachy][PATCH 1/2] drm/amd: declare amdgpu_exp_hw_support in amdgpu.h

2019-10-28 Thread Wambui Karuga
Declare `amdgpu_exp_hw_support` as extern in amdgpu.h to address the following sparse warning: drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c:118:5: warning: symbol 'amdgpu_exp_hw_support' was not declared. Should it be static? Signed-off-by: Wambui Karuga Suggested-by: Harry Wentland --

[Outreachy][PATCH 2/2] drm/amd: correct "_LENTH" mispelling in constant

2019-10-28 Thread Wambui Karuga
Correct the "_LENTH" mispelling in the AMDGPU_MAX_TIMEOUT_PARAM_LENGTH constant. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/amd/amdgpu/amdgpu.h| 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c| 2 +- 3 files

[Outreachy][PATCH 0/2] sparse warning cleanup

2019-10-28 Thread Wambui Karuga
This patchset addresses the sparse warning about the `amdgpu_exp_hw_support` variable and corrects the mispelling of the word "_LENTH". Wambui Karuga (2): drm/amd: declare amdgpu_exp_hw_support in amdgpu.h drm/amd: correct "_LENTH" mispelling in constant drivers/gpu/drm

Re: [PATCH] drm/rockchip: use DRM_DEV_ERROR for log output

2019-11-08 Thread Wambui Karuga
On Thu, Nov 07, 2019 at 08:38:51AM -0500, Sean Paul wrote: > On Thu, Nov 07, 2019 at 01:54:22AM -0800, Joe Perches wrote: > > On Thu, 2019-11-07 at 12:29 +0300, Wambui Karuga wrote: > > > Replace the use of the dev_err macro with the DRM_DEV_ERROR > > > DRM helper

[PATCH] drm/rockchip: use DRM_DEV_ERROR for log output

2019-11-08 Thread Wambui Karuga
Replace the use of the dev_err macro with the DRM_DEV_ERROR DRM helper macro. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c b/drivers/gpu/drm

Re: [PATCH] drm/rockchip: use DRM_DEV_ERROR for log output

2019-11-10 Thread Wambui Karuga
On Thu, Nov 07, 2019 at 08:38:51AM -0500, Sean Paul wrote: > On Thu, Nov 07, 2019 at 01:54:22AM -0800, Joe Perches wrote: > > On Thu, 2019-11-07 at 12:29 +0300, Wambui Karuga wrote: > > > Replace the use of the dev_err macro with the DRM_DEV_ERROR > > > DRM helper

Re: [PATCH] drm/rockchip: use DRM_DEV_ERROR for log output

2019-11-10 Thread Wambui Karuga
Karuga: On Thu, Nov 07, 2019 at 08:38:51AM -0500, Sean Paul wrote: On Thu, Nov 07, 2019 at 01:54:22AM -0800, Joe Perches wrote: On Thu, 2019-11-07 at 12:29 +0300, Wambui Karuga wrote: Replace the use of the dev_err macro with the DRM_DEV_ERROR DRM helper macro. The commit message should show the

[PATCH] drm/print: add DRM_DEV_WARN macro

2019-11-12 Thread Wambui Karuga
Add the DRM_DEV_WARN helper macro for printing warnings that use device pointers in their log output format. DRM_DEV_WARN can replace the use of dev_warn in such cases. Signed-off-by: Wambui Karuga --- include/drm/drm_print.h | 9 + 1 file changed, 9 insertions(+) diff --git a/include

Re: [PATCH] drm/print: add DRM_DEV_WARN macro

2019-11-12 Thread Wambui Karuga
On Tue, 12 Nov 2019, Daniel Vetter wrote: On Tue, Nov 12, 2019 at 08:09:09PM +0300, Wambui Karuga wrote: Add the DRM_DEV_WARN helper macro for printing warnings that use device pointers in their log output format. DRM_DEV_WARN can replace the use of dev_warn in such cases. Signed-off-by

[PATCH 1/2] drm/print: add DRM_DEV_WARN macro

2019-11-15 Thread Wambui Karuga
Add the DRM_DEV_WARN helper macro for printing warnings that use device pointers in their log output format. DRM_DEV_WARN can replace the use of dev_warn in such cases. Signed-off-by: Wambui Karuga --- include/drm/drm_print.h | 9 + 1 file changed, 9 insertions(+) diff --git a/include

[PATCH 0/2] add new DRM_DEV_WARN macro

2019-11-15 Thread Wambui Karuga
This adds a new DRM_DEV_WARN helper macro for warnings log output that include device pointers. It also includes the use of the DRM_DEV_WARN macro in drm/rockchip to replace dev_warn. Wambui Karuga (2): drm/print: add DRM_DEV_WARN macro drm/rockchip: use DRM_DEV_WARN macro in debug output

[PATCH 2/2] drm/rockchip: use DRM_DEV_WARN macro in debug output

2019-11-15 Thread Wambui Karuga
Replace the use of dev_warn in debug output with the new DRM specific DRM_DEV_WARN debug output macro to maintain consistency across the driver. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/rockchip/inno_hdmi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers

[PATCH] drm/panel: declare variable as __be16

2019-12-31 Thread Wambui Karuga
/gpu/drm/panel/panel-lg-lg4573.c:45:20:got restricted __be16 [usertype] Signed-off-by: Wambui Karuga --- drivers/gpu/drm/panel/panel-lg-lg4573.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-lg-lg4573.c b/drivers/gpu/drm/panel/panel-lg-lg4573

[PATCH] drm/msm: use BUG_ON macro for debugging.

2019-12-31 Thread Wambui Karuga
As the if statement only checks for the value of the offset_name variable, it can be replaced by the more conscise BUG_ON macro for error reporting. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/msm/adreno/adreno_gpu.h | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a

[PATCH] drm/nouveau: use NULL for pointer assignment.

2019-12-31 Thread Wambui Karuga
Replace the use of 0 in the pointer assignment with NULL to address the following sparse warning: drivers/gpu/drm/nouveau/nouveau_hwmon.c:744:29: warning: Using plain integer as NULL pointer Signed-off-by: Wambui Karuga --- drivers/gpu/drm/nouveau/nouveau_hwmon.c | 2 +- 1 file changed, 1

[PATCH] drm/nouveau: remove set but unused variable.

2019-12-31 Thread Wambui Karuga
The local variable `pclks` is defined and set but not used and can therefore be removed. Issue found by coccinelle. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/nouveau/dispnv04/arb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/nouveau/dispnv04

[PATCH] drm/nouveau: declare constants as unsigned long.

2019-12-31 Thread Wambui Karuga
Explicitly declare constants are unsigned long to address the following sparse warnings: warning: constant is so big it is long Signed-off-by: Wambui Karuga --- drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgf100.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgf108.c | 2 +- drivers/gpu/drm

Re: [PATCH] drm/nouveau: declare constants as unsigned long.

2020-01-01 Thread Wambui Karuga
On Tue, Dec 31, 2019 at 06:53:55PM -0500, Ilia Mirkin wrote: > Probably want ULL for 32-bit arches to be correct here too. > Okay, I can convert them to ULL and send a v2. Thanks, wambui. > On Tue, Dec 31, 2019 at 3:53 PM Wambui Karuga > wrote: > > > > Explicit

[PATCH] drm/omapdrm: use BUG_ON macro for error debugging.

2020-01-02 Thread Wambui Karuga
Since the if statement only checks for the value of the `id` variable, it can be replaced by the more concise BUG_ON() macro for error reporting. Issue found using coccinelle. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/omapdrm/dss/dispc.c | 3 +-- 1 file changed, 1 insertion(+), 2

[PATCH] drm/i915: remove boolean comparisons in conditionals.

2020-01-02 Thread Wambui Karuga
Remove unnecessary comparisons to true/false in if statements. Issues found by coccinelle. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/display/intel_ddi.c | 2 +- drivers/gpu/drm/i915/display/intel_dp.c | 2 +- drivers/gpu/drm/i915/display/intel_sdvo.c | 4 ++-- 3 files changed, 4

[PATCH] drm/radeon: remove unnecessary braces around conditionals.

2020-01-04 Thread Wambui Karuga
As single statement conditionals do not need to be wrapped around braces, the unnecessary braces can be removed. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/radeon/atombios_crtc.c | 3 +-- drivers/gpu/drm/radeon/atombios_dp.c | 3 +-- drivers/gpu/drm/radeon/atombios_encoders.c

[PATCH v2] drm/nouveau: declare constants as unsigned long long.

2020-01-04 Thread Wambui Karuga
Explicitly declare constants as unsigned long long to address the following sparse warnings: warning: constant is so big it is long v2: convert to unsigned long long for compatibility with 32-bit architectures. Signed-off-by: Wambui Karuga Suggested by: lia Mirkin --- drivers/gpu/drm/nouveau

[PATCH] drm/radeon: remove boolean checks in if statements.

2020-01-04 Thread Wambui Karuga
Remove unnecessary variable comparisions to true/false in if statements and check the value of the variable directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/radeon/cik_sdma.c | 2 +- drivers/gpu/drm/radeon/r100.c | 2 +- drivers/gpu/drm/radeon/r600.c

[PATCH] drm/amd: use list_for_each_entry for list iteration.

2020-01-04 Thread Wambui Karuga
list_for_each() can be replaced by the more concise list_for_each_entry() here for iteration over the lists. This change was reported by coccinelle. Signed-off-by: Wambui Karuga --- .../drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c | 19 --- 1 file changed, 4 insertions(+), 15

[PATCH] drm/sun4i: use PTR_ERR_OR_ZERO macro.

2020-01-07 Thread Wambui Karuga
Replace the use of IS_ERR and PTR_ZERO macros by returning the PTR_ERR_OR_ZERO macro. Changes suggested by coccinelle. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/sun4i/sun4i_dotclock.c | 4 +--- drivers/gpu/drm/sun4i/sun4i_hdmi_ddc_clk.c | 4 +--- drivers/gpu/drm/sun4i

[PATCH 3/5] drm/i915: use new struct drm_device based logging macros.

2020-01-08 Thread Wambui Karuga
Replace instances of printk based logging macros with the new struct drm_device logging macros in i915/intel_region_lmem.c. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_region_lmem.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 0/5] drm/i915: conversion to new drm logging macros.

2020-01-08 Thread Wambui Karuga
This series begins the conversion to using the new struct drm_device based logging macros in drm/i915. Wambui Karuga (5): drm/i915: convert to using the drm_dbg_kms() macro. drm/i915: use new struct drm_device logging macros. drm/i915: use new struct drm_device based logging macros. drm

[PATCH 1/5] drm/i915: convert to using the drm_dbg_kms() macro.

2020-01-08 Thread Wambui Karuga
Convert the use of the DRM_DEBUG_KMS() logging macro to the new struct drm_device based drm_dbg_kms() logging macro in i915/intel_pch.c. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_pch.c | 46 +--- 1 file changed, 24 insertions(+), 22 deletions

[PATCH 4/5] drm/i915: convert to using new struct drm_device logging macros

2020-01-08 Thread Wambui Karuga
Replace the use of printk based debugging macros with the struct drm_device based logging macros in i915/intel_sideband.c. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_sideband.c | 29 --- 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a

Re: [PATCH] drm/sun4i: use PTR_ERR_OR_ZERO macro.

2020-01-08 Thread Wambui Karuga
On Tue, 7 Jan 2020, Maxime Ripard wrote: Hi, On Mon, Jan 06, 2020 at 05:00:52PM +0300, Wambui Karuga wrote: Replace the use of IS_ERR and PTR_ZERO macros by returning the PTR_ERR_OR_ZERO macro. Changes suggested by coccinelle. Signed-off-by: Wambui Karuga Unfortunately, that patch came

[PATCH 2/5] drm/i915: use new struct drm_device logging macros.

2020-01-08 Thread Wambui Karuga
This converts various instances of the struct device and printk based logging macros with the new struct drm_device based logging macros in i915/intel_pm.c Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_pm.c | 351 ++-- 1 file changed, 194 insertions

[PATCH 5/5] drm/i915: use new struct drm_device based macros.

2020-01-08 Thread Wambui Karuga
Convert to the use of new struct drm_device based logging macros to replace the use of the printk based macros in i915/intel_uncore.c Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_uncore.c | 25 + 1 file changed, 13 insertions(+), 12 deletions(-) diff

[PATCH] drm/rockchip: use DIV_ROUND_UP macro for calculations.

2020-01-09 Thread Wambui Karuga
Replace the open coded calculation with the more concise and readable DIV_ROUND_UP macro. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/rockchip/rockchip_drm_vop.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.h b/drivers/gpu

[PATCH 3/5] drm/i915: conversion to new logging macros in i915/intel_device_info.c

2020-01-09 Thread Wambui Karuga
This replaces the printk and struct device based logging macros with the new struct drm_device style based logging macros i915/intel_device_info.c. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_device_info.c | 25 +--- 1 file changed, 14 insertions(+), 11

[PATCH v2] drm/msm: use BUG_ON macro for debugging.

2020-01-09 Thread Wambui Karuga
As the if statement only checks for the value of the offset_name variable, it can be replaced by the more conscise BUG_ON macro for error reporting. v2: format expression to less than 80 characters for each line. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/msm/adreno/adreno_gpu.h | 6

[PATCH 4/5] drm/i915: convert to new logging macros in i915/intel_gvt.c

2020-01-09 Thread Wambui Karuga
This converts the use of printk based logging macros in i915/intel_gvt.c with the new struct drm_device based logging macros. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_gvt.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/i915

[PATCH 1/5] drm/i915: conversion to new logging macros in i915/i915_vgpu.c

2020-01-09 Thread Wambui Karuga
Replace the use of printk based logging macros with the struct drm_device based macros in i915/i915_vgpu.c Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/i915_vgpu.c | 41 +++- 1 file changed, 25 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 2/5] drm/i915: conversion to new logging macros in i915/intel_csr.c

2020-01-09 Thread Wambui Karuga
Replace the use of printk and struct device based logging macros with the new struct drm_device based logging macros in i915/intel_csr.c Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_csr.c | 24 ++-- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git

[PATCH 5/5] drm/i915: convert to new logging macros in i915/intel_memory_region.c

2020-01-09 Thread Wambui Karuga
Replace the use of printk based logging macros with the new struct drm_device based logging macro in i915/intel_memory_region.c. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/intel_memory_region.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm

[PATCH] drm: remove unnecessary return variable

2019-10-19 Thread Wambui Karuga
From: Wambui Karuga Remove unnecessary variable `ret` in drm_dp_atomic_find_vcpi_slots() only used to hold the function return value and have the function return the value directly. Issue found by coccinelle: @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret

[PATCH] drm/amd/amdgpu: make undeclared variables static

2019-10-19 Thread Wambui Karuga
v.c:117:18: warning: symbol 'amdgpu_exp_hw_support' was not declared. Should it be static? Signed-off-by: Wambui Karuga --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/driver

[PATCH] drm/radeon: remove assignment for return value

2019-10-19 Thread Wambui Karuga
Remove unnecessary assignment for return value and have the function return the required value directly. Issue found by coccinelle: @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Wambui Karuga --- drivers/gpu/drm/radeon/cik.c | 8 ++-- 1 file

[PATCH] drm/amd/amdgpu: correct length misspelling

2019-10-19 Thread Wambui Karuga
Correct the "_LENTH" mispelling in the AMDGPU_MAX_TIMEOUT_PARAM_LENGTH constant. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/g

[Outreachy][PATCH] drm/mediatek: remove cast to pointers passed to kfree

2019-10-23 Thread Wambui Karuga
Remove unnecessary casts to pointer types passed to kfree. Issue detected by coccinelle: @@ type t1; expression *e; @@ -kfree((t1 *)e); +kfree(e); Signed-off-by: Wambui Karuga --- drivers/gpu/drm/mediatek/mtk_drm_gem.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[PATCH] drm/nouveau: remove checks for return value of debugfs functions

2020-02-19 Thread Wambui Karuga
As there is no need to check for the return value of debugfs_create_file and drm_debugfs_create_files, remove unnecessary checks and error handling in nouveau_drm_debugfs_init. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 20 1 file changed

[PATCH] drm/arc: make arcpgu_debugfs_init return 0

2020-02-19 Thread Wambui Karuga
As drm_debugfs_create_files should return void, remove its use as the return value of arcpgu_debugfs_init and have the latter function return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/arc/arcpgu_drv.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a

[PATCH] drm/tilcdc: remove check for return value of debugfs functions.

2020-02-19 Thread Wambui Karuga
Remove the check and error handling of the return value of drm_debugfs_create_files as it is not needed in tilcdc_debugfs_init. Also remove local variables that are not used after the changes. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tilcdc/tilcdc_drv.c | 15 --- 1 file

[PATCH] drm/tegra: remove checks for debugfs functions return value

2020-02-19 Thread Wambui Karuga
Remove the return checks and error handling of the drm_debugfs_create_files function from various debugfs init functions in drm/tegra and have them return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tegra/dc.c | 11 +-- drivers/gpu/drm/tegra/drm.c | 7

[PATCH 1/2] drm/debugfs: remove checks for return value of drm_debugfs functions.

2020-02-19 Thread Wambui Karuga
As there is no need to check the return value of drm_debugfs_create_files, remove unnecessary checks and error handling statement blocks. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_debugfs.c | 28 +--- 1 file changed, 5 insertions(+), 23 deletions(-) diff

[PATCH] drm/vc4: remove check of return value of drm_debugfs functions

2020-02-19 Thread Wambui Karuga
Remove unnecessary check and error handling for the return value of drm_debugfs_create_files in vc4_debugfs_init. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/vc4/vc4_debugfs.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_debugfs.c b

Re: [PATCH] drm/etnaviv: remove check for return value of drm_debugfs function

2020-02-19 Thread Wambui Karuga
On Tue, 18 Feb 2020, Lucas Stach wrote: On Di, 2020-02-18 at 20:28 +0300, Wambui Karuga wrote: As there is no need to check the return value if drm_debugfs_create_files, And here is where the commit message skips a very important information: Since 987d65d01356 (drm: debugfs: make

[PATCH] drm/v3d: make v3d_debugfs_init return 0

2020-02-19 Thread Wambui Karuga
As drm_debugfs_create_files should return void, remove its use as the return value of v3d_debugfs_init and have the function return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/v3d/v3d_debugfs.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers

[PATCH] drm/etnaviv: remove check for return value of drm_debugfs function

2020-02-19 Thread Wambui Karuga
As there is no need to check the return value if drm_debugfs_create_files, remove the check and error handling in etnaviv_debugfs_init and have the function return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 16 1 file changed, 4

[PATCH 2/2] drm: convert drm_debugfs functions to return void

2020-02-19 Thread Wambui Karuga
As drm_debug_create_files will be converted to return void, drop return value from various drm_debugfs functions that return drm_debug_create_files and convert the functions to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_atomic.c| 8 drivers/gpu/drm

[PATCH] drm/vram-helper: make drm_vram_mm_debugfs_init return 0

2020-02-19 Thread Wambui Karuga
As drm_debugfs_create_files() should return 0, remove its use as the return value of drm_vram_mm_debugfs_init(), and have the function return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_gem_vram_helper.c | 13 + 1 file changed, 5 insertions(+), 8 deletions

[PATCH] drm/arm: make hdlcd_debugfs_init return 0

2020-02-19 Thread Wambui Karuga
As drm_debugfs_create_files should return void, remove its use as a return value in hdlcd_debugfs_init and have the latter function return 0 directly. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/arm/hdlcd_drv.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a

[PATCH] drm/i915: make i915_debugfs_register return void.

2020-02-19 Thread Wambui Karuga
As drm_debugfs_create_files should return void, remove its use as the return value of i915_debugfs_register and have i915_debugfs_register return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/i915_debugfs.c | 8 drivers/gpu/drm/i915/i915_debugfs.h | 4 ++-- 2 files

[PATCH 04/21] drm/vram-helper: make drm_vram_mm_debugfs_init() return void

2020-02-27 Thread Wambui Karuga
Since 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files() never fails and should return void. Therefore, remove its use as the return value of drm_vram_mm_debugfs_init(), and have the function declared as void instead. Signed-off-by: Wambui Karuga

[PATCH 08/21] drm/etnaviv: remove check for return value of drm_debugfs function

2020-02-27 Thread Wambui Karuga
. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 18 -- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_drv.c b/drivers/gpu/drm/etnaviv/etnaviv_drv.c index 6b43c1c94e8f..a39735316ca5 100644 --- a/drivers/gpu

[PATCH 19/21] drm/mipi_dbi: make midi_dbi_debugfs_init() return void.

2020-02-27 Thread Wambui Karuga
As midi_dbi_debugfs_init() never fails and does not return anything other than zero, declare its return value as void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_mipi_dbi.c | 6 +- include/drm/drm_mipi_dbi.h | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git

[PATCH 02/21] drm: convert the drm_driver.debugfs_init() hook to return void.

2020-02-27 Thread Wambui Karuga
-by: Wambui Karuga --- include/drm/drm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h index 97109df5beac..c6ae888c672b 100644 --- a/include/drm/drm_drv.h +++ b/include/drm/drm_drv.h @@ -323,7 +323,7 @@ struct drm_driver

[PATCH 21/21] drm/arm: have malidp_debufs_init() return void

2020-02-27 Thread Wambui Karuga
As there's no need for the return value in malidp_debugfs_init() after the conversion of the drm_driver.debugfs_init() hook, (drm: convert the .debugs_init() hook to return void), convert the malidp_debugfs_init() function to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/dr

[PATCH 07/21] drm/arm: make hdlcd_debugfs_init() return void

2020-02-27 Thread Wambui Karuga
Since commit 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files() never fails, and should return void. Therefore, remove its use as a return value in hdlcd_debugfs_init and have the latter function return void. Signed-off-by: Wambui Karuga

[PATCH 13/21] drm/omapdrm: remove checks for return value of drm_debugfs functions.

2020-02-27 Thread Wambui Karuga
changing of omap_debugfs_init() to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/omapdrm/omap_debugfs.c | 29 +++--- drivers/gpu/drm/omapdrm/omap_drv.h | 2 +- 2 files changed, 8 insertions(+), 23 deletions(-) diff --git a/drivers/gpu/drm/omapdrm

[PATCH 05/21] drm/vc4: remove check of return value of drm_debugfs functions

2020-02-27 Thread Wambui Karuga
vc4_debugfs_init() to be declared as void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/vc4/vc4_debugfs.c | 11 +++ drivers/gpu/drm/vc4/vc4_drv.h | 2 +- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_debugfs.c b/drivers/gpu/drm/vc4

[PATCH 17/21] drm/tilcdc: remove check for return value of debugfs functions.

2020-02-27 Thread Wambui Karuga
are not used after the changes, and declare tilcdc_debugfs_init() as void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tilcdc/tilcdc_drv.c | 17 - 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm/tilcdc/tilcdc_drv.c b/drivers/gpu/drm/tilcdc

[PATCH 00/21] drm: subsytem-wide debugfs functions refactor

2020-02-27 Thread Wambui Karuga
the left over error handling and checks for its return value across drm drivers. As a result of these changes, most drm_debugfs functions are converted to return void in this series. This also enables the drm_driver,debugfs_init() hook to be changed to return void. Wambui Karuga (21): drm

Re: [PATCH 02/21] drm: convert the drm_driver.debugfs_init() hook to return void.

2020-02-27 Thread Wambui Karuga
On Thu, 27 Feb 2020, Greg KH wrote: On Thu, Feb 27, 2020 at 03:02:13PM +0300, Wambui Karuga wrote: As a result of commit 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail) and changes to various debugfs functions in drm/core and across various drivers, there is no need

[PATCH 18/21] drm/virtio: make virtio_gpu_debugfs() return void.

2020-02-27 Thread Wambui Karuga
Since 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files() never fails and should return void. Therefore, remove its use as the return value of virtio_gpu_debugfs() and have the latter function return void. Signed-off-by: Wambui Karuga --- drivers

[PATCH 11/21] drm/v3d: make v3d_debugfs_init return void

2020-02-27 Thread Wambui Karuga
Since commit 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files() never fails and should return void. Therefore, remove its use as the return value of v3d_debugfs_init and have the function return void instead. Signed-off-by: Wambui Karuga

[PATCH 01/21] drm/debugfs: remove checks for return value of drm_debugfs functions.

2020-02-27 Thread Wambui Karuga
drm_debugfs_create_files() to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_debugfs.c | 49 --- include/drm/drm_debugfs.h | 6 ++--- 2 files changed, 14 insertions(+), 41 deletions(-) diff --git a/drivers/gpu/drm/drm_debugfs.c b/drivers/gpu/drm

[PATCH 12/21] drm/msm: remove checks for return value of drm_debugfs functions.

2020-02-27 Thread Wambui Karuga
various debugfs_init() functions to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/msm/adreno/a5xx_debugfs.c | 18 +- drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 14 +++--- drivers/gpu/drm/msm/msm_debugfs.c | 21 ++--- drivers/gpu/drm

[PATCH 03/21] drm: convert drm_debugfs functions to return void

2020-02-27 Thread Wambui Karuga
: Wambui Karuga --- drivers/gpu/drm/drm_atomic.c| 8 drivers/gpu/drm/drm_client.c| 8 drivers/gpu/drm/drm_crtc_internal.h | 2 +- drivers/gpu/drm/drm_framebuffer.c | 8 drivers/gpu/drm/drm_internal.h | 2 +- include/drm/drm_client.h| 2

Re: [PATCH 17/21] drm/tilcdc: remove check for return value of debugfs functions.

2020-02-27 Thread Wambui Karuga
On Thu, 27 Feb 2020, Jyri Sarha wrote: On 27/02/2020 14:02, Wambui Karuga wrote: Since 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files() never fails. Therefore, remove the check and error handling of the return value of

[PATCH 10/21] drm/tegra: remove checks for debugfs functions return value

2020-02-27 Thread Wambui Karuga
and have them return 0 directly. This change also includes removing the use of drm_debugfs_create_files as a return value in tegra_debugfs_init() and have the function declared as void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tegra/dc.c | 11 +-- drivers/gpu/drm/tegra/drm.c

[PATCH 06/21] drm/arc: make arcpgu_debugfs_init return void

2020-02-27 Thread Wambui Karuga
Since commit 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail), drm_debugfs_create_files never fails and should return void. Therefore, remove its use as the return value of arcpgu_debugfs_init and have the latter function also return void. Signed-off-by: Wambui Karuga

[PATCH 15/21] drm/sti: remove use drm_debugfs functions as return value

2020-02-27 Thread Wambui Karuga
changed to use a void return value. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/sti/sti_cursor.c | 14 -- drivers/gpu/drm/sti/sti_drv.c| 16 drivers/gpu/drm/sti/sti_dvo.c| 13 + drivers/gpu/drm/sti/sti_gdp.c| 7 --- drivers/gpu/drm/sti

[PATCH 14/21] drm/pl111: make pl111_debugfs_init return void

2020-02-27 Thread Wambui Karuga
Since 987d65d01356 (drm: debugfs: make drm_debugfs_create_files() never fail) drm_debugfs_create_files() should return void. Therefore, remove its use as the return value in pl111_debugfs_init, and have the function declared as void instead. Signed-off-by: Wambui Karuga --- drivers/gpu/drm

[PATCH 09/21] drm/nouveau: remove checks for return value of debugfs functions

2020-02-27 Thread Wambui Karuga
enable nouveau_drm_debugfs_init() to be declared as void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/nouveau/nouveau_debugfs.c | 26 +-- drivers/gpu/drm/nouveau/nouveau_debugfs.h | 5 ++--- 2 files changed, 12 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 20/21] drm/qxl: have debugfs functions return void.

2020-02-27 Thread Wambui Karuga
can be converted to return void as a result of the changes to qxl_debugfs_init(). Signed-off-by: Wambui Karuga --- drivers/gpu/drm/qxl/qxl_debugfs.c | 21 +++-- drivers/gpu/drm/qxl/qxl_drv.h | 13 + drivers/gpu/drm/qxl/qxl_ttm.c | 6 ++ 3 files changed

[PATCH 16/21] drm/i915: make *_debugfs_register() functions return void.

2020-02-27 Thread Wambui Karuga
-off-by: Wambui Karuga --- drivers/gpu/drm/i915/display/intel_display_debugfs.c | 8 drivers/gpu/drm/i915/display/intel_display_debugfs.h | 4 ++-- drivers/gpu/drm/i915/i915_debugfs.c | 8 drivers/gpu/drm/i915/i915_debugfs.h | 4 ++-- 4 files

[PATCH v2 11/17] drm/nouveau: make nouveau_drm_debugfs_init() return 0

2020-03-10 Thread Wambui Karuga
function return 0 directly. v2: have nouveau_drm_debugfs_init() return 0 instead of void so as not to introduce any build warnings to enable individual patch compilation. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu

[PATCH v2 07/17] drm/etnaviv: remove check for return value of drm_debugfs_create_files()

2020-03-10 Thread Wambui Karuga
: have etnaviv_debugfs_init() return 0 instead of void to ensure individual compilation and avoid build breakage. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/etnaviv/etnaviv_drv.c | 16 1

[PATCH v2 00/17] drm: subsytem-wide debugfs functions refactor

2020-03-10 Thread Wambui Karuga
have been converted to have debugfs functions return 0 instead of void to prevent breaking individual driver builds. The last patch then converts the .debugfs_hook() and its users across all drivers to return void. Wambui Karuga (17): drm/tegra: remove checks for debugfs functions return value

[PATCH v2 09/17] drm/sti: remove use of drm_debugfs functions as return values

2020-03-10 Thread Wambui Karuga
: Wambui Karuga --- drivers/gpu/drm/sti/sti_compositor.c | 6 ++ drivers/gpu/drm/sti/sti_compositor.h | 4 ++-- drivers/gpu/drm/sti/sti_crtc.c | 2 +- drivers/gpu/drm/sti/sti_cursor.c | 14 -- drivers/gpu/drm/sti/sti_drv.c| 13 +++-- drivers/gpu/drm/sti

[PATCH v2 05/17] drm/arc: make arcgpu_debugfs_init() return 0.

2020-03-10 Thread Wambui Karuga
return 0 instead of void to avoid breaking the build and ensure that this individual patch compiles properly. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/arc/arcpgu_drv.c | 6 -- 1 file changed, 4

[PATCH v2 08/17] drm/msm: remove checks for return value of drm_debugfs_create_files()

2020-03-10 Thread Wambui Karuga
directly. v2: have debug functions return 0 instead of void to avoid build breakage and ensure standalone compilation. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/msm/adreno/a5xx_debugfs.c | 12

[PATCH v2 03/17] drm/v3d: make v3d_debugfs_init() return 0

2020-03-10 Thread Wambui Karuga
v3d_debugfs_init() to void to avoid build breakage and enable individual compilation. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/v3d/v3d_debugfs.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions

[PATCH v2 13/17] drm/omap: remove checks for return value of drm_debugfs functions

2020-03-10 Thread Wambui Karuga
: Wambui Karuga --- drivers/gpu/drm/omapdrm/omap_debugfs.c | 27 +++--- 1 file changed, 7 insertions(+), 20 deletions(-) diff --git a/drivers/gpu/drm/omapdrm/omap_debugfs.c b/drivers/gpu/drm/omapdrm/omap_debugfs.c index 34dfb33145b4..ed63dcced79a 100644 --- a/drivers/gpu/drm/omapdrm

[PATCH v2 02/17] drm/tilcdc: remove check for return value of debugfs functions.

2020-03-10 Thread Wambui Karuga
are not used after the changes. v2: remove conversion of tilcdc_debugfs_init() to void to avoid build breakage and enable individual compilation. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tilcdc

[PATCH v2 10/17] drm/vram-helper: make drm_vram_mm_debugfs_init() return 0

2020-03-10 Thread Wambui Karuga
() return 0 instead of void to avoid introducing build issues and build breakage. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga Acked-by: Thomas Zimmermann --- drivers/gpu/drm/drm_gem_vram_helper.c | 10 -- 1 file changed

[PATCH v2 14/17] drm/i915: have *_debugfs_init() functions return void.

2020-03-10 Thread Wambui Karuga
intel_display_debugfs_register() stub to return void too. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/i915/display/intel_display_debugfs.c | 8 drivers/gpu/drm/i915/display/intel_display_debugfs.h | 4 ++-- drivers/gpu/drm/i915/i915_debugfs.c | 8 drivers/gpu/drm/i915/i915_debugfs.h

[PATCH v2 12/17] drm/pl111: make pl111_debugfs_init return 0

2020-03-10 Thread Wambui Karuga
avoid build breakage for individual compilation. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/pl111/pl111_debugfs.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm

[PATCH v2 01/17] drm/tegra: remove checks for debugfs functions return value

2020-03-10 Thread Wambui Karuga
and have them return 0 directly. v2: remove conversion of tegra_debugfs_init() to void to avoid build breakage. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/tegra/dc.c | 11 +-- drivers/gpu/drm

[PATCH v2 16/17] drm/debugfs: remove checks for return value of drm_debugfs functions.

2020-03-10 Thread Wambui Karuga
drm_debugfs_create_files() to return void. Signed-off-by: Wambui Karuga --- drivers/gpu/drm/drm_debugfs.c | 33 +++-- include/drm/drm_debugfs.h | 16 +++- 2 files changed, 14 insertions(+), 35 deletions(-) diff --git a/drivers/gpu/drm/drm_debugfs.c b/drivers

[PATCH v2 04/17] drm/vc4: remove check of return value of drm_debugfs functions

2020-03-10 Thread Wambui Karuga
vc4_debugfs_init() to void to enable individual compilation and avoid build issues and breakage. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/vc4/vc4_debugfs.c | 7 ++- 1 file changed, 2 insertions

[PATCH v2 06/17] drm/arm: make hdlcd_debugfs_init() return 0

2020-03-10 Thread Wambui Karuga
() return 0 instead of void to ensure that each patch compiles individually. References: https://lists.freedesktop.org/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/arm/hdlcd_drv.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff

[PATCH v2 17/17] drm: convert .debugfs_init() hook to return void.

2020-03-10 Thread Wambui Karuga
/archives/dri-devel/2020-February/257183.html Signed-off-by: Wambui Karuga --- drivers/gpu/drm/arc/arcpgu_drv.c | 3 +-- drivers/gpu/drm/arm/hdlcd_drv.c | 3 +-- drivers/gpu/drm/arm/malidp_drv.c | 3 +-- drivers/gpu/drm/drm_atomic.c | 3 +-- drivers/gpu/drm

  1   2   >