Hi Eric,

On 07/24/13 10:04, Dong, Eric wrote:
> 
> I will refine the change in OvmePkg when I check in the code, also attach the 
> uni file this patch.

Thank you.

I needed the attached patches to build OvmfPkg on RHEL-6.4 (gcc-4.4).
(Some of them are probably incorrect.)

Unfortunately, even with these patches applied, when I enter the setup
UI from the TianoCore splash screen, the UI is not usable. Please find
the VM screenshot (19KB) attached as well.

Thanks,
Laszlo
From 93339fc2fe9b64dca4fd252c02814bf349106d0a Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Wed, 24 Jul 2013 12:05:07 +0200
Subject: [PATCH 1/5] DisplayProtocol.h, FormBrowserEx2.h: use forward slashes 
in #include's

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
 MdeModulePkg/Include/Protocol/DisplayProtocol.h |    2 +-
 MdeModulePkg/Include/Protocol/FormBrowserEx2.h  |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/MdeModulePkg/Include/Protocol/DisplayProtocol.h 
b/MdeModulePkg/Include/Protocol/DisplayProtocol.h
index 3be8566..d4f0deb 100644
--- a/MdeModulePkg/Include/Protocol/DisplayProtocol.h
+++ b/MdeModulePkg/Include/Protocol/DisplayProtocol.h
@@ -15,7 +15,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER 
EXPRESS OR IMPLIED.
 #ifndef __DISPLAY_PROTOCOL_H__
 #define __DISPLAY_PROTOCOL_H__
 
-#include <Protocol\FormBrowser2.h>
+#include <Protocol/FormBrowser2.h>
 
 #define EDKII_FORM_DISPLAY_ENGINE_PROTOCOL_GUID  \
   { 0x9bbe29e9, 0xfda1, 0x41ec, { 0xad, 0x52, 0x45, 0x22, 0x13, 0x74, 0x2d, 
0x2e } }
diff --git a/MdeModulePkg/Include/Protocol/FormBrowserEx2.h 
b/MdeModulePkg/Include/Protocol/FormBrowserEx2.h
index 13fab6a..817f80d 100644
--- a/MdeModulePkg/Include/Protocol/FormBrowserEx2.h
+++ b/MdeModulePkg/Include/Protocol/FormBrowserEx2.h
@@ -16,7 +16,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER 
EXPRESS OR IMPLIED.
 #ifndef __FORM_BROWSER_EXTENSION2_H__
 #define __FORM_BROWSER_EXTENSION2_H__
 
-#include <Protocol\FormBrowserEx.h>
+#include <Protocol/FormBrowserEx.h>
 
 #define EDKII_FORM_BROWSER_EXTENSION2_PROTOCOL_GUID  \
   { 0xa770c357, 0xb693, 0x4e6d, { 0xa6, 0xcf, 0xd2, 0x1c, 0x72, 0x8e, 0x55, 
0xb }}
-- 
1.7.1

From 1f28fd549411c3773dec71c97c3d18478633eff7 Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Wed, 24 Jul 2013 12:10:40 +0200
Subject: [PATCH 2/5] MdeModulePkg/Universal/SetupBrowserDxe/Setup: 
PasswordCheck() is EFIAPI

according to the PASSWORD_CHECK typedef in
"MdeModulePkg/Include/Protocol/DisplayProtocol.h".

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
 MdeModulePkg/Universal/SetupBrowserDxe/Setup.c |    1 +
 MdeModulePkg/Universal/SetupBrowserDxe/Setup.h |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.c 
b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.c
index 845a33a..1a8815c 100644
--- a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.c
+++ b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.c
@@ -4782,6 +4782,7 @@ IsHiiHandleInBrowserContext (
   @return Status     Status of Password check.
 **/
 EFI_STATUS
+EFIAPI
 PasswordCheck (
   IN FORM_DISPLAY_ENGINE_FORM      *Form,
   IN FORM_DISPLAY_ENGINE_STATEMENT *Statement,
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h 
b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h
index 3d6fd4a..1be2c0d 100644
--- a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h
+++ b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h
@@ -1560,6 +1560,7 @@ CompareHiiValue (
   @return Status     Status of Password check.
 **/
 EFI_STATUS
+EFIAPI
 PasswordCheck (
   IN FORM_DISPLAY_ENGINE_FORM      *Form,
   IN FORM_DISPLAY_ENGINE_STATEMENT *Statement,
-- 
1.7.1

From 250dc26bdf2458e7662caba20948a586777076e8 Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Wed, 24 Jul 2013 12:25:07 +0200
Subject: [PATCH 3/5] FormDisplay.UiAddMenuOption: fix parenthesizing

The "*MenuItemCount++" expression is parsed as follows:

            unary-expression
                /       \
  unary-operator         cast-expression
       |                        |
       *                  unary-expression
                                |
                        postfix-expression
                            /       \
          postfix-expression        ++
                  |
          primary-expression
                  |
             identifier
                  |
             MenuItemCount

That is, as "*(MenuItemCount++)". A gcc warning catches this.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
 .../Universal/DisplayEngineDxe/FormDisplay.c       |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c 
b/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
index 78e56a6..27517c0 100644
--- a/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
+++ b/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
@@ -610,7 +610,7 @@ UiAddMenuOption (
     InsertTailList (&gMenuOption, &MenuOption->Link);
   }
 
-  *MenuItemCount ++;
+  (*MenuItemCount)++;
 }
 
 /**
-- 
1.7.1

From cf11237ec7edd2c0459e72d091149b5e09bd2115 Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Wed, 24 Jul 2013 12:41:15 +0200
Subject: [PATCH 4/5] MdeModulePkg/Universal/SetupBrowserDxe/Presentation: 
QuestionCheck() is EFIAPI

according to the VALIDATE_QUESTION typedef in
"MdeModulePkg/Include/Protocol/DisplayProtocol.h".

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
 .../Universal/SetupBrowserDxe/Presentation.c       |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c 
b/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
index 89ba572..1aac4b5 100644
--- a/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
+++ b/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c
@@ -281,7 +281,9 @@ InConsistentIfCheck (
   @retval TRUE   Input Value is valid.
   @retval FALSE  Input Value is invalid.
 **/
+STATIC
 UINT32
+EFIAPI
 QuestionCheck (
   IN  FORM_DISPLAY_ENGINE_FORM      *Form,
   IN  FORM_DISPLAY_ENGINE_STATEMENT *Statement,
-- 
1.7.1

From 1a6e161d11095f825d15fecde6a56472eeb187f6 Mon Sep 17 00:00:00 2001
From: Laszlo Ersek <ler...@redhat.com>
Date: Wed, 24 Jul 2013 12:43:49 +0200
Subject: [PATCH 5/5] .../DisplayEngineDxe/FormDisplay: paper over difference in 
pointer signedness

"SkipValue" has type INTN in UiDisplayMenu(), but FindTopMenu() expects a
pointer-to-UINTN as 4th parameter. Cast the address of "SkipValue" to
pointer-to-UINTN.

This is almost certainly a wrong fix, but it shuts up a gcc warning.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Laszlo Ersek <ler...@redhat.com>
---
 .../Universal/DisplayEngineDxe/FormDisplay.c       |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c 
b/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
index 27517c0..a12e73c 100644
--- a/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
+++ b/MdeModulePkg/Universal/DisplayEngineDxe/FormDisplay.c
@@ -1499,7 +1499,7 @@ UiDisplayMenu (
     Col = gStatementDimensions.LeftColumn + LEFT_SKIPPED_COLUMNS;
   }
 
-  FindTopMenu(FormData, &TopOfScreen, &NewPos, &SkipValue);
+  FindTopMenu(FormData, &TopOfScreen, &NewPos, (UINTN *) &SkipValue);
 
   gST->ConOut->EnableCursor (gST->ConOut, FALSE);
 
-- 
1.7.1

<<attachment: Screenshot-ovmf.f19.a Virtual Machine.png>>

------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to