> Subject: Re: [PATCH V1 4/5] arm: include: protect header file
> hypervisor/arch/arm/include/asm/bitops.h
> 
> On 11.08.20 20:16, Alice Guo wrote:
> > Use "__ARM32_ASM_BITOPS__" to avoid redefine functions declared in
> > hypervisor/arch/arm/include/asm/bitops.h when building for AArch32.
> >
> 
> I do not yet understand the exact need. 

I think we should add some guard to make sure the contents in a header file
could only be included once. Otherwise it would be easy
to trigger issues if files was included twice by some nested including.

Regards,
Peng.

When does the build break without
> this patch? After patch 5 or already before it?
> 
> Jan
> 
> > Signed-off-by: Alice Guo <alice....@nxp.com>
> > ---
> >   hypervisor/arch/arm/include/asm/bitops.h | 5 +++++
> >   1 file changed, 5 insertions(+)
> >
> > diff --git a/hypervisor/arch/arm/include/asm/bitops.h
> > b/hypervisor/arch/arm/include/asm/bitops.h
> > index 67aee781..2940ae16 100644
> > --- a/hypervisor/arch/arm/include/asm/bitops.h
> > +++ b/hypervisor/arch/arm/include/asm/bitops.h
> > @@ -13,6 +13,10 @@
> >    */
> >
> >   /* also include from arm-common */
> > +
> > +#ifndef __ARM32_ASM_BITOPS__
> > +#define __ARM32_ASM_BITOPS__
> > +
> >   #include_next <asm/bitops.h>
> >
> >   static inline int atomic_test_and_set_bit(int nr, volatile unsigned
> > long *addr) @@ -42,3 +46,4 @@ static inline int
> > atomic_test_and_set_bit(int nr, volatile unsigned long *addr)
> >
> >     return !!(test);
> >   }
> > +#endif
> >
> 
> --
> Siemens AG, Corporate Technology, CT RDA IOT SES-DE Corporate
> Competence Center Embedded Linux
> 
> --
> You received this message because you are subscribed to the Google Groups
> "Jailhouse" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jailhouse-dev+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgroups
> .google.com%2Fd%2Fmsgid%2Fjailhouse-dev%2Fc7a37ee8-371c-d3e2-90a1-
> 7fda635505de%2540siemens.com&amp;data=02%7C01%7Cpeng.fan%40nxp.
> com%7C58d8abb6601b4bb72ed808d83eb3979c%7C686ea1d3bc2b4c6fa92c
> d99c5c301635%7C0%7C0%7C637328288346066670&amp;sdata=fuR42sXQ
> WaS7VI2EDGnGCPuQO8PvNlo6lsx66rgJqHM%3D&amp;reserved=0.

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jailhouse-dev/DB6PR0402MB2760E0441BE26A7031A07FE888420%40DB6PR0402MB2760.eurprd04.prod.outlook.com.

Reply via email to