diff mbox series

riscv: vdso: do not strip debugging info for vdso.so.dbg

Message ID 20240611040947.3024710-1-changbin.du@huawei.com (mailing list archive)
State New
Headers show
Series riscv: vdso: do not strip debugging info for vdso.so.dbg | expand

Checks

Context Check Description
conchuod/vmtest-for-next-PR success PR summary
conchuod/patch-1-test-1 success .github/scripts/patches/tests/build_rv32_defconfig.sh
conchuod/patch-1-test-2 success .github/scripts/patches/tests/build_rv64_clang_allmodconfig.sh
conchuod/patch-1-test-3 success .github/scripts/patches/tests/build_rv64_gcc_allmodconfig.sh
conchuod/patch-1-test-4 success .github/scripts/patches/tests/build_rv64_nommu_k210_defconfig.sh
conchuod/patch-1-test-5 success .github/scripts/patches/tests/build_rv64_nommu_virt_defconfig.sh
conchuod/patch-1-test-6 success .github/scripts/patches/tests/checkpatch.sh
conchuod/patch-1-test-7 success .github/scripts/patches/tests/dtb_warn_rv64.sh
conchuod/patch-1-test-8 success .github/scripts/patches/tests/header_inline.sh
conchuod/patch-1-test-9 success .github/scripts/patches/tests/kdoc.sh
conchuod/patch-1-test-10 success .github/scripts/patches/tests/module_param.sh
conchuod/patch-1-test-11 success .github/scripts/patches/tests/verify_fixes.sh
conchuod/patch-1-test-12 success .github/scripts/patches/tests/verify_signedoff.sh

Commit Message

duchangbin June 11, 2024, 4:09 a.m. UTC
The vdso.so.dbg is a debug version of vdso and could be used for debugging
purpose. For example, perf-annotate requires debugging info to show source
lines. So let's keep its debugging info.

Signed-off-by: Changbin Du <changbin.du@huawei.com>
---
 arch/riscv/kernel/vdso/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

duchangbin July 4, 2024, 1:57 a.m. UTC | #1
Hello,
Is there any problem with this change? Ping~

On Tue, Jun 11, 2024 at 12:09:47PM +0800, Changbin Du wrote:
> The vdso.so.dbg is a debug version of vdso and could be used for debugging
> purpose. For example, perf-annotate requires debugging info to show source
> lines. So let's keep its debugging info.
> 
> Signed-off-by: Changbin Du <changbin.du@huawei.com>
> ---
>  arch/riscv/kernel/vdso/Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile
> index f7ef8ad9b550..960feb1526ca 100644
> --- a/arch/riscv/kernel/vdso/Makefile
> +++ b/arch/riscv/kernel/vdso/Makefile
> @@ -45,7 +45,7 @@ $(obj)/vdso.o: $(obj)/vdso.so
>  # link rule for the .so file, .lds has to be first
>  $(obj)/vdso.so.dbg: $(obj)/vdso.lds $(obj-vdso) FORCE
>  	$(call if_changed,vdsold)
> -LDFLAGS_vdso.so.dbg = -shared -S -soname=linux-vdso.so.1 \
> +LDFLAGS_vdso.so.dbg = -shared -soname=linux-vdso.so.1 \
>  	--build-id=sha1 --hash-style=both --eh-frame-hdr
>  
>  # strip rule for the .so file
> -- 
> 2.34.1
>
Cyril Bur July 4, 2024, 4:29 a.m. UTC | #2
On 4/7/2024 11:57 am, duchangbin wrote:
> Hello,
> Is there any problem with this change? Ping~
> 
> On Tue, Jun 11, 2024 at 12:09:47PM +0800, Changbin Du wrote:
>> The vdso.so.dbg is a debug version of vdso and could be used for debugging
>> purpose. For example, perf-annotate requires debugging info to show source
>> lines. So let's keep its debugging info.
>>
>> Signed-off-by: Changbin Du <changbin.du@huawei.com>

Looks good to me

Reviewed-by: Cyril Bur <cyrilbur@tenstorrent.com>
>> ---
>>   arch/riscv/kernel/vdso/Makefile | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile
>> index f7ef8ad9b550..960feb1526ca 100644
>> --- a/arch/riscv/kernel/vdso/Makefile
>> +++ b/arch/riscv/kernel/vdso/Makefile
>> @@ -45,7 +45,7 @@ $(obj)/vdso.o: $(obj)/vdso.so
>>   # link rule for the .so file, .lds has to be first
>>   $(obj)/vdso.so.dbg: $(obj)/vdso.lds $(obj-vdso) FORCE
>>   	$(call if_changed,vdsold)
>> -LDFLAGS_vdso.so.dbg = -shared -S -soname=linux-vdso.so.1 \
>> +LDFLAGS_vdso.so.dbg = -shared -soname=linux-vdso.so.1 \
>>   	--build-id=sha1 --hash-style=both --eh-frame-hdr
>>   
>>   # strip rule for the .so file
>> -- 
>> 2.34.1
>>
>
Alexandre Ghiti July 5, 2024, 5:53 a.m. UTC | #3
Hi Changbin,

On 11/06/2024 06:09, Changbin Du wrote:
> The vdso.so.dbg is a debug version of vdso and could be used for debugging
> purpose. For example, perf-annotate requires debugging info to show source
> lines. So let's keep its debugging info.
>
> Signed-off-by: Changbin Du <changbin.du@huawei.com>
> ---
>   arch/riscv/kernel/vdso/Makefile | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile
> index f7ef8ad9b550..960feb1526ca 100644
> --- a/arch/riscv/kernel/vdso/Makefile
> +++ b/arch/riscv/kernel/vdso/Makefile
> @@ -45,7 +45,7 @@ $(obj)/vdso.o: $(obj)/vdso.so
>   # link rule for the .so file, .lds has to be first
>   $(obj)/vdso.so.dbg: $(obj)/vdso.lds $(obj-vdso) FORCE
>   	$(call if_changed,vdsold)
> -LDFLAGS_vdso.so.dbg = -shared -S -soname=linux-vdso.so.1 \
> +LDFLAGS_vdso.so.dbg = -shared -soname=linux-vdso.so.1 \
>   	--build-id=sha1 --hash-style=both --eh-frame-hdr
>   
>   # strip rule for the .so file


Reviewed-by: Alexandre Ghiti <alexghiti@rivosinc.com>

Thanks,

Alex
diff mbox series

Patch

diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile
index f7ef8ad9b550..960feb1526ca 100644
--- a/arch/riscv/kernel/vdso/Makefile
+++ b/arch/riscv/kernel/vdso/Makefile
@@ -45,7 +45,7 @@  $(obj)/vdso.o: $(obj)/vdso.so
 # link rule for the .so file, .lds has to be first
 $(obj)/vdso.so.dbg: $(obj)/vdso.lds $(obj-vdso) FORCE
 	$(call if_changed,vdsold)
-LDFLAGS_vdso.so.dbg = -shared -S -soname=linux-vdso.so.1 \
+LDFLAGS_vdso.so.dbg = -shared -soname=linux-vdso.so.1 \
 	--build-id=sha1 --hash-style=both --eh-frame-hdr
 
 # strip rule for the .so file