All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION
@ 2019-07-11 16:28 Heinrich Schuchardt
  2019-07-12  0:59 ` AKASHI Takahiro
  0 siblings, 1 reply; 4+ messages in thread
From: Heinrich Schuchardt @ 2019-07-11 16:28 UTC (permalink / raw)
  To: u-boot

IMAGE_SUBSYSTEM_EFI_APPLICATION is already defined in
include/asm-generic/pe.h which is included in include/pe.h. We should
not define it twice.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
 include/pe.h | 1 -
 1 file changed, 1 deletion(-)

diff --git a/include/pe.h b/include/pe.h
index 36e1908b7e..c7aeb2dcb6 100644
--- a/include/pe.h
+++ b/include/pe.h
@@ -48,7 +48,6 @@ typedef struct _IMAGE_DOS_HEADER {

 #define IMAGE_NT_OPTIONAL_HDR32_MAGIC	0x10b
 #define IMAGE_NT_OPTIONAL_HDR64_MAGIC	0x20b
-#define IMAGE_SUBSYSTEM_EFI_APPLICATION	10

 typedef struct _IMAGE_FILE_HEADER {
 	uint16_t Machine;
--
2.20.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION
  2019-07-11 16:28 [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION Heinrich Schuchardt
@ 2019-07-12  0:59 ` AKASHI Takahiro
  2019-07-12  6:04   ` Heinrich Schuchardt
  0 siblings, 1 reply; 4+ messages in thread
From: AKASHI Takahiro @ 2019-07-12  0:59 UTC (permalink / raw)
  To: u-boot

Heinrich,

I wonder why we need "asm-generic/pe.h."
If IMAGE_SUBSYSTEM_EFI_APPLICATION can be arch-specific,
why not move other definitions, like * relocation types, too?

-Takahiro Akashi

On Thu, Jul 11, 2019 at 06:28:24PM +0200, Heinrich Schuchardt wrote:
> IMAGE_SUBSYSTEM_EFI_APPLICATION is already defined in
> include/asm-generic/pe.h which is included in include/pe.h. We should
> not define it twice.
> 
> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> ---
>  include/pe.h | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/include/pe.h b/include/pe.h
> index 36e1908b7e..c7aeb2dcb6 100644
> --- a/include/pe.h
> +++ b/include/pe.h
> @@ -48,7 +48,6 @@ typedef struct _IMAGE_DOS_HEADER {
> 
>  #define IMAGE_NT_OPTIONAL_HDR32_MAGIC	0x10b
>  #define IMAGE_NT_OPTIONAL_HDR64_MAGIC	0x20b
> -#define IMAGE_SUBSYSTEM_EFI_APPLICATION	10
> 
>  typedef struct _IMAGE_FILE_HEADER {
>  	uint16_t Machine;
> --
> 2.20.1
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION
  2019-07-12  0:59 ` AKASHI Takahiro
@ 2019-07-12  6:04   ` Heinrich Schuchardt
  2019-07-12  6:22     ` AKASHI Takahiro
  0 siblings, 1 reply; 4+ messages in thread
From: Heinrich Schuchardt @ 2019-07-12  6:04 UTC (permalink / raw)
  To: u-boot

On 7/12/19 2:59 AM, AKASHI Takahiro wrote:
> Heinrich,
>
> I wonder why we need "asm-generic/pe.h".

The assembler cannot understand includes that contain C specific syntax.
So we cannot include "pe.h". This is why "asm-generic/pe.h" has been
split off.

> If IMAGE_SUBSYSTEM_EFI_APPLICATION can be arch-specific,
> why not move other definitions, like * relocation types, too?

We need those symbols in include/asm-generic/pe.h that are used by
assembler code. IMAGE_SUBSYSTEM_EFI_APPLICATION is not arch-specific but
it is used in arch/arm/lib/crt0_arm_efi.S and others.

Best regards

Heinrich

>
> -Takahiro Akashi
>
> On Thu, Jul 11, 2019 at 06:28:24PM +0200, Heinrich Schuchardt wrote:
>> IMAGE_SUBSYSTEM_EFI_APPLICATION is already defined in
>> include/asm-generic/pe.h which is included in include/pe.h. We should
>> not define it twice.
>>
>> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
>> ---
>>   include/pe.h | 1 -
>>   1 file changed, 1 deletion(-)
>>
>> diff --git a/include/pe.h b/include/pe.h
>> index 36e1908b7e..c7aeb2dcb6 100644
>> --- a/include/pe.h
>> +++ b/include/pe.h
>> @@ -48,7 +48,6 @@ typedef struct _IMAGE_DOS_HEADER {
>>
>>   #define IMAGE_NT_OPTIONAL_HDR32_MAGIC	0x10b
>>   #define IMAGE_NT_OPTIONAL_HDR64_MAGIC	0x20b
>> -#define IMAGE_SUBSYSTEM_EFI_APPLICATION	10
>>
>>   typedef struct _IMAGE_FILE_HEADER {
>>   	uint16_t Machine;
>> --
>> 2.20.1
>>
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION
  2019-07-12  6:04   ` Heinrich Schuchardt
@ 2019-07-12  6:22     ` AKASHI Takahiro
  0 siblings, 0 replies; 4+ messages in thread
From: AKASHI Takahiro @ 2019-07-12  6:22 UTC (permalink / raw)
  To: u-boot

On Fri, Jul 12, 2019 at 08:04:59AM +0200, Heinrich Schuchardt wrote:
> On 7/12/19 2:59 AM, AKASHI Takahiro wrote:
> >Heinrich,
> >
> >I wonder why we need "asm-generic/pe.h".
> 
> The assembler cannot understand includes that contain C specific syntax.
> So we cannot include "pe.h". This is why "asm-generic/pe.h" has been
> split off.

If so, why not use "#if(n)def __ASSEMBLY__"?
It is a common usage in lots of headers.

-Takahiro Akashi

> >If IMAGE_SUBSYSTEM_EFI_APPLICATION can be arch-specific,
> >why not move other definitions, like * relocation types, too?
> 
> We need those symbols in include/asm-generic/pe.h that are used by
> assembler code. IMAGE_SUBSYSTEM_EFI_APPLICATION is not arch-specific but
> it is used in arch/arm/lib/crt0_arm_efi.S and others.
> 
> Best regards
> 
> Heinrich
> 
> >
> >-Takahiro Akashi
> >
> >On Thu, Jul 11, 2019 at 06:28:24PM +0200, Heinrich Schuchardt wrote:
> >>IMAGE_SUBSYSTEM_EFI_APPLICATION is already defined in
> >>include/asm-generic/pe.h which is included in include/pe.h. We should
> >>not define it twice.
> >>
> >>Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> >>---
> >>  include/pe.h | 1 -
> >>  1 file changed, 1 deletion(-)
> >>
> >>diff --git a/include/pe.h b/include/pe.h
> >>index 36e1908b7e..c7aeb2dcb6 100644
> >>--- a/include/pe.h
> >>+++ b/include/pe.h
> >>@@ -48,7 +48,6 @@ typedef struct _IMAGE_DOS_HEADER {
> >>
> >>  #define IMAGE_NT_OPTIONAL_HDR32_MAGIC	0x10b
> >>  #define IMAGE_NT_OPTIONAL_HDR64_MAGIC	0x20b
> >>-#define IMAGE_SUBSYSTEM_EFI_APPLICATION	10
> >>
> >>  typedef struct _IMAGE_FILE_HEADER {
> >>  	uint16_t Machine;
> >>--
> >>2.20.1
> >>
> >
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-07-12  6:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-11 16:28 [U-Boot] [PATCH 1/1] efi_loader: duplicate IMAGE_SUBSYSTEM_EFI_APPLICATION Heinrich Schuchardt
2019-07-12  0:59 ` AKASHI Takahiro
2019-07-12  6:04   ` Heinrich Schuchardt
2019-07-12  6:22     ` AKASHI Takahiro

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.