* Re: [PATCH v2] staging: media: atomisp: remove unused macros
From: Dan Carpenter @ 2026-06-08 7:12 UTC (permalink / raw)
To: Rhys Tumelty
Cc: Andy Shevchenko, Hans de Goede, Mauro Carvalho Chehab,
Sakari Ailus, Greg Kroah-Hartman, linux-media, linux-staging,
linux-kernel
In-Reply-To: <20260607094130.3208513-1-rhys@tumelty.co.uk>
On Sun, Jun 07, 2026 at 10:41:30AM +0100, Rhys Tumelty wrote:
> Remove unused macros across the atomisp driver that are defined
> in .c files but never used. This was flagged as an error in a
> W=2 build due to -Werror=unused-macros.
>
> Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
> ---
> v2: Removed some macros that are used, or should be kept for documentation, with feedback from Dan Carpenter
Thanks. Looks okay to me now.
regards,
dan carpenter
^ permalink raw reply
* Re: [PATCH] staging: media: atomisp: prefer kcalloc over kzalloc with multiply
From: Dan Carpenter @ 2026-06-08 7:08 UTC (permalink / raw)
To: Andrew Soto
Cc: hansg, mchehab, gregkh, andy, sakari.ailus, linux-media,
linux-staging, linux-kernel
In-Reply-To: <20260606234427.9902-1-linux@notrealandy.dev>
On Sat, Jun 06, 2026 at 11:44:27PM +0000, Andrew Soto wrote:
> Optimize memory allocation layout
This part of the commit message is techno-bable. It's just
words that don't mean anything. I suppose teally they do
mean something, but it's not what the patch does...
> in sh_css_params.c by replacing the raw multiplication inside kzalloc() with a type-safe kcalloc() array allocation wrapper.
>
> This prevents potential integer overflow vulnerabilities by validating the array size calculations before interacting with the kernel heap allocator, aligning the driver with modern kernel memory allocation standards.
>
There is no risk of integer overflow when we multiply by 1.
> Signed-off-by: Andrew Soto <linux@notrealandy.dev>
> ---
> drivers/staging/media/atomisp/pci/sh_css_params.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/media/atomisp/pci/sh_css_params.c b/drivers/staging/media/atomisp/pci/sh_css_params.c
> index fcebace11..9147ca047 100644
> --- a/drivers/staging/media/atomisp/pci/sh_css_params.c
> +++ b/drivers/staging/media/atomisp/pci/sh_css_params.c
> @@ -3716,7 +3716,7 @@ ia_css_ptr sh_css_store_sp_group_to_ddr(void)
>
> IA_CSS_ENTER_LEAVE_PRIVATE("void");
>
> - write_buf = kzalloc(sizeof(u8) * 8192, GFP_KERNEL);
> + write_buf = kcalloc(8192, sizeof(u8), GFP_KERNEL);
This should just be:
write_buf = kzalloc(8192, GFP_KERNEL);
If we weren't allocating a text buffer then the new way to write this
would be using kzalloc_objs().
regards,
dan carpenter
^ permalink raw reply
* Re: [PATCH 2/2] staging: fbtft: fbtft-bus: remove prohibited space before close parenthesis
From: Andy Shevchenko @ 2026-06-08 6:08 UTC (permalink / raw)
To: Georgii Druzhinin
Cc: andy, gregkh, dri-devel, linux-fbdev, linux-staging, linux-kernel
In-Reply-To: <20260607201708.88644-2-ilovelinuxgames@gmail.com>
On Sun, Jun 7, 2026 at 11:17 PM Georgii Druzhinin
<ilovelinuxgames@gmail.com> wrote:
>
> Fix checkpatch.pl error: "space prohibited before that close
> parenthesis ')'" by removing the empty argument and comma
> in define_fbtft_write_reg macro calls.
Please, learn C preprocessor and compile your stuff before submitting.
Also since you have a series of the patches it should have had a cover letter.
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply
* [PATCH 2/2] staging: fbtft: fbtft-bus: remove prohibited space before close parenthesis
From: Georgii Druzhinin @ 2026-06-07 20:17 UTC (permalink / raw)
To: andy, gregkh
Cc: dri-devel, linux-fbdev, linux-staging, linux-kernel,
Georgii Druzhinin
In-Reply-To: <20260607201708.88644-1-ilovelinuxgames@gmail.com>
Fix checkpatch.pl error: "space prohibited before that close
parenthesis ')'" by removing the empty argument and comma
in define_fbtft_write_reg macro calls.
Signed-off-by: Georgii Druzhinin <ilovelinuxgames@gmail.com>
---
drivers/staging/fbtft/fbtft-bus.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/fbtft/fbtft-bus.c b/drivers/staging/fbtft/fbtft-bus.c
index 30e436ff19e4..409770891c54 100644
--- a/drivers/staging/fbtft/fbtft-bus.c
+++ b/drivers/staging/fbtft/fbtft-bus.c
@@ -62,9 +62,9 @@ out: \
} \
EXPORT_SYMBOL(func);
-define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8, )
+define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8)
define_fbtft_write_reg(fbtft_write_reg16_bus8, __be16, u16, cpu_to_be16)
-define_fbtft_write_reg(fbtft_write_reg16_bus16, u16, u16, )
+define_fbtft_write_reg(fbtft_write_reg16_bus16, u16, u16)
void fbtft_write_reg8_bus9(struct fbtft_par *par, int len, ...)
{
--
2.54.0
^ permalink raw reply related
* [PATCH 1/2] staging: fbtft: fb_ra8875: prefer usleep_range over udelay
From: Georgii Druzhinin @ 2026-06-07 20:17 UTC (permalink / raw)
To: andy, gregkh
Cc: dri-devel, linux-fbdev, linux-staging, linux-kernel,
Georgii Druzhinin
Replace udelay(100) with usleep_range(100, 120) to avoid busy-waiting
and allow the scheduler to utilize the CPU during the delay.
Signed-off-by: Georgii Druzhinin <ilovelinuxgames@gmail.com>
---
drivers/staging/fbtft/fb_ra8875.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/fbtft/fb_ra8875.c b/drivers/staging/fbtft/fb_ra8875.c
index 0ab1de6647d0..6058934e2ca2 100644
--- a/drivers/staging/fbtft/fb_ra8875.c
+++ b/drivers/staging/fbtft/fb_ra8875.c
@@ -210,7 +210,7 @@ static void write_reg8_bus8(struct fbtft_par *par, int len, ...)
}
len--;
- udelay(100);
+ usleep_range(100, 120);
if (len) {
buf = (u8 *)par->buf;
@@ -231,7 +231,7 @@ static void write_reg8_bus8(struct fbtft_par *par, int len, ...)
/* restore user spi-speed */
par->fbtftops.write = fbtft_write_spi;
- udelay(100);
+ usleep_range(100, 120);
}
static int write_vmem16_bus8(struct fbtft_par *par, size_t offset, size_t len)
--
2.54.0
^ permalink raw reply related
* Re: [PATCH v2] staging: media: atomisp: prefer kcalloc over kzalloc with multiply
From: Andy Shevchenko @ 2026-06-07 18:52 UTC (permalink / raw)
To: Andrew Soto
Cc: andy, gregkh, hansg, linux-kernel, linux-media, linux-staging,
mchehab, sakari.ailus
In-Reply-To: <20260607121833.10058-1-linux@notrealandy.dev>
On Sun, Jun 7, 2026 at 3:19 PM Andrew Soto <linux@notrealandy.dev> wrote:
>
> Optimize memory allocation layout in sh_css_params.c by replacing
> the raw multiplication inside kzalloc() with a type-safe kcalloc()
> array allocation wrapper.
>
> This prevents potential integer overflow vulnerabilities by validating
> the array size calculations before interacting
> with the kernel heap allocator, aligning the driver with modern kernel
> memory allocation standards.
See my reply to v1.
...
> - write_buf = kzalloc(sizeof(u8) * 8192, GFP_KERNEL);
> + write_buf = kcalloc(8192, sizeof(u8), GFP_KERNEL);
While at it, you can switch to a more robust sizeof(*write_buf).
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply
* [PATCH v2] staging: media: atomisp: prefer kcalloc over kzalloc with multiply
From: Andrew Soto @ 2026-06-07 12:18 UTC (permalink / raw)
To: linux
Cc: andy, gregkh, hansg, linux-kernel, linux-media, linux-staging,
mchehab, sakari.ailus
In-Reply-To: <20260606234427.9902-1-linux@notrealandy.dev>
Optimize memory allocation layout in sh_css_params.c by replacing
the raw multiplication inside kzalloc() with a type-safe kcalloc()
array allocation wrapper.
This prevents potential integer overflow vulnerabilities by validating
the array size calculations before interacting
with the kernel heap allocator, aligning the driver with modern kernel
memory allocation standards.
Signed-off-by: Andrew Soto <linux@notrealandy.dev>
---
drivers/staging/media/atomisp/pci/sh_css_params.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/media/atomisp/pci/sh_css_params.c b/drivers/staging/media/atomisp/pci/sh_css_params.c
index fcebace11..9147ca047 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_params.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_params.c
@@ -3716,7 +3716,7 @@ ia_css_ptr sh_css_store_sp_group_to_ddr(void)
IA_CSS_ENTER_LEAVE_PRIVATE("void");
- write_buf = kzalloc(sizeof(u8) * 8192, GFP_KERNEL);
+ write_buf = kcalloc(8192, sizeof(u8), GFP_KERNEL);
if (!write_buf)
return 0;
--
2.53.0
^ permalink raw reply related
* [PATCH v2] staging: media: atomisp: remove unused macros
From: Rhys Tumelty @ 2026-06-07 9:41 UTC (permalink / raw)
To: Andy Shevchenko, Hans de Goede, Mauro Carvalho Chehab
Cc: Sakari Ailus, Greg Kroah-Hartman, linux-media, linux-staging,
linux-kernel, Dan Carpenter, Rhys Tumelty
Remove unused macros across the atomisp driver that are defined
in .c files but never used. This was flagged as an error in a
W=2 build due to -Werror=unused-macros.
Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
---
v2: Removed some macros that are used, or should be kept for documentation, with feedback from Dan Carpenter
drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 3 ---
drivers/staging/media/atomisp/pci/sh_css.c | 4 ----
drivers/staging/media/atomisp/pci/sh_css_metrics.c | 6 ------
3 files changed, 13 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
index 900a67552d6a..7c1fdd39d6a3 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
@@ -40,9 +40,6 @@
#define SUBDEV_WAIT_TIMEOUT 50 /* ms */
#define SUBDEV_WAIT_TIMEOUT_MAX_COUNT 40 /* up to 2 seconds */
-/* G-Min addition: pull this in from intel_mid_pm.h */
-#define CSTATE_EXIT_LATENCY_C1 1
-
/* cross component debug message flag */
int dbg_level;
module_param(dbg_level, int, 0644);
diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c
index 6cda5925fa45..cd1be313c758 100644
--- a/drivers/staging/media/atomisp/pci/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/sh_css.c
@@ -61,10 +61,6 @@
#include <gpio_private.h>
#include "timed_ctrl.h"
#include "ia_css_inputfifo.h"
-#define WITH_PC_MONITORING 0
-
-#define SH_CSS_VIDEO_BUFFER_ALIGNMENT 0
-
#include "ia_css_spctrl.h"
#include "ia_css_version_data.h"
diff --git a/drivers/staging/media/atomisp/pci/sh_css_metrics.c b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
index edf473dd86ca..24cdd52283ba 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_metrics.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
@@ -12,12 +12,6 @@
#include "sh_css_internal.h"
-#define MULTIPLE_PCS 0
-#define SUSPEND 0
-#define NOF_PCS 1
-#define RESUME_MASK 0x8
-#define STOP_MASK 0x0
-
static bool pc_histogram_enabled;
static struct sh_css_pc_histogram *isp_histogram;
static struct sh_css_pc_histogram *sp_histogram;
--
2.54.0
^ permalink raw reply related
* Re: [PATCH] staging: media: atomisp: prefer kcalloc over kzalloc with multiply
From: Andy Shevchenko @ 2026-06-07 7:42 UTC (permalink / raw)
To: Andrew Soto
Cc: hansg, mchehab, gregkh, andy, sakari.ailus, linux-media,
linux-staging, linux-kernel
In-Reply-To: <20260606234427.9902-1-linux@notrealandy.dev>
On Sun, Jun 7, 2026 at 2:45 AM Andrew Soto <linux@notrealandy.dev> wrote:
>
> Optimize memory allocation layout in sh_css_params.c by replacing the raw multiplication inside kzalloc() with a type-safe kcalloc() array allocation wrapper.
>
> This prevents potential integer overflow vulnerabilities by validating the array size calculations before interacting with the kernel heap allocator, aligning the driver with modern kernel memory allocation standards.
Wrap the commit message around 72 characters per line.
...
Is this the only case like this in the entire driver?
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply
* Re: [PATCH] staging: rtl8723: remove multiple blank lines in rtw_security.c
From: Ethan Tidmore @ 2026-06-07 0:25 UTC (permalink / raw)
To: Andrea Frasson, gregkh; +Cc: linux-staging, linux-kernel
In-Reply-To: <aiRL4dekV140SPGw@frassi>
On Sat Jun 6, 2026 at 11:33 AM CDT, Andrea Frasson wrote:
> Remove unnecessary multiple blank lines.
>
> Fix 5 checkpatch.pl checks in rtw_security.c of the type:
> - CHECK: Please don't use multiple blank lines
>
> Signed-off-by: Andrea Frasson <andreafrasson1995@gmail.com>
> ---
LGTM.
Reviewed-by: Ethan Tidmore <ethantidmore06@gmail.com>
Thanks,
ET
^ permalink raw reply
* [PATCH] staging: media: atomisp: prefer kcalloc over kzalloc with multiply
From: Andrew Soto @ 2026-06-06 23:44 UTC (permalink / raw)
To: hansg, mchehab, gregkh
Cc: andy, sakari.ailus, linux-media, linux-staging, linux-kernel,
Andrew Soto
Optimize memory allocation layout in sh_css_params.c by replacing the raw multiplication inside kzalloc() with a type-safe kcalloc() array allocation wrapper.
This prevents potential integer overflow vulnerabilities by validating the array size calculations before interacting with the kernel heap allocator, aligning the driver with modern kernel memory allocation standards.
Signed-off-by: Andrew Soto <linux@notrealandy.dev>
---
drivers/staging/media/atomisp/pci/sh_css_params.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/media/atomisp/pci/sh_css_params.c b/drivers/staging/media/atomisp/pci/sh_css_params.c
index fcebace11..9147ca047 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_params.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_params.c
@@ -3716,7 +3716,7 @@ ia_css_ptr sh_css_store_sp_group_to_ddr(void)
IA_CSS_ENTER_LEAVE_PRIVATE("void");
- write_buf = kzalloc(sizeof(u8) * 8192, GFP_KERNEL);
+ write_buf = kcalloc(8192, sizeof(u8), GFP_KERNEL);
if (!write_buf)
return 0;
--
2.53.0
^ permalink raw reply related
* [PATCH] staging: rtl8723: remove multiple blank lines in rtw_security.c
From: Andrea Frasson @ 2026-06-06 16:33 UTC (permalink / raw)
To: gregkh; +Cc: linux-staging, linux-kernel
Remove unnecessary multiple blank lines.
Fix 5 checkpatch.pl checks in rtw_security.c of the type:
- CHECK: Please don't use multiple blank lines
Signed-off-by: Andrea Frasson <andreafrasson1995@gmail.com>
---
drivers/staging/rtl8723bs/core/rtw_security.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/drivers/staging/rtl8723bs/core/rtw_security.c b/drivers/staging/rtl8723bs/core/rtw_security.c
index 0cfd7734c174..da61a552bdb3 100644
--- a/drivers/staging/rtl8723bs/core/rtw_security.c
+++ b/drivers/staging/rtl8723bs/core/rtw_security.c
@@ -409,7 +409,6 @@ static void phase2(u8 *rc4key, const u8 *tk, const u16 *p1k, u16 iv16)
rc4key[2] = Lo8(iv16);
rc4key[3] = Lo8((PPK[5] ^ TK16(0)) >> 1);
-
/* Copy 96 bits of PPK[0..5] to RC4KEY[4..15] (little-endian) */
for (i = 0; i < 6; i++) {
rc4key[4 + 2 * i] = Lo8(PPK[i]);
@@ -417,7 +416,6 @@ static void phase2(u8 *rc4key, const u8 *tk, const u16 *p1k, u16 iv16)
}
}
-
/* The hlen isn't include the IV */
u32 rtw_tkip_encrypt(struct adapter *padapter, u8 *pxmitframe)
{ /* exclude ICV */
@@ -491,7 +489,6 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, u8 *pxmitframe)
return res;
}
-
/* The hlen isn't include the IV */
u32 rtw_tkip_decrypt(struct adapter *padapter, u8 *precvframe)
{ /* exclude ICV */
@@ -593,11 +590,8 @@ u32 rtw_tkip_decrypt(struct adapter *padapter, u8 *precvframe)
return res;
}
-
/* 3 =====AES related ===== */
-
-
#define MAX_MSG_SIZE 2048
/****************************************/
--
2.48.1
^ permalink raw reply related
* Re: [PATCH v2] staging: media: atomisp: remove unused macros
From: Dan Carpenter @ 2026-06-06 10:12 UTC (permalink / raw)
To: Rhys Tumelty
Cc: hansg, mchehab, gregkh, sakari.ailus, andy, linux-media,
linux-staging, linux-kernel
In-Reply-To: <20260606092842.179826-1-rhys@tumelty.co.uk>
On Sat, Jun 06, 2026 at 10:28:42AM +0100, Rhys Tumelty wrote:
> diff --git a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
> index 4026e98c5845..0eafd81c44cd 100644
> --- a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
> +++ b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
> @@ -48,7 +48,6 @@ enum clock_rate {
> /* TI SND9039 PMIC register set */
> #define LDO9_REG 0x49
> #define LDO10_REG 0x4a
> -#define LDO11_REG 0x4b
Don't delete this. It's useful documentation.
There are some other issues with this patch but I commented on them
in my previous review.
regards,
dan carpenter
^ permalink raw reply
* Re: [PATCH v2] staging: media: atomisp: remove unused macros
From: Dan Carpenter @ 2026-06-06 10:01 UTC (permalink / raw)
To: Rhys Tumelty
Cc: hansg, mchehab, gregkh, sakari.ailus, andy, linux-media,
linux-staging, linux-kernel
In-Reply-To: <20260606092842.179826-1-rhys@tumelty.co.uk>
On Sat, Jun 06, 2026 at 10:28:42AM +0100, Rhys Tumelty wrote:
> removed unused macros across the atomisp driver that are defined
> in .c files, but never used, which was flagged as errors in a
> W=2 build, due to -Werror=unused-macros.
>
> Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
> ---
Please slow down. Don't resend a patch twice in the same day.
Follow all the v2 rules etc. I will review this patch when you
resend it (not today hopefully).
https://staticthinking.wordpress.com/2022/07/27/how-to-send-a-v2-patch/
regards,
dan carpenter
^ permalink raw reply
* [PATCH RESEND] media: atomisp: replace kmalloc() with kmalloc_array() in sh_css.c
From: Andrei Khomenkov @ 2026-06-06 9:54 UTC (permalink / raw)
To: Greg Kroah-Hartman, Hans de Goede, Mauro Carvalho Chehab
Cc: Andy Shevchenko, Sakari Ailus, Kees Cook, linux-staging,
linux-media
Replace arithmetic in the kmalloc() function with the kmalloc_array()
function, as this calculation method is unsafe.
Signed-off-by: Andrei Khomenkov <khomenkov@mailbox.org>
---
drivers/staging/media/atomisp/pci/sh_css.c | 41 +++++++++-------------
1 file changed, 16 insertions(+), 25 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c
index 6cda5925fa45..a325a7994068 100644
--- a/drivers/staging/media/atomisp/pci/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/sh_css.c
@@ -5819,36 +5819,31 @@ static int ia_css_pipe_create_cas_scaler_desc_single_output(
i *= max_scale_factor_per_stage;
}
- descr->in_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->in_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->in_info) {
err = -ENOMEM;
goto ERR;
}
- descr->internal_out_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->internal_out_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->internal_out_info) {
err = -ENOMEM;
goto ERR;
}
- descr->out_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->out_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->out_info) {
err = -ENOMEM;
goto ERR;
}
- descr->vf_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->vf_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->vf_info) {
err = -ENOMEM;
goto ERR;
}
- descr->is_output_stage = kmalloc(descr->num_stage * sizeof(bool),
- GFP_KERNEL);
+ descr->is_output_stage = kmalloc_array(descr->num_stage, sizeof(bool), GFP_KERNEL);
if (!descr->is_output_stage) {
err = -ENOMEM;
goto ERR;
@@ -5974,29 +5969,25 @@ ia_css_pipe_create_cas_scaler_desc(struct ia_css_pipe *pipe,
err = -ENOMEM;
goto ERR;
}
- descr->internal_out_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->internal_out_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->internal_out_info) {
err = -ENOMEM;
goto ERR;
}
- descr->out_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->out_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->out_info) {
err = -ENOMEM;
goto ERR;
}
- descr->vf_info = kmalloc(descr->num_stage *
- sizeof(struct ia_css_frame_info),
- GFP_KERNEL);
+ descr->vf_info = kmalloc_array(descr->num_stage, sizeof(struct ia_css_frame_info),
+ GFP_KERNEL);
if (!descr->vf_info) {
err = -ENOMEM;
goto ERR;
}
- descr->is_output_stage = kmalloc(descr->num_stage * sizeof(bool),
- GFP_KERNEL);
+ descr->is_output_stage = kmalloc_array(descr->num_stage, sizeof(bool), GFP_KERNEL);
if (!descr->is_output_stage) {
err = -ENOMEM;
goto ERR;
^ permalink raw reply related
* [PATCH v2] staging: media: atomisp: remove unused macros
From: Rhys Tumelty @ 2026-06-06 9:28 UTC (permalink / raw)
To: hansg, mchehab, gregkh
Cc: error27, sakari.ailus, andy, linux-media, linux-staging,
linux-kernel, Rhys Tumelty
removed unused macros across the atomisp driver that are defined
in .c files, but never used, which was flagged as errors in a
W=2 build, due to -Werror=unused-macros.
Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
---
.../media/atomisp/pci/atomisp_compat_css20.c | 3 ---
.../media/atomisp/pci/atomisp_gmin_platform.c | 3 ---
drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 7 -------
drivers/staging/media/atomisp/pci/mmu/isp_mmu.c | 14 --------------
.../atomisp/pci/runtime/inputfifo/src/inputfifo.c | 3 ---
drivers/staging/media/atomisp/pci/sh_css.c | 3 ---
drivers/staging/media/atomisp/pci/sh_css_hrt.c | 2 --
drivers/staging/media/atomisp/pci/sh_css_metrics.c | 6 ------
8 files changed, 41 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c b/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
index be5f37f4a6fd..95edc98137cc 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
@@ -28,9 +28,6 @@
#include <linux/io.h>
#include <linux/pm_runtime.h>
-/* Assume max number of ACC stages */
-#define MAX_ACC_STAGES 20
-
/* Ideally, this should come from CSS headers */
#define NO_LINK -1
diff --git a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
index 4026e98c5845..0eafd81c44cd 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
@@ -48,7 +48,6 @@ enum clock_rate {
/* TI SND9039 PMIC register set */
#define LDO9_REG 0x49
#define LDO10_REG 0x4a
-#define LDO11_REG 0x4b
#define LDO_2P8V_ON 0x2f /* 0x2e selects 2.85V ... */
#define LDO_2P8V_OFF 0x2e /* ... bottom bit is "enabled" */
@@ -99,8 +98,6 @@ static struct gmin_subdev gmin_subdevs[MAX_SUBDEVS];
#define PMIC_ACPI_TI "INT33F5" /* Dollar Cove TI PMIC */
#define PMIC_ACPI_CRYSTALCOVE "INT33FD" /* Crystal Cove PMIC */
-#define PMIC_PLATFORM_TI "intel_soc_pmic_chtdc_ti"
-
static enum {
PMIC_UNSET = 0,
PMIC_REGULATOR,
diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
index 900a67552d6a..eaaa3753abf9 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
@@ -36,13 +36,6 @@
#include "device_access.h"
-/* Timeouts to wait for all subdevs to be registered */
-#define SUBDEV_WAIT_TIMEOUT 50 /* ms */
-#define SUBDEV_WAIT_TIMEOUT_MAX_COUNT 40 /* up to 2 seconds */
-
-/* G-Min addition: pull this in from intel_mid_pm.h */
-#define CSTATE_EXIT_LATENCY_C1 1
-
/* cross component debug message flag */
int dbg_level;
module_param(dbg_level, int, 0644);
diff --git a/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c b/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
index 5193a7eb7d9f..6a8c5ba27b02 100644
--- a/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
+++ b/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
@@ -29,20 +29,6 @@
#include "atomisp_internal.h"
#include "mmu/isp_mmu.h"
-/*
- * 64-bit x86 processor physical address layout:
- * 0 - 0x7fffffff DDR RAM (2GB)
- * 0x80000000 - 0xffffffff MMIO (2GB)
- * 0x100000000 - 0x3fffffffffff DDR RAM (64TB)
- * So if the system has more than 2GB DDR memory, the lower 2GB occupies the
- * physical address 0 - 0x7fffffff and the rest will start from 0x100000000.
- * We have to make sure memory is allocated from the lower 2GB for devices
- * that are only 32-bit capable(e.g. the ISP MMU).
- *
- * For any confusion, contact bin.gao@intel.com.
- */
-#define NR_PAGES_2GB (SZ_2G / PAGE_SIZE)
-
static void free_mmu_map(struct isp_mmu *mmu, unsigned int start_isp_virt,
unsigned int end_isp_virt);
diff --git a/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c b/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
index 8e1efeb6372c..b084f9edb8a7 100644
--- a/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
+++ b/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
@@ -10,9 +10,7 @@
#include "device_access.h"
-#define __INLINE_SP__
#include "sp.h"
-#define __INLINE_ISP__
#include "isp.h"
#define __INLINE_IRQ__
#include "irq.h"
@@ -21,7 +19,6 @@
#define __INLINE_EVENT__
#include "event_fifo.h"
-#define __INLINE_SP__
#include "input_system.h" /* MIPI_PREDICTOR_NONE,... */
diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c
index 6cda5925fa45..ec3ff31f76e0 100644
--- a/drivers/staging/media/atomisp/pci/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/sh_css.c
@@ -61,9 +61,6 @@
#include <gpio_private.h>
#include "timed_ctrl.h"
#include "ia_css_inputfifo.h"
-#define WITH_PC_MONITORING 0
-
-#define SH_CSS_VIDEO_BUFFER_ALIGNMENT 0
#include "ia_css_spctrl.h"
diff --git a/drivers/staging/media/atomisp/pci/sh_css_hrt.c b/drivers/staging/media/atomisp/pci/sh_css_hrt.c
index d4633572f8f3..1ef95308bd48 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_hrt.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_hrt.c
@@ -13,9 +13,7 @@
#define __INLINE_EVENT__
#include "event_fifo.h"
-#define __INLINE_SP__
#include "sp.h"
-#define __INLINE_ISP__
#include "isp.h"
#define __INLINE_IRQ__
#include "irq.h"
diff --git a/drivers/staging/media/atomisp/pci/sh_css_metrics.c b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
index edf473dd86ca..24cdd52283ba 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_metrics.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
@@ -12,12 +12,6 @@
#include "sh_css_internal.h"
-#define MULTIPLE_PCS 0
-#define SUSPEND 0
-#define NOF_PCS 1
-#define RESUME_MASK 0x8
-#define STOP_MASK 0x0
-
static bool pc_histogram_enabled;
static struct sh_css_pc_histogram *isp_histogram;
static struct sh_css_pc_histogram *sp_histogram;
--
2.54.0
^ permalink raw reply related
* Re: [PATCH] staging: media: atomisp: remove unused macros
From: Dan Carpenter @ 2026-06-06 9:23 UTC (permalink / raw)
To: Rhys Tumelty
Cc: hansg, mchehab, gregkh, sakari.ailus, andy, linux-media,
linux-staging, linux-kernel
In-Reply-To: <20260606091447.168262-1-rhys@tumelty.co.uk>
On Sat, Jun 06, 2026 at 10:14:47AM +0100, Rhys Tumelty wrote:
> diff --git a/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c b/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
> index 8513e78856b2..d05832e7f337 100644
> --- a/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
> +++ b/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
> @@ -12,7 +12,6 @@
> #include "debug_private.h"
> #endif /* __INLINE_DEBUG__ */
>
> -#define __INLINE_SP__
> #include "sp.h"
>
This is used. It should eventually be cleaned up, but not by randomly
deleting stuff.
regards,
dan carpenter
^ permalink raw reply
* [PATCH] staging: media: atomisp: remove unused macros
From: Rhys Tumelty @ 2026-06-06 9:14 UTC (permalink / raw)
To: hansg, mchehab, gregkh
Cc: sakari.ailus, andy, linux-media, linux-staging, linux-kernel,
Rhys Tumelty
removed unused macros across the atomisp driver that are defined
in .c files, but never used, which was flagged as errors in a
W=2 build, due to -Werror=unused-macros.
Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
---
.../media/atomisp/pci/atomisp_compat_css20.c | 3 ---
.../media/atomisp/pci/atomisp_gmin_platform.c | 3 ---
drivers/staging/media/atomisp/pci/atomisp_v4l2.c | 7 -------
.../atomisp/pci/hive_isp_css_common/host/debug.c | 1 -
drivers/staging/media/atomisp/pci/mmu/isp_mmu.c | 14 --------------
.../atomisp/pci/runtime/inputfifo/src/inputfifo.c | 3 ---
drivers/staging/media/atomisp/pci/sh_css.c | 3 ---
drivers/staging/media/atomisp/pci/sh_css_hrt.c | 2 --
drivers/staging/media/atomisp/pci/sh_css_metrics.c | 6 ------
9 files changed, 42 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c b/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
index be5f37f4a6fd..95edc98137cc 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_compat_css20.c
@@ -28,9 +28,6 @@
#include <linux/io.h>
#include <linux/pm_runtime.h>
-/* Assume max number of ACC stages */
-#define MAX_ACC_STAGES 20
-
/* Ideally, this should come from CSS headers */
#define NO_LINK -1
diff --git a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
index 4026e98c5845..0eafd81c44cd 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
@@ -48,7 +48,6 @@ enum clock_rate {
/* TI SND9039 PMIC register set */
#define LDO9_REG 0x49
#define LDO10_REG 0x4a
-#define LDO11_REG 0x4b
#define LDO_2P8V_ON 0x2f /* 0x2e selects 2.85V ... */
#define LDO_2P8V_OFF 0x2e /* ... bottom bit is "enabled" */
@@ -99,8 +98,6 @@ static struct gmin_subdev gmin_subdevs[MAX_SUBDEVS];
#define PMIC_ACPI_TI "INT33F5" /* Dollar Cove TI PMIC */
#define PMIC_ACPI_CRYSTALCOVE "INT33FD" /* Crystal Cove PMIC */
-#define PMIC_PLATFORM_TI "intel_soc_pmic_chtdc_ti"
-
static enum {
PMIC_UNSET = 0,
PMIC_REGULATOR,
diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
index 900a67552d6a..eaaa3753abf9 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c
@@ -36,13 +36,6 @@
#include "device_access.h"
-/* Timeouts to wait for all subdevs to be registered */
-#define SUBDEV_WAIT_TIMEOUT 50 /* ms */
-#define SUBDEV_WAIT_TIMEOUT_MAX_COUNT 40 /* up to 2 seconds */
-
-/* G-Min addition: pull this in from intel_mid_pm.h */
-#define CSTATE_EXIT_LATENCY_C1 1
-
/* cross component debug message flag */
int dbg_level;
module_param(dbg_level, int, 0644);
diff --git a/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c b/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
index 8513e78856b2..d05832e7f337 100644
--- a/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
+++ b/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/debug.c
@@ -12,7 +12,6 @@
#include "debug_private.h"
#endif /* __INLINE_DEBUG__ */
-#define __INLINE_SP__
#include "sp.h"
#include "assert_support.h"
diff --git a/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c b/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
index 5193a7eb7d9f..6a8c5ba27b02 100644
--- a/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
+++ b/drivers/staging/media/atomisp/pci/mmu/isp_mmu.c
@@ -29,20 +29,6 @@
#include "atomisp_internal.h"
#include "mmu/isp_mmu.h"
-/*
- * 64-bit x86 processor physical address layout:
- * 0 - 0x7fffffff DDR RAM (2GB)
- * 0x80000000 - 0xffffffff MMIO (2GB)
- * 0x100000000 - 0x3fffffffffff DDR RAM (64TB)
- * So if the system has more than 2GB DDR memory, the lower 2GB occupies the
- * physical address 0 - 0x7fffffff and the rest will start from 0x100000000.
- * We have to make sure memory is allocated from the lower 2GB for devices
- * that are only 32-bit capable(e.g. the ISP MMU).
- *
- * For any confusion, contact bin.gao@intel.com.
- */
-#define NR_PAGES_2GB (SZ_2G / PAGE_SIZE)
-
static void free_mmu_map(struct isp_mmu *mmu, unsigned int start_isp_virt,
unsigned int end_isp_virt);
diff --git a/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c b/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
index 8e1efeb6372c..b084f9edb8a7 100644
--- a/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
+++ b/drivers/staging/media/atomisp/pci/runtime/inputfifo/src/inputfifo.c
@@ -10,9 +10,7 @@
#include "device_access.h"
-#define __INLINE_SP__
#include "sp.h"
-#define __INLINE_ISP__
#include "isp.h"
#define __INLINE_IRQ__
#include "irq.h"
@@ -21,7 +19,6 @@
#define __INLINE_EVENT__
#include "event_fifo.h"
-#define __INLINE_SP__
#include "input_system.h" /* MIPI_PREDICTOR_NONE,... */
diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c
index 6cda5925fa45..ec3ff31f76e0 100644
--- a/drivers/staging/media/atomisp/pci/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/sh_css.c
@@ -61,9 +61,6 @@
#include <gpio_private.h>
#include "timed_ctrl.h"
#include "ia_css_inputfifo.h"
-#define WITH_PC_MONITORING 0
-
-#define SH_CSS_VIDEO_BUFFER_ALIGNMENT 0
#include "ia_css_spctrl.h"
diff --git a/drivers/staging/media/atomisp/pci/sh_css_hrt.c b/drivers/staging/media/atomisp/pci/sh_css_hrt.c
index d4633572f8f3..1ef95308bd48 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_hrt.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_hrt.c
@@ -13,9 +13,7 @@
#define __INLINE_EVENT__
#include "event_fifo.h"
-#define __INLINE_SP__
#include "sp.h"
-#define __INLINE_ISP__
#include "isp.h"
#define __INLINE_IRQ__
#include "irq.h"
diff --git a/drivers/staging/media/atomisp/pci/sh_css_metrics.c b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
index edf473dd86ca..24cdd52283ba 100644
--- a/drivers/staging/media/atomisp/pci/sh_css_metrics.c
+++ b/drivers/staging/media/atomisp/pci/sh_css_metrics.c
@@ -12,12 +12,6 @@
#include "sh_css_internal.h"
-#define MULTIPLE_PCS 0
-#define SUSPEND 0
-#define NOF_PCS 1
-#define RESUME_MASK 0x8
-#define STOP_MASK 0x0
-
static bool pc_histogram_enabled;
static struct sh_css_pc_histogram *isp_histogram;
static struct sh_css_pc_histogram *sp_histogram;
--
2.54.0
^ permalink raw reply related
* Re: [PATCH] staging: greybus: audio: fix snprintf truncation errors
From: Dan Carpenter @ 2026-06-06 7:08 UTC (permalink / raw)
To: Rhys Tumelty
Cc: gregkh, Vaibhav Agarwal, Mark Greer, Johan Hovold, Alex Elder,
greybus-dev, linux-staging, linux-kernel
In-Reply-To: <20260605192857.78944-1-rhys@tumelty.co.uk>
On Fri, Jun 05, 2026 at 08:28:56PM +0100, Rhys Tumelty wrote:
> change snprintf() to scnprintf() in both gbaudio_tplg_create_widget()
> and gbaudio_tplg_process_kcontrols() to prevent potential string
> truncation warnings when prefixing the device id to the control name.
>
This commit message is unclear. My understanding is that snprintf()
is complaining that the array size of w->name is less than the array
size of "GB %d %s" plus the array size of temp_name. This is a W=1
complaint.
I hate this warning. We use snprintf() to deliberately truncate
the string. Now it's complaining that the string might be truncated.
Oh no! What we want to happen might happen! This is the same argument
that people used to block safer alternatives to strcpy() into glibc
because "it's still going to truncate the string and that's equally
bad as a root exploit!"
First of all, the string is not going to be truncated. (I haven't
looked). Second of all, this warning makes no sense in the kernel.
I have never once had a bug which I failed to debug because the
last two bytes in a string were truncated. There has never been a
scenario where I was looking through dmesg and snprintf() truncated
some bytes so I couldn't guess what I was looking at.
So your solution is to change it to scnprintf() which is kernel only
and GCC doesn't know about it... I bet GCC eventually learns about
scnprintf() and it eventually becomes a warning again.
A better solution is to disable that annoying check.
regards,
dan carpenter
^ permalink raw reply
* Re: [linux-6.1.y 1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
From: Sasha Levin @ 2026-06-05 19:37 UTC (permalink / raw)
To: lee, Jiri Kosina, Benjamin Tissoires, Filipe Laíns,
Bastien Nocera, Ping Cheng, Jason Gerecke, Viresh Kumar,
Johan Hovold, Alex Elder, Greg Kroah-Hartman, linux-input,
linux-kernel, greybus-dev, linux-staging
Cc: Sasha Levin, stable, Vicki Pfau, Jiri Kosina
In-Reply-To: <20260603163022.3301081-1-lee@kernel.org>
> [linux-6.1.y 1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
Whole series queued for 6.1.y, thanks.
--
Thanks,
Sasha
^ permalink raw reply
* Re: [linux-5.15.y 1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
From: Sasha Levin @ 2026-06-05 19:37 UTC (permalink / raw)
To: lee, Jiri Kosina, Benjamin Tissoires, Viresh Kumar, Johan Hovold,
Alex Elder, Greg Kroah-Hartman, linux-input, linux-kernel,
greybus-dev, linux-staging
Cc: Sasha Levin, stable, Vicki Pfau, Jiri Kosina
In-Reply-To: <20260604092659.3953067-1-lee@kernel.org>
> [linux-5.15.y 1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
Whole series queued for 5.15.y, thanks.
--
Thanks,
Sasha
^ permalink raw reply
* [PATCH] staging: greybus: audio: fix snprintf truncation errors
From: Rhys Tumelty @ 2026-06-05 19:28 UTC (permalink / raw)
To: gregkh
Cc: Rhys Tumelty, Vaibhav Agarwal, Mark Greer, Johan Hovold,
Alex Elder, greybus-dev, linux-staging, linux-kernel
change snprintf() to scnprintf() in both gbaudio_tplg_create_widget()
and gbaudio_tplg_process_kcontrols() to prevent potential string
truncation warnings when prefixing the device id to the control name.
Signed-off-by: Rhys Tumelty <rhys@tumelty.co.uk>
---
drivers/staging/greybus/audio_topology.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/greybus/audio_topology.c b/drivers/staging/greybus/audio_topology.c
index 76146f91c..b19febabb 100644
--- a/drivers/staging/greybus/audio_topology.c
+++ b/drivers/staging/greybus/audio_topology.c
@@ -1087,7 +1087,7 @@ static int gbaudio_tplg_create_widget(struct gbaudio_module_info *module,
/* Prefix dev_id to widget control_name */
strscpy(temp_name, w->name, sizeof(temp_name));
- snprintf(w->name, sizeof(w->name), "GB %d %s", module->dev_id, temp_name);
+ scnprintf(w->name, sizeof(w->name), "GB %d %s", module->dev_id, temp_name);
switch (w->type) {
case snd_soc_dapm_spk:
@@ -1169,8 +1169,8 @@ static int gbaudio_tplg_process_kcontrols(struct gbaudio_module_info *module,
control->id = curr->id;
/* Prefix dev_id to widget_name */
strscpy(temp_name, curr->name, sizeof(temp_name));
- snprintf(curr->name, sizeof(curr->name), "GB %d %s", module->dev_id,
- temp_name);
+ scnprintf(curr->name, sizeof(curr->name), "GB %d %s", module->dev_id,
+ temp_name);
control->name = curr->name;
if (curr->info.type == GB_AUDIO_CTL_ELEM_TYPE_ENUMERATED) {
struct gb_audio_enumerated *gbenum =
--
2.54.0
^ permalink raw reply related
* Re: [PATCH v2 1/1] MAINTAINERS: Camera sensor and Intel IPU driver changes
From: Frank Li @ 2026-06-05 18:49 UTC (permalink / raw)
To: Sakari Ailus
Cc: linux-media, Yong Zhi, Mauro Carvalho Chehab, Greg Kroah-Hartman,
Lixu Zhang, linux-kernel, linux-staging, Bingbu Cao,
Dave Stevenson, David Heidelberg, Richard Acayan
In-Reply-To: <20260605074944.666654-1-sakari.ailus@linux.intel.com>
On Fri, Jun 05, 2026 at 10:49:44AM +0300, Sakari Ailus wrote:
> From: Dave Hansen <dave.hansen@linux.intel.com>
>
> Tian Shu Qiu and Bingbu Cao are maintainers and reviewers of a bunch of
> media drivers (7 and 9 respectively). Bingbu's e-mail address has changed
> and Tian Shu's is bouncing.
>
> Update Bingbu's e-mail address, remove Bingbu as a maintainer from Intel
> specific drivers and and remove Tian Shu as maintainer. Also add Dave
> Stevenson as a maintainer and David Heidelberg as a reviewer for the
> imx355 driver.
>
> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
> Cc: Yong Zhi <yong.zhi@intel.com>
> Cc: Dan Scally <dan.scally@ideasonboard.com>
> Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Lixu Zhang <lixu.zhang@intel.com>
> Cc: linux-media@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: linux-staging@lists.linux.dev
> Co-developed-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---
> MAINTAINERS | 29 ++++++++++++-----------------
> 1 file changed, 12 insertions(+), 17 deletions(-)
>
...
>
> INTEL IPU6 INPUT SYSTEM DRIVER
> M: Sakari Ailus <sakari.ailus@linux.intel.com>
> -M: Bingbu Cao <bingbu.cao@intel.com>
> -R: Tianshu Qiu <tian.shu.qiu@intel.com>
Need add both to CREDITS files
Frank
^ permalink raw reply
* Re: [linux-6.6.y 1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
From: patchwork-bot+netdevbpf @ 2026-06-05 10:05 UTC (permalink / raw)
To: Lee Jones
Cc: jikos, benjamin.tissoires, lains, hadess, ping.cheng,
jason.gerecke, vireshk, johan, elder, gregkh, sashal, linux-input,
linux-kernel, greybus-dev, linux-staging, bpf, stable, vi,
jkosina
In-Reply-To: <20260603133140.3069226-1-lee@kernel.org>
Hello:
This series was applied to bpf/bpf-next.git (net)
by Linus Torvalds <torvalds@linux-foundation.org>:
On Wed, 3 Jun 2026 14:31:25 +0100 you wrote:
> From: Vicki Pfau <vi@endrift.com>
>
> hid_warn_ratelimited() is needed. Add the others as part of the block.
>
> Signed-off-by: Vicki Pfau <vi@endrift.com>
> Signed-off-by: Jiri Kosina <jkosina@suse.com>
> (cherry picked from commit 1d64624243af8329b4b219d8c39e28ea448f9929)
> Signed-off-by: Lee Jones <lee@kernel.org>
>
> [...]
Here is the summary with links:
- [linux-6.6.y,1/3] HID: core: Add printk_ratelimited variants to hid_warn() etc
(no matching commit)
- [linux-6.6.y,2/3] HID: pass the buffer size to hid_report_raw_event
(no matching commit)
- [linux-6.6.y,3/3] HID: core: Fix size_t specifier in hid_report_raw_event()
https://git.kernel.org/bpf/bpf-next/c/4d3a2a466b8d
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply
* Re: [PATCH v2 1/1] staging: media: tegra-video: vi: Improve media graph building logic
From: Luca Ceresoli @ 2026-06-05 8:29 UTC (permalink / raw)
To: Svyatoslav Ryhel, Thierry Reding, Jonathan Hunter,
Sowjanya Komatineni, Luca Ceresoli, Mauro Carvalho Chehab,
Hans Verkuil, Greg Kroah-Hartman
Cc: linux-media, linux-tegra, linux-staging, linux-kernel
In-Reply-To: <20260523064750.35553-2-clamor95@gmail.com>
On Sat May 23, 2026 at 8:47 AM CEST, Svyatoslav Ryhel wrote:
> The existing tegra_vi_graph_build function relies heavily on a one-to-one
> match between Device Tree nodes and media pad links. While this works for
> simpler configurations, it causes issues when Device Tree nodes do not
> match media pad link logic (e.g., mt9m114). Switch to the
> media_entity_get_fwnode_pad helper to verify and retrieve the correct pad
> linked to an endpoint, rather than assuming the endpoint ID matches the
> pad ID.
>
> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
I still haven't looked at the code, but:
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # tegra20, parallel camera
Luca
--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply
page: next (older)
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox