diff mbox series

[edk2,v2] AppPkg: fix webserver build for !Ia32/X64

Message ID 20181102105015.3609-1-leif.lindholm@linaro.org
State New
Headers show
Series [edk2,v2] AppPkg: fix webserver build for !Ia32/X64 | expand

Commit Message

Leif Lindholm Nov. 2, 2018, 10:50 a.m. UTC
The WebServer application is not meant to be Ia32/X64 specific, and would
build for other architectures, if it wasn't for the
  #include <Register/Msr.h>
in WebServer.h. Move that statement to Mtrr.c instead, which is the only
consumer, and is already being filtered out for other architectures.

Cc: Daryl McDaniel <edk2-lists@mc2research.org>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>

---

Resending only 1/6, since the others got R-b already.
Looking at PageList.c, the app was clearly intended to be portable,
so updated commit message to reflect this.

 AppPkg/Applications/Sockets/WebServer/WebServer.h | 1 -
 AppPkg/Applications/Sockets/WebServer/Mtrr.c      | 1 +
 2 files changed, 1 insertion(+), 1 deletion(-)

-- 
2.11.0

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Comments

Leif Lindholm Feb. 4, 2019, 12:04 p.m. UTC | #1
Mike, Daryl, Jaben - any comments on v2?

On Fri, Nov 02, 2018 at 10:50:15AM +0000, Leif Lindholm wrote:
> The WebServer application is not meant to be Ia32/X64 specific, and would

> build for other architectures, if it wasn't for the

>   #include <Register/Msr.h>

> in WebServer.h. Move that statement to Mtrr.c instead, which is the only

> consumer, and is already being filtered out for other architectures.

> 

> Cc: Daryl McDaniel <edk2-lists@mc2research.org>

> Cc: Jaben Carsey <jaben.carsey@intel.com>

> Contributed-under: TianoCore Contribution Agreement 1.1

> Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>

> ---

> 

> Resending only 1/6, since the others got R-b already.

> Looking at PageList.c, the app was clearly intended to be portable,

> so updated commit message to reflect this.

> 

>  AppPkg/Applications/Sockets/WebServer/WebServer.h | 1 -

>  AppPkg/Applications/Sockets/WebServer/Mtrr.c      | 1 +

>  2 files changed, 1 insertion(+), 1 deletion(-)

> 

> diff --git a/AppPkg/Applications/Sockets/WebServer/WebServer.h b/AppPkg/Applications/Sockets/WebServer/WebServer.h

> index 21b07b63df..16c30c8d6d 100644

> --- a/AppPkg/Applications/Sockets/WebServer/WebServer.h

> +++ b/AppPkg/Applications/Sockets/WebServer/WebServer.h

> @@ -20,7 +20,6 @@

>  

>  #include <Guid/EventGroup.h>

>  

> -#include <Register/Msr.h>

>  #include <Library/BaseMemoryLib.h>

>  #include <Library/DebugLib.h>

>  #include <Library/MemoryAllocationLib.h>

> diff --git a/AppPkg/Applications/Sockets/WebServer/Mtrr.c b/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> index 54356bde64..4b8482d4e2 100644

> --- a/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> +++ b/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> @@ -15,6 +15,7 @@

>  

>  #include <WebServer.h>

>  #include <Library/MtrrLib.h>

> +#include <Register/Msr.h>

>  

>  #define VARIABLE_MTRR_VALID     0x800

>  

> -- 

> 2.11.0

> 

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Philippe Mathieu-Daudé Feb. 4, 2019, 12:06 p.m. UTC | #2
On 11/2/18 11:50 AM, Leif Lindholm wrote:
> The WebServer application is not meant to be Ia32/X64 specific, and would
> build for other architectures, if it wasn't for the
>   #include <Register/Msr.h>
> in WebServer.h. Move that statement to Mtrr.c instead, which is the only
> consumer, and is already being filtered out for other architectures.
> 
> Cc: Daryl McDaniel <edk2-lists@mc2research.org>
> Cc: Jaben Carsey <jaben.carsey@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.1
> Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>

> ---
> 
> Resending only 1/6, since the others got R-b already.
> Looking at PageList.c, the app was clearly intended to be portable,
> so updated commit message to reflect this.
> 
>  AppPkg/Applications/Sockets/WebServer/WebServer.h | 1 -
>  AppPkg/Applications/Sockets/WebServer/Mtrr.c      | 1 +
>  2 files changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/AppPkg/Applications/Sockets/WebServer/WebServer.h b/AppPkg/Applications/Sockets/WebServer/WebServer.h
> index 21b07b63df..16c30c8d6d 100644
> --- a/AppPkg/Applications/Sockets/WebServer/WebServer.h
> +++ b/AppPkg/Applications/Sockets/WebServer/WebServer.h
> @@ -20,7 +20,6 @@
>  
>  #include <Guid/EventGroup.h>
>  
> -#include <Register/Msr.h>
>  #include <Library/BaseMemoryLib.h>
>  #include <Library/DebugLib.h>
>  #include <Library/MemoryAllocationLib.h>
> diff --git a/AppPkg/Applications/Sockets/WebServer/Mtrr.c b/AppPkg/Applications/Sockets/WebServer/Mtrr.c
> index 54356bde64..4b8482d4e2 100644
> --- a/AppPkg/Applications/Sockets/WebServer/Mtrr.c
> +++ b/AppPkg/Applications/Sockets/WebServer/Mtrr.c
> @@ -15,6 +15,7 @@
>  
>  #include <WebServer.h>
>  #include <Library/MtrrLib.h>
> +#include <Register/Msr.h>
>  
>  #define VARIABLE_MTRR_VALID     0x800
>  
>
Carsey, Jaben Feb. 4, 2019, 3:27 p.m. UTC | #3
Leif,

Sorry, I missed this one.  Code change here looks good.

Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>


> -----Original Message-----

> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of

> Leif Lindholm

> Sent: Monday, February 04, 2019 4:04 AM

> To: edk2-devel@lists.01.org

> Cc: Kinney, Michael D <michael.d.kinney@intel.com>; Carsey, Jaben

> <jaben.carsey@intel.com>; Daryl McDaniel <edk2-lists@mc2research.org>

> Subject: Re: [edk2] [PATCH v2] AppPkg: fix webserver build for !Ia32/X64

> Importance: High

> 

> Mike, Daryl, Jaben - any comments on v2?

> 

> On Fri, Nov 02, 2018 at 10:50:15AM +0000, Leif Lindholm wrote:

> > The WebServer application is not meant to be Ia32/X64 specific, and would

> > build for other architectures, if it wasn't for the

> >   #include <Register/Msr.h>

> > in WebServer.h. Move that statement to Mtrr.c instead, which is the only

> > consumer, and is already being filtered out for other architectures.

> >

> > Cc: Daryl McDaniel <edk2-lists@mc2research.org>

> > Cc: Jaben Carsey <jaben.carsey@intel.com>

> > Contributed-under: TianoCore Contribution Agreement 1.1

> > Signed-off-by: Leif Lindholm <leif.lindholm@linaro.org>

> > ---

> >

> > Resending only 1/6, since the others got R-b already.

> > Looking at PageList.c, the app was clearly intended to be portable,

> > so updated commit message to reflect this.

> >

> >  AppPkg/Applications/Sockets/WebServer/WebServer.h | 1 -

> >  AppPkg/Applications/Sockets/WebServer/Mtrr.c      | 1 +

> >  2 files changed, 1 insertion(+), 1 deletion(-)

> >

> > diff --git a/AppPkg/Applications/Sockets/WebServer/WebServer.h

> b/AppPkg/Applications/Sockets/WebServer/WebServer.h

> > index 21b07b63df..16c30c8d6d 100644

> > --- a/AppPkg/Applications/Sockets/WebServer/WebServer.h

> > +++ b/AppPkg/Applications/Sockets/WebServer/WebServer.h

> > @@ -20,7 +20,6 @@

> >

> >  #include <Guid/EventGroup.h>

> >

> > -#include <Register/Msr.h>

> >  #include <Library/BaseMemoryLib.h>

> >  #include <Library/DebugLib.h>

> >  #include <Library/MemoryAllocationLib.h>

> > diff --git a/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> b/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> > index 54356bde64..4b8482d4e2 100644

> > --- a/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> > +++ b/AppPkg/Applications/Sockets/WebServer/Mtrr.c

> > @@ -15,6 +15,7 @@

> >

> >  #include <WebServer.h>

> >  #include <Library/MtrrLib.h>

> > +#include <Register/Msr.h>

> >

> >  #define VARIABLE_MTRR_VALID     0x800

> >

> > --

> > 2.11.0

> >

> _______________________________________________

> edk2-devel mailing list

> edk2-devel@lists.01.org

> https://lists.01.org/mailman/listinfo/edk2-devel

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
diff mbox series

Patch

diff --git a/AppPkg/Applications/Sockets/WebServer/WebServer.h b/AppPkg/Applications/Sockets/WebServer/WebServer.h
index 21b07b63df..16c30c8d6d 100644
--- a/AppPkg/Applications/Sockets/WebServer/WebServer.h
+++ b/AppPkg/Applications/Sockets/WebServer/WebServer.h
@@ -20,7 +20,6 @@ 
 
 #include <Guid/EventGroup.h>
 
-#include <Register/Msr.h>
 #include <Library/BaseMemoryLib.h>
 #include <Library/DebugLib.h>
 #include <Library/MemoryAllocationLib.h>
diff --git a/AppPkg/Applications/Sockets/WebServer/Mtrr.c b/AppPkg/Applications/Sockets/WebServer/Mtrr.c
index 54356bde64..4b8482d4e2 100644
--- a/AppPkg/Applications/Sockets/WebServer/Mtrr.c
+++ b/AppPkg/Applications/Sockets/WebServer/Mtrr.c
@@ -15,6 +15,7 @@ 
 
 #include <WebServer.h>
 #include <Library/MtrrLib.h>
+#include <Register/Msr.h>
 
 #define VARIABLE_MTRR_VALID     0x800