This patch series fixes some of the issues reported by static analysis
tool.
Pankaj Bharadiya (6):
media: staging: atomisp: remove redundent check
media: staging: atomisp: Remove useless if statement
media: staging: atomisp: Remove useless "ifndef ISP2401"
media: staging: at
Local variable "requeue" is assigned only once to a constant "false"
value so "if(requeue)" condition will never be true.
Thus remove it.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c | 14 --
1 file change
In sh_css_config_input_network(), "stream" is being dereferenced
before it is null checked.
Fix it by moving the "stream" pointer dereference after it has been
properly null checked.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_c
In ia_css_pipe_get_primary_binarydesc(), "pipe" is being dereferenced
before it is null checked.
Fix it by moving the "pipe" pointer dereference after it has been
properly null checked.
Signed-off-by: Pankaj Bharadiya
---
.../atomisp/pci/atomisp2/css2400/camera/pipe/s
In verify_copy_out_frame_format(), "pipe" is being dereferenced before
it is null checked.
Fix it by moving the "pipe" pointer dereference after it has been
properly null checked.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_cs
Assignment asd = &isp->asd[i] can never be null hence remove
redundent check.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat_css20.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/a
In atomisp_csi2_set_ffmt(), there is no reason to have
"#ifndef ISP2401" condition since code is identical in ifndef and
else sections. Hence remove redudent checks.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/media/atomisp/pci/atomisp2/atomisp_csi2.c | 8
1 file
of above 3 macros where used with newly
introduced sizeof_member macro
- removes definitions of SIZEOF_FIELD, FIELD_SIZEOF, sizeof_field
This series aims to fix the issue based on given comments in [1].
[1] Link: https://www.openwall.com/lists/kernel-hardening/2019/07/02/2
Pankaj Bharadiya
~ $EXCLUDE_FILES ]]; then
continue
fi
sed -i -e 's/\bFIELD_SIZEOF\b/sizeof_member/g' \
-e 's/\bsizeof_field\b/sizeof_member/g' \
-e 's/\bSIZEOF_FIELD\b/sizeof_member/g' $file;
done
Signed-off-by: Pankaj Bharadiya
Now we have sizeof_member macro to find the size of a member of a struct.
FIELD_SIZEOF macro is not getting used any more hence remove it.
Signed-off-by: Pankaj Bharadiya
---
include/linux/kernel.h | 9 -
1 file changed, 9 deletions(-)
diff --git a/include/linux/kernel.h b/include
Now we have a standard sizeof_member macro to find the size of a
member of a struct. Remove the SIZEOF_FIELD macro and use
sizeof_member instead.
Signed-off-by: Pankaj Bharadiya
---
arch/mips/cavium-octeon/executive/cvmx-bootmem.c | 9 +
1 file changed, 1 insertion(+), 8 deletions
re patches.
Signed-off-by: Pankaj Bharadiya
---
include/linux/kernel.h | 9 +
1 file changed, 9 insertions(+)
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 4fa360a13c1e..0b80d8bb3978 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -7
Now we have sizeof_member macro to find the size of a member of a
struct.
sizeof_field macro is not getting used any more hence remove it.
Also modify the offsetofend macro to get rid of it.
Signed-off-by: Pankaj Bharadiya
---
include/linux/stddef.h | 10 +-
1 file changed, 1
In case of single config, w_param_text is NULL.
In snd_soc_dapm_new_control_unlocked() call failure case, it will end
up calling snd_soc_dapm_free_kcontrol() unconditionally and result in
NULL pointer dereference.
Signed-off-by: Pankaj Bharadiya
---
sound/soc/soc-dapm.c | 5 +++--
1 file
w_text_param can be NULL and it is being dereferenced without checking.
Add the missing sanity check to prevent NULL pointer dereference.
Signed-off-by: Pankaj Bharadiya
---
sound/soc/soc-dapm.c | 4
1 file changed, 4 insertions(+)
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c
In case of single config, private_value is left uninitialized.
The private_value does need to be initialized or in
snd_soc_dapm_new_control_unlocked() call failure case, it leads to a
bogus free in snd_soc_dapm_free_kcontrol()
Signed-off-by: Pankaj Bharadiya
---
sound/soc/soc-dapm.c | 2 +-
1
gb_audio_manager_module_descriptor's cport field is actually used to
manage and pass interface id to user space.
Thus rename gb_audio_manager_module_descriptor's 'cport' field and
few other things to avoid confusion.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/gre
Replace CamelCase names with underscores to comply with the standard
kernel coding style.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/dgnc/dgnc_tty.c | 20 ++--
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/staging/dgnc/dgnc_tty.c b/drivers
gb_audio_manager_module_descriptor's intf_id field maintains the
information about the interface on which module is connected hence
having an extra slot field is redundant.
Thus remove the slot field and its associated code.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/gr
Hi,
This patchset does minor cleanup for dgnc driver.
v1->v2:
- Split into multiple patches
- remove redundant dgnc_tmp_write_buf variable and function calls
- rename dgnc_default_termios to default_termios
Pankaj Bharadiya (2):
staging: dgnc: Remove some redundant functions
staging: d
dgnc_tty_preinit() and dgnc_tty_post_uninit() functions are used to
allocate and free "dgnc_TmpWriteBuf" and this "dgnc_TmpWriteBuf" is
not really getting used. Hence remove these redundant functions.
Also remove dgnc_TmpWriteBuf variable as it is not used anymore.
S
Replace CamelCase names with underscores to comply with the standard
kernel coding style.
Signed-off-by: Pankaj Bharadiya
---
drivers/staging/dgnc/dgnc_tty.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/dgnc/dgnc_tty.c b/drivers/staging/dgnc
On Mon, Oct 17, 2016 at 1:16 PM, Greg KH wrote:
>
> On Mon, Oct 17, 2016 at 01:13:55AM +0530, Pankaj Bharadiya wrote:
> > Replace CamelCase names with underscores to comply with the standard
> > kernel coding style.
> >
> > Signed-off-by: Pankaj Bharadiya
>
23 matches
Mail list logo