en't tested it.
I tested the patchset and both clang-tidy and clang-analyzer work for me.
>
> [1] https://patchwork.kernel.org/patch/11687833/
>
>
>
> Masahiro Yamada (2):
> gen_compile_commands: parse only the first line of .*.cmd files
> gen_compile_comman
Sounds good. Do you think this patch is ready to land then?
On Thu, Aug 6, 2020 at 5:10 PM Masahiro Yamada wrote:
>
> On Fri, Aug 7, 2020 at 6:42 AM 'Nathan Huckleberry' via Clang Built
> Linux wrote:
> >
> > On Thu, Aug 6, 2020 at 3:44 AM Masahiro Yamada wr
tst sv_lr, #0 @ If there's no previous lr,
> + beq finished_setup @ we're done.
> ldr r0, [sv_lr, #-4]@ get call instruction
> ldr r3, .Lopcode+4
> and r2, r3, r0 @ is this a bl call
> --
> 2.28.0.163.g6104cc2f0b6-goog
>
Reviewed-by: Nathan Huckleberry
The style cleanup looks great. I just have one extra thing that
can probably be thrown into this patch.
On Thu, Jul 30, 2020 at 3:51 PM Nick Desaulniers
wrote:
>
> Removes the 1004 label; it was neither a control flow target, nor an
> instruction we expect to produce a fault.
>
> Gives the labels
Mostly looks good to me. Just a minor nit.
On Thu, Jul 30, 2020 at 3:51 PM Nick Desaulniers
wrote:
>
> If the value of the link register is not correct (tail call from asm
> that didn't set it, stack corruption, memory no longer mapped), then
> using it for an address calculation may trigger an e
On Thu, Aug 6, 2020 at 3:44 AM Masahiro Yamada wrote:
>
> On Tue, Jul 28, 2020 at 9:47 AM Nathan Huckleberry wrote:
> >
> > This patch adds clang-tidy and the clang static-analyzer as make
> > targets. The goal of this patch is to make static analysis tools
> >
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes v6->v7
* Fix issues with relative paths
* Additional style fixes
MAINTAINERS | 1 +
Makefile | 3 +
scripts/clang-tools/Makefile.clang-tools | 23 +
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes v5->v6
* Minor style fixes
MAINTAINERS | 1 +
Makefile | 3 +
scripts/clang-tools/Makefile.clang-tools | 23 ++
.../{ => clang-tools}/gen_compile_comma
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes v4->v5
* Use PEP8 style
* Other misc style fixes
MAINTAINERS | 1 +
Makefile | 3 +
scripts/clang-tools/Makefile.clang-tools | 23 ++
.../{ => clang-tool
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes v3->v4
* Update usages of static-analyzer to clang-analyzer
* Clarify -* explicitly in comment
* Remove filename printing
MAINTAINERS | 1 +
Makefile | 3
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes v2 -> v3
* Redirect clang-tidy output to stderr
* Style fixes
* Add directory to MAINTAINERS
MAINTAINERS | 1 +
Makefile | 3 +
scripts/clang-tools/Makefil
On Wed, Jul 8, 2020 at 2:11 PM Nick Desaulniers wrote:
>
> On Wed, Jul 8, 2020 at 11:21 AM 'Nathan Huckleberry' via Clang Built
> Linux wrote:
> >
> > This patch adds clang-tidy and the clang static-analyzer as make
> > targets. The goal of this patch is to
el codebase.
Signed-off-by: Nathan Huckleberry
---
Changes V1 -> V2:
* Remove dependencies on GNU Parallel
* * Clang-tidy/analyzer now invoked directly from python
Link: https://lkml.org/lkml/2019/8/6/941
Makefile | 3 +
scripts/clang-tools/Makefil
there are 8 less bytes between frames.
This fixes /proc//stack.
Link: https://github.com/ClangBuiltLinux/linux/issues/912
Reported-by: Miles Chen
Tested-by: Miles Chen
Cc: sta...@vger.kernel.org
Reviewed-by: Nick Desaulniers
Signed-off-by: Nathan Huckleberry
---
arch/arm/kernel/stacktrace.c
there are 8 less bytes between frames.
This fixes /proc//stack.
Link: https://github.com/ClangBuiltLinux/linux/issues/912
Signed-off-by: Nathan Huckleberry
---
arch/arm/kernel/stacktrace.c | 24
1 file changed, 24 insertions(+)
diff --git a/arch/arm/kernel/stacktrace.c b
.
Link: https://github.com/ClangBuiltLinux/linux/issues/867
Cc: clang-built-li...@googlegroups.com
Signed-off-by: Nathan Huckleberry
---
arch/riscv/include/asm/cmpxchg.h | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/riscv/include/asm/cmpxchg.h b/arch/riscv/include
...@googlegroups.com
Suggested-by: Tri Vo
Signed-off-by: Nathan Huckleberry
Tested-by: Nick Desaulniers
---
Changes from v2->v3
* Fix indentation on code
* Fix comment formatting
arch/arm/Kconfig.debug | 2 +-
arch/arm/Makefile | 5 +-
arch/arm/lib/Makefile | 8 +-
arch/
...@googlegroups.com
Suggested-by: Tri Vo
Signed-off-by: Nathan Huckleberry
---
Changes from v1->v2
* Fix indentation in various files
* Swap spaces for tabs
* Rename Ldsi to Lopcode
* Remove unused Ldsi entry
arch/arm/Kconfig.debug | 2 +-
arch/arm/Makefile | 5 +-
arch/arm/lib/Makef
On Tue, Aug 20, 2019 at 2:39 PM Nick Desaulniers
wrote:
>
> On Tue, Aug 20, 2019 at 12:44 PM Nathan Huckleberry wrote:
> >
> > The stackframe setup when compiled with clang is different.
> > Since the stack unwinder expects the gcc stackframe setup it
> > fails t
...@googlegroups.com
Suggested-by: Tri Vo
Signed-off-by: Nathan Huckleberry
---
Changes from RFC
* Push extra register to satisfy 8 byte alignment requirement
* Add clarifying comments
* Separate code into its own file
arch/arm/Kconfig.debug | 4 +-
arch/arm/Makefile | 5 +-
arch/arm/lib
is intended to be reverted after the warnings
have been cleaned up.
Signed-off-by: Nathan Huckleberry
Suggested-by: Nathan Chancellor
Reviewed-by: Nathan Chancellor
---
Changes v1->v2
* Move code to preexisting ifdef
scripts/Makefile.extrawarn | 1 +
1 file changed, 1 insertion(+)
diff --git a/s
is intended to be reverted after the warnings
have been cleaned up.
Signed-off-by: Nathan Huckleberry
---
Makefile | 4
scripts/Makefile.extrawarn | 3 +++
2 files changed, 7 insertions(+)
diff --git a/Makefile b/Makefile
index 1b23f95db176..93b9744e66a2 100644
--- a/Makefile
++
I'm not familiar enough with the code to rewrite these parts of the
driver. Silencing the warnings while maintaining the same
functionality was the goal of this patch.
On Fri, Jun 14, 2019 at 3:52 AM Daniel Lezcano
wrote:
>
>
> Hi Nathan,
>
> On 13/06/2019 23:12, Nath
_IMSG_THRD_SHIFT and
MV_XOR_V2_DMA_IMSG_TIMER_THRD_SHIFT are both 0. Since shifting by 0 does
nothing, these variables can be removed.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/521
Signed-off-by: Nathan Huckleberry
---
drivers/dma/mv_xor_v2.c | 11 --
Following up to see if this patch is going to be accepted.
quite a bit of noise, this
patch moves -Wimplicit-fallthrough to
Makefile.extrawarn if you are compiling with
clang.
Signed-off-by: Nathan Huckleberry
---
Makefile| 4 ++
include/linux/compiler_attributes.h | 4 ++
include/linux/jhash.h | 60
quite a bit of noise, this
patch moves -Wimplicit-fallthrough to
Makefile.extrawarn if you are compiling with
clang.
Signed-off-by: Nathan Huckleberry
---
Makefile | 4 +++
include/linux/jhash.h | 60 --
include/linux/mm.h | 9
wrote:
>
> On Fri, Aug 02, 2019 at 10:27:30AM -0700, Nathan Huckleberry wrote:
> > You're right. Would pushing an extra register be an adequate fix?
>
> Would forcing CONFIG_ARM_UNWIND=y for clang work as an alternative to
> this?
>
> Assuming clang supports -funwin
This patch is not intended to be merged. It simply shows the scale of
the effort involved in applying annotations in the case of intentionally
unbalanced calls to local_irq_disable.
Signed-off-by: Nathan Huckleberry
---
arch/arm64/kernel/debug-monitors.c | 1 +
arch/arm64/kernel
Signed-off-by: Nathan Huckleberry
---
These patches add clang-tidy and the clang static-analyzer as make
targets. The goal of these patches is to make static analysis tools
usable and extendable by any developer or researcher who is familiar
with basic c++.
The current static analysis tools
You're right. Would pushing an extra register be an adequate fix?
On Fri, Aug 2, 2019 at 7:24 AM Robin Murphy wrote:
>
> On 02/08/2019 00:10, Nathan Huckleberry wrote:
> > The stackframe setup when compiled with clang is different.
> > Since the stack unwinder expects the
The stackframe setup when compiled with clang is different.
Since the stack unwinder expects the gcc stackframe setup it
fails to print backtraces. This patch adds support for the
clang stackframe setup.
Cc: clang-built-li...@googlegroups.com
Suggested-by: Tri Vo
Signed-off-by: Nathan
Warning is not triggered in next. Looks like this patch is unnecessary.
Thanks,
Nathan Huckleberry
On Wed, Jul 3, 2019 at 4:23 AM Mark Rutland wrote:
>
> On Tue, Jul 02, 2019 at 04:41:35PM -0700, Nathan Huckleberry wrote:
> > When analyzed with the clang static analyzer the
&
Cc: clang-built-li...@googlegroups.com
Signed-off-by: Nathan Huckleberry
---
arch/arm64/include/asm/pgtable.h | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/arch/arm64/include/asm/pgtable.h b/arch/arm64/include/asm/pgtable.h
index fca26759081a..42ca4fc67f27 100644
--- a/
Cc: clang-built-li...@googlegroups.com
Signed-off-by: Nathan Huckleberry
---
Changes from v1 -> v2
* Added scope to avoid [-Wdeclaration-after-statement]
arch/arm64/include/asm/pgtable.h | 27 ---
1 file changed, 16 insertions(+), 11 deletions(-)
diff --git a/arch/arm6
Oops I forgot moving the variable declaration would cause a warning.
Will send a V2.
Thanks,
Nathan Huckleberry
On Tue, Jul 2, 2019 at 4:25 PM Nathan Chancellor
wrote:
>
> On Tue, Jul 02, 2019 at 04:13:02PM -0700, 'Nathan Huckleberry' via Clang
> Built Linux wrote:
> &g
. Deleting it to remove the
warning.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/524
Signed-off-by: Nathan Huckleberry
---
drivers/clk/rockchip/clk-rv1108.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/clk/rockchip/clk-rv1108.c
b
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/523
Signed-off-by: Nathan Huckleberry
---
drivers/clk/mediatek/clk-mt8516.c | 5 -
1 file changed, 5 deletions(-)
diff --git a/drivers/clk/mediatek/clk-mt8516.c
b/drivers/clk/mediatek/clk-mt85
uct
clockgen_muxinfo p5020_cmux_grp2
In the definition of the p5020 chip, the p2041 chip's info was used
instead. The p5020 and p2041 chips have different info. This is most
likely a typo.
Link: https://github.com/ClangBuiltLinux/linux/issues/525
Cc: clang-built-li...@googlegroups.com
Signed-o
Commit-ID: a9314773a91a1d3b36270085246a6715a326ff00
Gitweb: https://git.kernel.org/tip/a9314773a91a1d3b36270085246a6715a326ff00
Author: Nathan Huckleberry
AuthorDate: Fri, 14 Jun 2019 11:16:04 -0700
Committer: Thomas Gleixner
CommitDate: Sun, 23 Jun 2019 00:08:52 +0200
timer_list
There was an unused variable 'mvpp2_dbgfs_prs_pmap_fops'
Added a usage consistent with other fops to dump pmap
to userspace.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/529
Signed-off-by: Nathan Huckleberry
---
Changes from v1 ->
There was an unused variable 'mvpp2_dbgfs_prs_pmap_fops'
Added a usage consistent with other fops to dump pmap
to userspace.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/529
Signed-off-by: Nathan Huckleberry
---
drivers/net/ethernet/mar
.
Reported-by: Nick Desaulniers
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/520
Signed-off-by: Nathan Huckleberry
---
scripts/Makefile.extrawarn | 1 -
1 file changed, 1 deletion(-)
diff --git a/scripts/Makefile.extrawarn b/scripts
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/528
Signed-off-by: Nathan Huckleberry
---
drivers/gpu/drm/msm/disp/dpu1/dpu_formats.c | 110
1 file changed, 110 deletions(-)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_fo
fdef guard around proc_fs specific code.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/534
Signed-off-by: Nathan Huckleberry
---
kernel/time/timer_list.c | 36 +++-
1 file changed, 19 insertions(+), 17 deletions(-)
di
.com/ClangBuiltLinux/linux/issues/530
Signed-off-by: Nathan Huckleberry
---
drivers/net/wireless/ti/wl18xx/main.c | 38 ---
1 file changed, 38 deletions(-)
diff --git a/drivers/net/wireless/ti/wl18xx/main.c
b/drivers/net/wireless/ti/wl18xx/main.c
index a5e0604d3009..0b3cf
e is no real reason for
TJ_3 to be -41. Usages subtract -41, code would be cleaner to just add.
Fixes: 4eb39f79ef44 ("thermal: rcar_gen3_thermal: Update value of Tj_1")
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/531
Signed-off-by: Nat
generated
.
~~~ ^
CONTROL1_TSEN_AVG_SHIFT is defined to be zero.
Since shifting by zero does nothing this variable can be removed.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/532
Signed-off-by: Nathan Huckleberry
---
drivers/thermal/armada_thermal.c | 5 ++---
1 fi
out to ask the best steps for cleaning this up.
If the variable is no longer needed I'd like to send a patch to remove it.
https://github.com/ClangBuiltLinux/linux/issues/533
Thanks,
Nathan Huckleberry
ifdef.
It seems logical to move the variable into the ifdef as well.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/526
Signed-off-by: Nathan Huckleberry
---
Changes from v1 -> v2:
* Moved definition of tegra124_mc_emem_regs into existing ifdef
d
inside the ifdef.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/527
Signed-off-by: Nathan Huckleberry
---
Changes from v1 -> v2
* Moved definition of mxt_video_fops into existing ifdef
drivers/input/touchscreen/atmel_mxt_ts.c | 20 ++-
ifdef.
It seems logical to move the variable into the ifdef as well.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/526
Signed-off-by: Nathan Huckleberry
---
drivers/memory/tegra/tegra124.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/driv
_IMSG_THRD_SHIFT and
MV_XOR_V2_DMA_IMSG_TIMER_THRD_SHIFT are both 0. Since shifting by 0 does
nothing, these variables can be removed.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/521
Signed-off-by: Nathan Huckleberry
---
drivers/dma/mv_xor_v2.c | 11 --
it.
Since tac5711_controls is identical to tas5721_controls we can just swap
them
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/522
Signed-off-by: Nathan Huckleberry
---
sound/soc/codecs/tas571x.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
di
inside the ifdef.
Cc: clang-built-li...@googlegroups.com
Link: https://github.com/ClangBuiltLinux/linux/issues/527
Signed-off-by: Nathan Huckleberry
---
drivers/input/touchscreen/atmel_mxt_ts.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c
b/dri
issues/518
Suggested-by: Nathan Chancellor
Signed-off-by: Nathan Huckleberry
---
drivers/clk/qcom/gcc-msm8996.c | 36 --
1 file changed, 36 deletions(-)
diff --git a/drivers/clk/qcom/gcc-msm8996.c b/drivers/clk/qcom/gcc-msm8996.c
index d2f39a972cad..d004cdaa0e39
56 matches
Mail list logo