public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Gary Lin" <glin@suse.com>
To: "devel@edk2.groups.io" <devel@edk2.groups.io>,
	"michael.d.kinney@intel.com" <michael.d.kinney@intel.com>
Cc: Yi Qian <yi.qian@intel.com>, Zailiang Sun <zailiang.sun@intel.com>
Subject: Re: [edk2-devel] [edk2-platforms Patch 00/14] Vlv2TbltDevicePkg: Remove Intel Framework dependencies
Date: Tue, 2 Jul 2019 09:48:24 +0000	[thread overview]
Message-ID: <20190702094812.GA32340@GaryWorkstation> (raw)
In-Reply-To: <E92EE9817A31E24EB0585FDF735412F5B9D5B45F@ORSMSX113.amr.corp.intel.com>

On Mon, Jul 01, 2019 at 11:07:11PM +0000,  Michael D Kinney  wrote:
> Hi Gary,
> 
> I recommend you rebase on top of this series.
> 
> I have verified Linux boots and I have been working
> on the GCC and Linux build scripts as well. 
> 
> Please let me know if you see any issues with this
> series applied and I can help get them fixed.
> 
Hi Mike,

I'm rebasing my patches and they are available in my branch:

https://github.com/lcp/edk2-platforms/commits/vlv2-fixes-wip

It's based on edk2(dcce9cbd48e07fcd11f7ef34cad48faf7bb61e6e)
and edk2-non-osi(de0a6bc19c4ee0468f04e4d37035cdc59558137f).

There are 3 problems I currently encountered, and maybe you can give me
some suggestions.

1. Missing DSDT

When compiling DSDT, iasl failed with this error:

DSDT.iiii   6077:             Or(ShiftLeft(Derefof(Index(CDCT, \_SB.PCI0.GFX0.MCHK.DCFE)), 21),PARM, PARM)                                           
Error    6163 -                                                                      ^ Object is created temporarily in another method and cannot be accessed (\_SB.PCI0.GFX0. MCHK.DCFE)

The code is from Silicon/Intel/Vlv2DeviceRefCodePkg/AcpiTablesPCAT/IgdOGBDA.ASL

I have to comment out the line or iasl won't generate the aml file and
the OS would fail to get DSDT.

My acpica version is 20190509, and I vaguely remember that the older
acpica seems to be more tolerant to this error.

2. Crash at SMBIOS driver

When booting the system, I got the following error:

Loading driver at 0x00078DBA000 EntryPoint=0x00078DBEC3C MiscSubclass.efi
InstallProtocolInterface: BC62157E-3E33-4FEC-9920-2D3B36D750DF 78FE8D18
ProtectUefiImageCommon - 0x78FE8040
  - 0x0000000078DBA000 - 0x0000000000007B80
PlatformInfoHob->BoardId [0xB0]
GetBiosVersionDateTime :MNW2MAX1.X64.0084.D01 01/01/2019 00:00 
SmbiosAdd: Smbios type 0 with size 0x48 is added to 32-bit table
SmbiosAdd: Smbios type 0 with size 0x48 is added to 64-bit table
SmbiosCreateTable: Initialize 32-bit entry point structure
SmbiosCreateTable() re-allocate SMBIOS 32-bit table
SmbiosCreateTable: Initialize 64-bit entry point structure
SmbiosCreate64BitTable() re-allocate SMBIOS 64-bit table
Create Smbios Manu callback.
!!!! X64 Exception Type - 06(#UD - Invalid Opcode)  CPU Apic ID - 00000000 !!!!
RIP  - 0000000078DBEC26, CS  - 0000000000000038, RFLAGS - 0000000000010206
RAX  - 0000000000000000, RCX - 000000007984A5A0, RDX - 000000007A46E5FF
RBX  - 000000007A46E920, RSP - 000000007A46E8B0, RBP - 0000000078DC0EC0
RSI  - 0000000000000012, RDI - 0000000000000003
R8   - 800000000000000E, R9  - 000000007A46E920, R10 - 0000000078FE8398
R11  - 0000000000000001, R12 - 0000000078FE8798, R13 - 0000000078FE8898
R14  - 0000000078FE8818, R15 - 000000007A46EC60
DS   - 0000000000000030, ES  - 0000000000000030, FS  - 0000000000000030
GS   - 0000000000000030, SS  - 0000000000000030
CR0  - 0000000080010013, CR2 - 0000000000000000, CR3 - 000000007A201000
CR4  - 0000000000000628, CR8 - 0000000000000000
DR0  - 0000000000000000, DR1 - 0000000000000000, DR2 - 0000000000000000
DR3  - 0000000000000000, DR6 - 00000000FFFF0FF8, DR7 - 0000000000000400
GDTR - 0000000079FFDA98 0000000000000047, LDTR - 0000000000000000
IDTR - 0000000079862018 0000000000000FFF,   TR - 0000000000000000
FXSAVE_STATE - 000000007A46E510
!!!! Find image based on IP(0x78DBEC26) /home/gary/git/edk2-workspace/Build/Vlv2TbltDevicePkg/DEBUG_GCC5/X64/Vlv2TbltDevicePkg/SmBiosMiscDxe/SmBiosMiscDxe/DEBUG/MiscSubclass.
dll (ImageBase=0000000078DBA000, EntryPoint=0000000078DBEC3C) !!!!

I disaseembled MiscSubclass.debug and found that the address is a "ud2"
instruction at
SmBiosMiscDxe/MiscBaseBoardManufacturerFunction.c:MiscBaseBoardManufacturer()

After adding a few more debug messages, the system crashed at another
function:
SmBiosMiscDxe/MiscSystemManufacturerFunction.c:AddSmbiosManuCallback()

If I added debug messages to both functions, the system booted
successfully. I currently didn't have any clue on this.

3. The firmware always booted into EFI shell.

I guess something went wrong with BDS. I haven't looked into this issue
yet.

Thanks,

Gary Lin

> Thanks,
> 
> Mike
> 
> > -----Original Message-----
> > From: Gary Lin [mailto:GLin@suse.com]
> > Sent: Sunday, June 30, 2019 9:04 PM
> > To: devel@edk2.groups.io; Kinney, Michael D
> > <michael.d.kinney@intel.com>
> > Cc: Qian, Yi <yi.qian@intel.com>; Sun, Zailiang
> > <zailiang.sun@intel.com>
> > Subject: Re: [edk2-devel] [edk2-platforms Patch 00/14]
> > Vlv2TbltDevicePkg: Remove Intel Framework dependencies
> > 
> > On Sun, Jun 30, 2019 at 07:55:39PM -0700,  Michael D
> > Kinney  wrote:
> > > The following changes remove all dependencies on the
> > IntelFrameworkPkg
> > > and IntelFrameworkModulePkg from the Vlv2TbltDevicePkg
> > platform
> > > builds.  These changes do depend on updates binaries
> > on the edk2-non-osi repository.
> > >
> > Hi Michael,
> > 
> > I am amending the bash scripts for gcc. The firmware I
> > built is using the binaries from Development190216 and
> > could boot into Linux successfully with some workarounds
> > for Wpce791, Bds, and InteFspWrapper. The patches you
> > posted eliminate those parts I have to work around.
> > 
> > Just want to know if you need any assistance for the gcc
> > build? I could rebase my work upon your patches and send
> > them later.
> > 
> > Thanks,
> > 
> > Gary Lin
> > 
> 
> 
> 

  reply	other threads:[~2019-07-02  9:48 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-01  2:55 [edk2-platforms Patch 00/14] Vlv2TbltDevicePkg: Remove Intel Framework dependencies Michael D Kinney
2019-07-01  2:55 ` [edk2-platforms Patch 01/14] Vlv2DeviceRefCodePkg: Add gEfiSmmIchnDispatchProtocolGuid Michael D Kinney
2019-07-01  4:06   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 02/14] Vlv2TbltDevicePkg: Reduce Intel Framework dependencies Michael D Kinney
2019-07-01  4:06   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 03/14] Vlv2TbltDevicePkg: Remove unused modules/libraries Michael D Kinney
2019-07-01  4:07   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 04/14] Vlv2TbltDevicePkg: Switch from ISA to SIO modules Michael D Kinney
2019-07-01  4:07   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 05/14] Vlv2TbltDevicePkg: Switch to CPU I/O 2 Protocol Michael D Kinney
2019-07-01  4:07   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 06/14] Vlv2TbltDevicePkg: Remove use of PS/2 Policy Protocol Michael D Kinney
2019-07-01  4:07   ` [edk2-devel] " Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 07/14] Vlv2TbltDevicePkg: Remove use of BIOS ID tools Michael D Kinney
2019-07-01  4:07   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 08/14] Vlv2TbltDevicePkg: Remove use of Data Hub Protocol Michael D Kinney
2019-07-01  4:08   ` [edk2-devel] " Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 09/14] Vlv2TbltDevicePkg: Use PI Spec SMBUS2 PPI Michael D Kinney
2019-07-01  4:08   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 10/14] Vlv2TbltDevicePkg: Switch to MdeModulePkg BdsDxe Michael D Kinney
2019-07-01  4:08   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 11/14] Vlv2TbltDevicePkg: Update boot mode/state behaviors Michael D Kinney
2019-07-01  4:08   ` [edk2-devel] " Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 12/14] Vlv2TbltDevicePkg/PlatformSmm: Switch to PI SMM Protocols Michael D Kinney
2019-07-01  4:08   ` [edk2-devel] " Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 13/14] Vlv2TbltDevicePkg: Change to PI Spec ACPI Table Protocol Michael D Kinney
2019-07-01  4:08   ` Sun, Zailiang
2019-07-01  2:55 ` [edk2-platforms Patch 14/14] Vlv2TbltDevicePkg/PlatformInitPei: Update MemoryTypeInformation Michael D Kinney
2019-07-01  4:08   ` Sun, Zailiang
2019-07-01  4:04 ` [edk2-devel] [edk2-platforms Patch 00/14] Vlv2TbltDevicePkg: Remove Intel Framework dependencies Gary Lin
2019-07-01 23:07   ` Michael D Kinney
2019-07-02  9:48     ` Gary Lin [this message]
2019-07-02 16:49       ` Michael D Kinney
2019-07-02 21:11         ` Michael D Kinney
2019-07-03  3:57           ` Gary Lin
2019-07-09  3:52             ` Michael D Kinney
2019-07-09  6:04               ` Gary Lin
2019-07-10  3:38                 ` Michael D Kinney
2019-07-10  4:14                   ` Gary Lin
2019-07-10  5:01                     ` Michael D Kinney
2019-07-10  7:10                       ` Gary Lin
2019-07-10 19:27                         ` Michael D Kinney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190702094812.GA32340@GaryWorkstation \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox