Skip to contentSkip to conversation

fsp: Move and rename fsp_types.h file

PATCH Superseded Sughosh Ganu 3 participants 4 messages Dec 14, 2020 – Dec 22, 2020 x86

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 fsp: Move and rename fsp_types.h file

The fsp_types.h header file contains macros for building signatures of different widths. These signature macros are architecture agnostic, and can be used in all places which use signatures in a data structure. Move and rename the fsp_types.h under the common include header.

---

Changes since v1:
Handled review comments from Simon Glass

Build tested for cougarcanyon2 board which builds the relevant fsp code.

 arch/x86/include/asm/fsp/fsp_support.h                      | 3 ++-
 .../x86/include/asm/fsp/fsp_types.h => include/signatures.h | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
 rename arch/x86/include/asm/fsp/fsp_types.h => include/signatures.h (95%)
arch/x86/include/asm/fsp/fsp_support.h +2 -1
index 29e511415c..3cd3e4fcf5 100644
@@ -7,11 +7,12 @@
 #ifndef __FSP_SUPPORT_H__
 #define __FSP_SUPPORT_H__
 
+#include <signatures.h>
+
 #include <asm/fsp/fsp_bootmode.h>
 #include <asm/fsp/fsp_fv.h>
 #include <asm/fsp/fsp_hob.h>
 #include <asm/fsp/fsp_infoheader.h>
-#include <asm/fsp/fsp_types.h>
 #include <asm/fsp_arch.h>
 #include <asm/fsp/fsp_azalia.h>
 
include/signatures.h renamed from arch/x86/include/asm/fsp/fsp_types.h +3 -3
similarity index 95%
rename from arch/x86/include/asm/fsp/fsp_types.h
rename to include/signatures.h
index 3d5b17ecf1..4042db1e00 100644
@@ -4,8 +4,8 @@
  * Copyright (C) 2014, Bin Meng <[email protected]>
  */
 
-#ifndef __FSP_TYPES_H__
-#define __FSP_TYPES_H__
+#ifndef __SIGNATURES_H__
+#define __SIGNATURES_H__
 
 /**
  * Returns a 16-bit signature built from 2 ASCII characters.
@@ -59,4 +59,4 @@
 #define SIGNATURE_64(A, B, C, D, E, F, G, H)	\
 	(SIGNATURE_32(A, B, C, D) | ((u64)(SIGNATURE_32(E, F, G, H)) << 32))
 
-#endif
+#endif /* __SIGNATURES_H__ */
Signature · 1 line
2.17.1
#1 lore raw

PATCH v2 1/1 fsp: Move and rename fsp_types.h file

Hi Sughosh,

Quoted 7 lines · Sughosh Ganu

The fsp_types.h header file contains macros for building signatures of different widths. These signature macros are architecture agnostic, and can be used in all places which use signatures in a data structure. Move and rename the fsp_types.h under the common include header.

Quoted 5 lines

---

Changes since v1:
Handled review comments from Simon Glass

(best to mention the changes you made rather than the name of your reviewer, since that won't mean much to others)

Quoted 8 lines

Build tested for cougarcanyon2 board which builds the relevant fsp code.

 arch/x86/include/asm/fsp/fsp_support.h                      | 3 ++-
 .../x86/include/asm/fsp/fsp_types.h => include/signatures.h | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
 rename arch/x86/include/asm/fsp/fsp_types.h => include/signatures.h (95%)
Quoted 46 lines
arch/x86/include/asm/fsp/fsp_support.h +2 -1
index 29e511415c..3cd3e4fcf5 100644
@@ -7,11 +7,12 @@
 #ifndef __FSP_SUPPORT_H__
 #define __FSP_SUPPORT_H__
 
+#include <signatures.h>
+
 #include <asm/fsp/fsp_bootmode.h>
 #include <asm/fsp/fsp_fv.h>
 #include <asm/fsp/fsp_hob.h>
 #include <asm/fsp/fsp_infoheader.h>
-#include <asm/fsp/fsp_types.h>
 #include <asm/fsp_arch.h>
 #include <asm/fsp/fsp_azalia.h>
 
include/signatures.h renamed from arch/x86/include/asm/fsp/fsp_types.h +3 -4
similarity index 95%
rename from arch/x86/include/asm/fsp/fsp_types.h
rename to include/signatures.h
index 3d5b17ecf1..4042db1e00 100644
@@ -4,8 +4,8 @@
  * Copyright (C) 2014, Bin Meng <[email protected]>
  */
 
-#ifndef __FSP_TYPES_H__
-#define __FSP_TYPES_H__
+#ifndef __SIGNATURES_H__
+#define __SIGNATURES_H__
 
 /**
  * Returns a 16-bit signature built from 2 ASCII characters.
@@ -59,4 +59,4 @@
 #define SIGNATURE_64(A, B, C, D, E, F, G, H)   \
        (SIGNATURE_32(A, B, C, D) | ((u64)(SIGNATURE_32(E, F, G, H)) << 32))
 
-#endif
+#endif /* __SIGNATURES_H__ */
--

2.17.1

#2 lore raw

PATCH v2 1/1 fsp: Move and rename fsp_types.h file

hi Simon,

Quoted 11 lines · Simon Glass

Hi Sughosh,

Quoted 7 lines · Sughosh Ganu

The fsp_types.h header file contains macros for building signatures of different widths. These signature macros are architecture agnostic, and can be used in all places which use signatures in a data structure. Move and rename the fsp_types.h under the common include header.

Quoted 9 lines
Quoted 5 lines

---

Changes since v1:
Handled review comments from Simon Glass

(best to mention the changes you made rather than the name of your reviewer, since that won't mean much to others)

Sure, will keep this in mind henceforth. Thanks.

-sughosh

Quoted 63 lines
Quoted 9 lines

Build tested for cougarcanyon2 board which builds the relevant fsp code.

 arch/x86/include/asm/fsp/fsp_support.h                      | 3 ++-
 .../x86/include/asm/fsp/fsp_types.h => include/signatures.h | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
 rename arch/x86/include/asm/fsp/fsp_types.h => include/signatures.h

(95%)

Review

Quoted 2 lines
(quoted diff) +0 -0

b/arch/x86/include/asm/fsp/fsp_support.h

Quoted 36 lines

index 29e511415c..3cd3e4fcf5 100644

arch/x86/include/asm/fsp/fsp_support.h +2 -1
@@ -7,11 +7,12 @@
 #ifndef __FSP_SUPPORT_H__
 #define __FSP_SUPPORT_H__
 
+#include <signatures.h>
+
 #include <asm/fsp/fsp_bootmode.h>
 #include <asm/fsp/fsp_fv.h>
 #include <asm/fsp/fsp_hob.h>
 #include <asm/fsp/fsp_infoheader.h>
-#include <asm/fsp/fsp_types.h>
 #include <asm/fsp_arch.h>
 #include <asm/fsp/fsp_azalia.h>
 
include/signatures.h renamed from arch/x86/include/asm/fsp/fsp_types.h +2 -2
similarity index 95%
rename from arch/x86/include/asm/fsp/fsp_types.h
rename to include/signatures.h
index 3d5b17ecf1..4042db1e00 100644
@@ -4,8 +4,8 @@
  * Copyright (C) 2014, Bin Meng <[email protected]>
  */
 
-#ifndef __FSP_TYPES_H__
-#define __FSP_TYPES_H__
+#ifndef __SIGNATURES_H__
+#define __SIGNATURES_H__
 
 /**
  * Returns a 16-bit signature built from 2 ASCII characters.

include/signatures.h line 60

Quoted 2 lines
include/signatures.h renamed from arch/x86/include/asm/fsp/fsp_types.h +0 -0
@@ -59,4 +59,4 @@
 #define SIGNATURE_64(A, B, C, D, E, F, G, H)   \
        (SIGNATURE_32(A, B, C, D) | ((u64)(SIGNATURE_32(E, F, G, H)) <<

32))

Quoted 6 lines
include/signatures.h renamed from arch/x86/include/asm/fsp/fsp_types.h +1 -2
-#endif
+#endif /* __SIGNATURES_H__ */
--

2.17.1

#3 lore raw

PATCH v2 1/1 fsp: Move and rename fsp_types.h file

In reply to Sughosh Ganu
Quoted 13 lines · Sughosh Ganu

The fsp_types.h header file contains macros for building signatures of different widths. These signature macros are architecture agnostic, and can be used in all places which use signatures in a data structure. Move and rename the fsp_types.h under the common include header.

---

Changes since v1:
Handled review comments from Simon Glass

Quoted 8 lines

Build tested for cougarcanyon2 board which builds the relevant fsp code.

 arch/x86/include/asm/fsp/fsp_support.h                      | 3 ++-
 .../x86/include/asm/fsp/fsp_types.h => include/signatures.h | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
 rename arch/x86/include/asm/fsp/fsp_types.h => include/signatures.h (95%)

applied to u-boot-x86, thanks!