[RFC PATCH v3 05/17] s390: asm/dwarf.h should only be included in assembly files

Jens Remus posted 17 patches 1 week, 3 days ago
[RFC PATCH v3 05/17] s390: asm/dwarf.h should only be included in assembly files
Posted by Jens Remus 1 week, 3 days ago
Align to x86 and add a compile-time check that asm/dwarf.h is only
included in pure assembly files.

Signed-off-by: Jens Remus <jremus@linux.ibm.com>
---

Notes (jremus):
    Changes in RFC v2:
    - Adjust to upstream change of __ASSEMBLY__ to __ASSEMBLER__.

 arch/s390/include/asm/dwarf.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/s390/include/asm/dwarf.h b/arch/s390/include/asm/dwarf.h
index e3ad6798d0cd..df9f467910f7 100644
--- a/arch/s390/include/asm/dwarf.h
+++ b/arch/s390/include/asm/dwarf.h
@@ -2,7 +2,9 @@
 #ifndef _ASM_S390_DWARF_H
 #define _ASM_S390_DWARF_H
 
-#ifdef __ASSEMBLER__
+#ifndef __ASSEMBLER__
+#warning "asm/dwarf.h should be only included in pure assembly files"
+#endif
 
 #define CFI_STARTPROC		.cfi_startproc
 #define CFI_ENDPROC		.cfi_endproc
@@ -33,6 +35,4 @@
 	.cfi_sections .eh_frame, .debug_frame
 #endif
 
-#endif	/* __ASSEMBLER__ */
-
 #endif	/* _ASM_S390_DWARF_H */
-- 
2.51.0
Re: [RFC PATCH v3 05/17] s390: asm/dwarf.h should only be included in assembly files
Posted by Heiko Carstens 1 week, 1 day ago
On Mon, Dec 08, 2025 at 06:15:47PM +0100, Jens Remus wrote:
> Align to x86 and add a compile-time check that asm/dwarf.h is only
> included in pure assembly files.
> 
> Signed-off-by: Jens Remus <jremus@linux.ibm.com>
> ---
> 
> Notes (jremus):
>     Changes in RFC v2:
>     - Adjust to upstream change of __ASSEMBLY__ to __ASSEMBLER__.
> 
>  arch/s390/include/asm/dwarf.h | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Is there a reason why this and the next two patches couldn't go upstream
already now? It looks like they improve things in any case.
No dependency to the sframe work.
Re: [RFC PATCH v3 05/17] s390: asm/dwarf.h should only be included in assembly files
Posted by Jens Remus 1 week, 1 day ago
On 12/10/2025 4:16 PM, Heiko Carstens wrote:
> On Mon, Dec 08, 2025 at 06:15:47PM +0100, Jens Remus wrote:
>> Align to x86 and add a compile-time check that asm/dwarf.h is only
>> included in pure assembly files.

> Is there a reason why this and the next two patches couldn't go upstream
> already now? It looks like they improve things in any case.
> No dependency to the sframe work.

They probably could go upstream now.  At least this one.  For the two
other patches the question is whether we want to wait for whether the
respective x86 changes go upstream, as their descriptions claim to align
to x86.

Regards,
Jens
-- 
Jens Remus
Linux on Z Development (D3303)
+49-7031-16-1128 Office
jremus@de.ibm.com

IBM

IBM Deutschland Research & Development GmbH; Vorsitzender des Aufsichtsrats: Wolfgang Wendt; Geschäftsführung: David Faller; Sitz der Gesellschaft: Böblingen; Registergericht: Amtsgericht Stuttgart, HRB 243294
IBM Data Privacy Statement: https://www.ibm.com/privacy/