[PATCH] scsi: virtio_scsi: Use struct_size() helper

2019-06-19 Thread Gustavo A. R. Silva
lle. Signed-off-by: Gustavo A. R. Silva --- drivers/scsi/virtio_scsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/virtio_scsi.c b/drivers/scsi/virtio_scsi.c index 13f1b3b9923a..ed4f79bffc73 100644 --- a/drivers/scsi/virtio_scsi.c +++ b/drivers/scsi/virtio_scs

Re: [PATCH][next] drm: Replace zero-length array with flexible-array member

2020-03-03 Thread Gustavo A. R. Silva
On 2/25/20 08:17, Jani Nikula wrote: > On Tue, 25 Feb 2020, "Gustavo A. R. Silva" wrote: >> The current codebase makes use of the zero-length array language >> extension to the C90 standard, but the preferred mechanism to declare >> variable-length types such as

[PATCH][next] drm: Replace zero-length array with flexible-array member

2020-02-25 Thread Gustavo A. R. Silva
[1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/etnaviv/etnaviv_gem.h | 2 +- drivers/gpu/drm/gma500/intel_

[PATCH] drm/qxl: replace zero-length array with flexible-array member

2020-02-12 Thread Gustavo A. R. Silva
[1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/qxl/qxl_cmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[PATCH] char: virtio: Replace zero-length array with flexible-array member

2020-02-11 Thread Gustavo A. R. Silva
of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- drivers/char/virtio_console.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH] vhost: vdpa: remove unnecessary null check

2020-03-30 Thread Gustavo A. R. Silva
container_of is never null, so this null check is unnecessary. Addresses-Coverity-ID: 1492006 ("Logically dead code") Fixes: 20453a45fb06 ("vhost: introduce vDPA-based backend") Signed-off-by: Gustavo A. R. Silva --- drivers/vhost/vdpa.c | 2 -- 1 file changed, 2 dele

Re: [PATCH 000/141] Fix fall-through warnings for Clang

2020-11-20 Thread Gustavo A. R. Silva
Hi, On 11/20/20 12:53, Jakub Kicinski wrote: > On Fri, 20 Nov 2020 12:21:39 -0600 Gustavo A. R. Silva wrote: >> This series aims to fix almost all remaining fall-through warnings in >> order to enable -Wimplicit-fallthrough for Clang. >> >> In preparation to en

Re: [PATCH 000/141] Fix fall-through warnings for Clang

2020-11-20 Thread Gustavo A. R. Silva
On 11/20/20 12:28, Joe Perches wrote: > On Fri, 2020-11-20 at 12:21 -0600, Gustavo A. R. Silva wrote: >> Hi all, >> >> This series aims to fix almost all remaining fall-through warnings in >> order to enable -Wimplicit-fallthrough for Clang. >> >> In prepa

Re: [PATCH 136/141] virtio_net: Fix fall-through warnings for Clang

2021-02-02 Thread Gustavo A. R. Silva
Hi all, Who can take this? :) Thanks -- Gustavo On 11/20/20 12:40, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning > by explicitly adding a goto statement instead of letting the code fall > through to the next case. > &

Re: [PATCH 3/9] drm/i915/selftests: Annotate struct perf_series with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
Airlie Cc: Daniel Vetter Cc: Chris Wilson Cc: John Harrison Cc: Andi Shyti Cc: Matthew Brost Cc: intel-...@lists.freedesktop.org Cc: dri-de...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/i915/selftests

Re: [PATCH 2/9] drm/amdgpu/discovery: Annotate struct ip_hw_instance with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
Cc: David Airlie Cc: Daniel Vetter Cc: Hawking Zhang Cc: amd-...@lists.freedesktop.org Cc: dri-de...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c | 2 +- 1 file changed, 1 insertion(+), 1 del

Re: [PATCH 6/9] drm/vc4: Annotate struct vc4_perfmon with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/vc4/vc4_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/vc4/vc4_drv.h b/drivers/gpu/drm/vc4/vc4_drv.h index bf66499765fb

Re: [PATCH 4/9] drm/msm/dpu: Annotate struct dpu_hw_intr with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
Cc: David Airlie Cc: Daniel Vetter Cc: Bjorn Andersson Cc: linux-arm-...@vger.kernel.org Cc: dri-de...@lists.freedesktop.org Cc: freedr...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/msm/disp/dpu1

Re: [PATCH] virtio_console: Annotate struct port_buffer with __counted_by

2023-09-23 Thread Gustavo A. R. Silva
-foundation.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/char/virtio_console.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 680d1ef2a217..431e9e5bf9c1

Re: [PATCH 7/9] drm/virtio: Annotate struct virtio_gpu_object_array with __counted_by

2023-09-23 Thread Gustavo A. R. Silva
: Daniel Vetter Cc: dri-de...@lists.freedesktop.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/virtio/virtgpu_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers

Re: [PATCH 1/9] drm/amd/pm: Annotate struct smu10_voltage_dependency_table with __counted_by

2023-09-23 Thread Gustavo A. R. Silva
Cc: "Pan, Xinhui" Cc: David Airlie Cc: Daniel Vetter Cc: Xiaojian Du Cc: Huang Rui Cc: Kevin Wang Cc: amd-...@lists.freedesktop.org Cc: dri-de...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/am

Re: [PATCH 8/9] drm/vmwgfx: Annotate struct vmw_surface_dirty with __counted_by

2023-09-23 Thread Gustavo A. R. Silva
Cc: dri-de...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/vmwgfx/vmwgfx_surface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_surface.c b/drivers/gpu/drm

Re: [PATCH 5/9] drm/nouveau/pm: Annotate struct nvkm_perfdom with __counted_by

2023-09-24 Thread Gustavo A. R. Silva
Cc: dri-de...@lists.freedesktop.org Cc: nouv...@lists.freedesktop.org Signed-off-by: Kees Cook Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo --- drivers/gpu/drm/nouveau/nvkm/engine/pm/priv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau