Re: [Intel-gfx] [PATCH] drm/i915/gt: Avoid redundant pointer validity check

2023-02-06 Thread Deepak R Varma
On Tue, Feb 07, 2023 at 12:12:18AM +0530, Deepak R Varma wrote: > On Mon, Feb 06, 2023 at 10:33:13AM +, Matthew Auld wrote: > > On 06/02/2023 09:45, Tvrtko Ursulin wrote: > > > > > > Hi, > > > > > > Adding Matt & Thomas as pot

Re: [Intel-gfx] [PATCH] drm/i915/gt: Avoid redundant pointer validity check

2023-02-06 Thread Deepak R Varma
On Mon, Feb 06, 2023 at 10:33:13AM +, Matthew Auld wrote: > On 06/02/2023 09:45, Tvrtko Ursulin wrote: > > > > Hi, > > > > Adding Matt & Thomas as potential candidates to review. > > > > Regards, > > > > Tvrtko > > > > On

[Intel-gfx] [PATCH] drm/i915/gt: Avoid redundant pointer validity check

2023-02-03 Thread Deepak R Varma
The macro definition of gen6_for_all_pdes() expands to a for loop such that it breaks when the page table is null. Hence there is no need to again test validity of the page table entry pointers in the pde list. This change is identified using itnull.cocci semantic patch. Signed-off-by: Deepak R

[Intel-gfx] [PATCH v2] drm/i915/gvt: Avoid full proxy f_ops for debugfs attributes

2023-01-18 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma Reviewed-by: Rodrigo Vivi Acked-by: Zhenyu Wang --- Changes in v2: - Following changes as suggested by Rodrigo Vivi - Combine 2 patch series in a single patch - Base the patch on the i915/gvt to avoid

Re: [Intel-gfx] [PATCH 2/2] drm/i915/gvt: Avoid full proxy f_ops for vgpu_status debug attributes

2023-01-17 Thread Deepak R Varma
On Tue, Jan 17, 2023 at 02:29:37PM -0500, Rodrigo Vivi wrote: > On Mon, Jan 16, 2023 at 01:44:46PM +0800, Zhenyu Wang wrote: > > On 2023.01.10 13:49:57 -0500, Rodrigo Vivi wrote: > > > On Wed, Jan 11, 2023 at 12:00:12AM +0530, Deepak R Varma wrote: > > > > Using DEFI

Re: [Intel-gfx] [PATCH] drm/i915/display: Convert i9xx_pipe_crc_auto_source to void

2023-01-17 Thread Deepak R Varma
On Tue, Jan 17, 2023 at 02:21:59PM -0500, Rodrigo Vivi wrote: > On Sat, Jan 14, 2023 at 07:33:53PM +0530, Deepak R Varma wrote: > > Convert function i9xx_pipe_crc_auto_source() to return void instead > > of int since the current implementation always returns 0 to the caller. >

[Intel-gfx] [PATCH] drm/i915/gvt: Remove extra semicolon

2023-01-14 Thread Deepak R Varma
Remove the extra semicolon at end. Issue identified using semicolon.cocci Coccinelle semantic patch. Signed-off-by: Deepak R Varma --- drivers/gpu/drm/i915/gvt/vgpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/gvt/vgpu.c b/drivers/gpu/drm/i915/gvt

[Intel-gfx] [PATCH] drm/i915/display: Convert i9xx_pipe_crc_auto_source to void

2023-01-14 Thread Deepak R Varma
Convert function i9xx_pipe_crc_auto_source() to return void instead of int since the current implementation always returns 0 to the caller. Issue identified using returnvar Coccinelle semantic patch. Signed-off-by: Deepak R Varma --- Please note: The change is compile tested only. drivers/gpu

[Intel-gfx] [PATCH v3 2/2] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-11 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- Changes in v3: - None Changes in v2: - Include coccicheck make command in the patch log message for clarity. Suggested by Rodrigo Vivi drivers/gpu/drm/i915/display/intel_fbc.c | 12 ++-- 1 file

[Intel-gfx] [PATCH v3 1/2] drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes

2023-01-11 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- Changes in v3: - Fix checkpatch complaint around function parameter alignment Changes in v2: - Include coccicheck make command in the patch log message for clarity. Suggested by Rodrigo Vivi drivers/gpu

[Intel-gfx] [PATCH v3 0/2] drm/i915: Avoid full proxy f_ops debug attributes

2023-01-11 Thread Deepak R Varma
eter alignment complaint Patch 2/2: None Changes in v2: - Individual patches clubbed in patch set - Update patch log message to include coccicheck make command Deepak R Varma (2): drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes drm/i915/fbc: Avoid full proxy f_ops

Re: [Intel-gfx] [PATCH 2/2] drm/i915/gvt: Avoid full proxy f_ops for vgpu_status debug attributes

2023-01-11 Thread Deepak R Varma
On Wed, Jan 11, 2023 at 10:00:11AM -0500, Rodrigo Vivi wrote: > > > Actually, could you please address the checkpatch issues before we can > > > push? > > > Sorry about that, but just noticed now when I was going to push the other > > > ones. > > > > Hello Rodrigo, > > The checkpatch warning is

Re: [Intel-gfx] [PATCH v2 2/2] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-11 Thread Deepak R Varma
On Tue, Jan 10, 2023 at 01:52:05PM -0500, Rodrigo Vivi wrote: > On Tue, Jan 10, 2023 at 11:45:40PM +0530, Deepak R Varma wrote: > > Using DEFINE_SIMPLE_ATTRIBUTE macro with the debugfs_create_file() > > function adds the overhead of introducing a proxy file operation > >

Re: [Intel-gfx] [PATCH 2/2] drm/i915/gvt: Avoid full proxy f_ops for vgpu_status debug attributes

2023-01-11 Thread Deepak R Varma
On Wed, Jan 11, 2023 at 05:02:02AM -0500, Rodrigo Vivi wrote: > On Tue, Jan 10, 2023 at 01:49:57PM -0500, Rodrigo Vivi wrote: > > On Wed, Jan 11, 2023 at 12:00:12AM +0530, Deepak R Varma wrote: > > > Using DEFINE_SIMPLE_ATTRIBUTE macro with the debugfs_create_file() >

[Intel-gfx] [PATCH 2/2] drm/i915/gvt: Avoid full proxy f_ops for vgpu_status debug attributes

2023-01-10 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- drivers/gpu/drm/i915/gvt/debugfs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/gvt/debugfs.c b/drivers/gpu/drm/i915/gvt/debugfs.c index 03f081c3d9a4..baccbf1761b7

[Intel-gfx] [PATCH 1/2] drm/i915/gvt: Avoid full proxy f_ops for scan_nonprivbb debug attributes

2023-01-10 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- drivers/gpu/drm/i915/gvt/debugfs.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/i915/gvt/debugfs.c b/drivers/gpu/drm/i915/gvt/debugfs.c index 0616b73175f3

[Intel-gfx] [PATCH 0/2] drm/i915/gvt: Avoid full proxy f_ops debug attributes

2023-01-10 Thread Deepak R Varma
for the scan_nonprivbb and vgpu_status f_ops debugfs attributes respectively. Following coccicheck make command helped identify this change: make coccicheck M=drivers/gpu/drm/i915/ MODE=patch COCCI=./scripts/coccinelle/api/debugfs/debugfs_simple_attr.cocci Deepak R Varma (2): drm/i915

[Intel-gfx] [PATCH v2 2/2] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-10 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- Changes in v2: - Include coccicheck make command in the patch log message for clarity. Suggested by Rodrigo Vivi drivers/gpu/drm/i915/display/intel_fbc.c | 12 ++-- 1 file changed, 6 insertions(+), 6

[Intel-gfx] [PATCH v2 1/2] drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes

2023-01-10 Thread Deepak R Varma
/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- Changes in v2: - Include coccicheck make command in the patch log message for clarity. Suggested by Rodrigo Vivi drivers/gpu/drm/i915/display/intel_drrs.c | 8 1 file changed, 4 insertions(+), 4

[Intel-gfx] [PATCH 0/2 v2] drm/i915: Avoid full proxy f_ops debug attributes

2023-01-10 Thread Deepak R Varma
set - Update patch log message to include coccicheck make command Deepak R Varma (2): drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes drivers/gpu/drm/i915/display/intel_drrs.c | 8 drivers/gpu/drm/

Re: [Intel-gfx] [PATCH] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-09 Thread Deepak R Varma
On Mon, Jan 09, 2023 at 02:06:13PM -0500, Rodrigo Vivi wrote: > On Sun, Jan 08, 2023 at 01:33:41AM +0530, Deepak R Varma wrote: > > On Thu, Jan 05, 2023 at 09:13:35AM +0100, Julia Lawall wrote: > > > > Hi Julia, thanks for helping here. > > > > &g

Re: [Intel-gfx] [PATCH] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-07 Thread Deepak R Varma
On Thu, Jan 05, 2023 at 09:13:35AM +0100, Julia Lawall wrote: > > Hi Julia, thanks for helping here. > > > > So, my question is why this > > > > make coccicheck M=drivers/gpu/drm/i915/ MODE=context > > COCCI=./scripts/coccinelle/api/debugfs/debugfs_simple_attr.cocci > > > > didn't catch this chunc

Re: [Intel-gfx] [PATCH] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2023-01-02 Thread Deepak R Varma
On Wed, Dec 28, 2022 at 06:18:12AM -0500, Rodrigo Vivi wrote: > On Tue, Dec 27, 2022 at 11:36:13PM +0530, Deepak R Varma wrote: > > On Tue, Dec 27, 2022 at 12:13:56PM -0500, Rodrigo Vivi wrote: > > > On Tue, Dec 27, 2022 at 01:30:53PM +0530, Deepak R Varma wr

Re: [Intel-gfx] [PATCH] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2022-12-27 Thread Deepak R Varma
On Tue, Dec 27, 2022 at 12:13:56PM -0500, Rodrigo Vivi wrote: > On Tue, Dec 27, 2022 at 01:30:53PM +0530, Deepak R Varma wrote: > > Using DEFINE_SIMPLE_ATTRIBUTE macro with the debugfs_create_file() > > function adds the overhead of introducing a proxy file operation > >

[Intel-gfx] [PATCH v2 1/2] drm/i915: convert i915_active.count from atomic_t to refcount_t

2022-12-27 Thread Deepak R Varma
atomic_add_unless Signed-off-by: Deepak R Varma --- Please note: 1. Proposed changes are compile tested only. 2. This patch 1/2 is required to be applied before patch 2/2 due to interdependency. Changes in v2: 1. Patch added to the patch series. 2. Handle build issues Reported-by: kernel

[Intel-gfx] [PATCH] drm/i915/fbc: Avoid full proxy f_ops for FBC debug attributes

2022-12-27 Thread Deepak R Varma
protect the original read and write function calls for the debug attributes. There is no need for any runtime proxy file operations to be managed by the debugfs core. This Change is reported by the debugfs_simple_attr.cocci Coccinelle semantic patch. Signed-off-by: Deepak R Varma --- drivers/gpu

[Intel-gfx] [PATCH] drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes

2022-12-27 Thread Deepak R Varma
protect the original read and write function calls for the debug attributes. There is no need for any runtime proxy file operations to be managed by the debugfs core. This Change is reported by the debugfs_simple_attr.cocci Coccinelle semantic patch. Signed-off-by: Deepak R Varma --- drivers/gpu

[Intel-gfx] [PATCH v2 2/2] drm/i915/selftests: Convert atomic_* API calls for i915_active.count refcount_*

2022-12-27 Thread Deepak R Varma
Handle the struct i915_active member variable count transition from atomic_t type to refcount_t type for selftest use cases. Transition the atomic_*() API calls to their equivalent refcount_*() API calls. Reported-by: kernel test robot Signed-off-by: Deepak R Varma --- Please note: 1

[Intel-gfx] [PATCH] drm/i915: convert i915_active.count from atomic_t to refcount_t

2022-12-27 Thread Deepak R Varma
atomic_add_unless Signed-off-by: Deepak R Varma --- Please note: Proposed changes are compile tested only. drivers/gpu/drm/i915/i915_active.c | 24 +--- drivers/gpu/drm/i915/i915_active.h | 6 +++--- drivers/gpu/drm/i915/i915_active_types.h | 4 ++-- 3 files changed, 18

[Intel-gfx] [PATCH v2 0/2] convert i915_active.count from atomic_t to refcount_t

2022-12-27 Thread Deepak R Varma
refcount_* transition. Deepak R Varma (2): drm/i915: convert i915_active.count from atomic_t to refcount_t drm/i915/selftests: Convert atomic_* API calls for i915_active.count refcount_* drivers/gpu/drm/i915/i915_active.c | 28 +++- drivers/gpu/drm/i915

[Intel-gfx] [PATCH v2] drm/vgem: replace idr_init() by idr_init_base()

2020-11-06 Thread Deepak R Varma
Signed-off-by: Deepak R Varma --- Changes since v1: - Changes suggested by Daniel Vetter: 1. Correct typo in patch summary 2. cc intel-gfx to get the patch through CI bot test drivers/gpu/drm/vgem/vgem_fence.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drive

[Intel-gfx] [PATCH] drm/i915/perf: replace idr_init() by idr_init_base()

2020-11-04 Thread Deepak R Varma
Signed-off-by: Deepak R Varma --- drivers/gpu/drm/i915/i915_perf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_perf.c b/drivers/gpu/drm/i915/i915_perf.c index e94976976571..2d033255b7cf 100644 --- a/drivers/gpu/drm/i915/i915_perf.c +++ b/drivers/gp

[Intel-gfx] [PATCH] drm/i915/gvt: replace idr_init() by idr_init_base()

2020-11-04 Thread Deepak R Varma
Signed-off-by: Deepak R Varma --- drivers/gpu/drm/i915/gvt/gvt.c | 2 +- drivers/gpu/drm/i915/gvt/vgpu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/gvt/gvt.c b/drivers/gpu/drm/i915/gvt/gvt.c index c7c561237883..45b492edbb19 100644 --- a/drivers/gp

[Intel-gfx] [PATCH] drm/i915/gvt: use DEFINE_DEBUGFS_ATTRIBUTE with debugfs_create_file_unsafe()

2020-10-30 Thread Deepak R Varma
Issue reported by Coccinelle script: scripts/coccinelle/api/debugfs/debugfs_simple_attr.cocci Signed-off-by: Deepak R Varma --- Please Note: This is a Outreachy project task patch. drivers/gpu/drm/i915/gvt/debugfs.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/