diff mbox series

[1/2] parisc: vdso: remove dead code in vdso32/Makefile

Message ID 20240330100849.426874-1-masahiroy@kernel.org (mailing list archive)
State New
Headers show
Series [1/2] parisc: vdso: remove dead code in vdso32/Makefile | expand

Commit Message

Masahiro Yamada March 30, 2024, 10:08 a.m. UTC
This commit removes the unused build rule because 'obj-cvdso32' is
not defined.

If you add a C file into arch/parisc/kernel/vdso32/ in the future,
you can revert this change. The kernel does not keep code that
may or may not be used.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---

 arch/parisc/kernel/vdso32/Makefile | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Comments

Helge Deller March 30, 2024, 10:46 p.m. UTC | #1
On 3/30/24 11:08, Masahiro Yamada wrote:
> This commit removes the unused build rule because 'obj-cvdso32' is
> not defined.
>
> If you add a C file into arch/parisc/kernel/vdso32/ in the future,
> you can revert this change. The kernel does not keep code that
> may or may not be used.
>
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

Acked-by: Helge Deller <deller@gmx.de>

Thank you for those cleanups, Masahiro!

Shall I take your patches via parisc git tree, or will you take
them via your git trees?

Helge


> ---
>
>   arch/parisc/kernel/vdso32/Makefile | 7 +------
>   1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/arch/parisc/kernel/vdso32/Makefile b/arch/parisc/kernel/vdso32/Makefile
> index 4459a48d2303..e45d46bf46a2 100644
> --- a/arch/parisc/kernel/vdso32/Makefile
> +++ b/arch/parisc/kernel/vdso32/Makefile
> @@ -26,23 +26,18 @@ $(obj)/vdso32_wrapper.o : $(obj)/vdso32.so FORCE
>
>   # Force dependency (incbin is bad)
>   # link rule for the .so file, .lds has to be first
> -$(obj)/vdso32.so: $(src)/vdso32.lds $(obj-vdso32) $(obj-cvdso32) $(VDSO_LIBGCC) FORCE
> +$(obj)/vdso32.so: $(src)/vdso32.lds $(obj-vdso32) $(VDSO_LIBGCC) FORCE
>   	$(call if_changed,vdso32ld)
>
>   # assembly rules for the .S files
>   $(obj-vdso32): %.o: %.S FORCE
>   	$(call if_changed_dep,vdso32as)
>
> -$(obj-cvdso32): %.o: %.c FORCE
> -	$(call if_changed_dep,vdso32cc)
> -
>   # actual build commands
>   quiet_cmd_vdso32ld = VDSO32L $@
>         cmd_vdso32ld = $(CROSS32CC) $(c_flags) -Wl,-T $(filter-out FORCE, $^) -o $@
>   quiet_cmd_vdso32as = VDSO32A $@
>         cmd_vdso32as = $(CROSS32CC) $(a_flags) -c -o $@ $<
> -quiet_cmd_vdso32cc = VDSO32C $@
> -      cmd_vdso32cc = $(CROSS32CC) $(c_flags) -c -fPIC -mno-fast-indirect-calls -o $@ $<
>
>   # Generate VDSO offsets using helper script
>   gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh
Masahiro Yamada April 16, 2024, 2:26 a.m. UTC | #2
On Sun, Mar 31, 2024 at 7:46 AM Helge Deller <deller@gmx.de> wrote:
>
> On 3/30/24 11:08, Masahiro Yamada wrote:
> > This commit removes the unused build rule because 'obj-cvdso32' is
> > not defined.
> >
> > If you add a C file into arch/parisc/kernel/vdso32/ in the future,
> > you can revert this change. The kernel does not keep code that
> > may or may not be used.
> >
> > Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
>
> Acked-by: Helge Deller <deller@gmx.de>
>
> Thank you for those cleanups, Masahiro!
>
> Shall I take your patches via parisc git tree, or will you take
> them via your git trees?
>
> Helge


Thanks, I applied this to my tree now.

(I need this as a prerequisite for my Kbuild work)
diff mbox series

Patch

diff --git a/arch/parisc/kernel/vdso32/Makefile b/arch/parisc/kernel/vdso32/Makefile
index 4459a48d2303..e45d46bf46a2 100644
--- a/arch/parisc/kernel/vdso32/Makefile
+++ b/arch/parisc/kernel/vdso32/Makefile
@@ -26,23 +26,18 @@  $(obj)/vdso32_wrapper.o : $(obj)/vdso32.so FORCE
 
 # Force dependency (incbin is bad)
 # link rule for the .so file, .lds has to be first
-$(obj)/vdso32.so: $(src)/vdso32.lds $(obj-vdso32) $(obj-cvdso32) $(VDSO_LIBGCC) FORCE
+$(obj)/vdso32.so: $(src)/vdso32.lds $(obj-vdso32) $(VDSO_LIBGCC) FORCE
 	$(call if_changed,vdso32ld)
 
 # assembly rules for the .S files
 $(obj-vdso32): %.o: %.S FORCE
 	$(call if_changed_dep,vdso32as)
 
-$(obj-cvdso32): %.o: %.c FORCE
-	$(call if_changed_dep,vdso32cc)
-
 # actual build commands
 quiet_cmd_vdso32ld = VDSO32L $@
       cmd_vdso32ld = $(CROSS32CC) $(c_flags) -Wl,-T $(filter-out FORCE, $^) -o $@
 quiet_cmd_vdso32as = VDSO32A $@
       cmd_vdso32as = $(CROSS32CC) $(a_flags) -c -o $@ $<
-quiet_cmd_vdso32cc = VDSO32C $@
-      cmd_vdso32cc = $(CROSS32CC) $(c_flags) -c -fPIC -mno-fast-indirect-calls -o $@ $<
 
 # Generate VDSO offsets using helper script
 gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh