From: "Maciej Rabeda" <maciej.rabeda@linux.intel.com>
To: devel@edk2.groups.io, sivaramann@amiindia.co.in
Cc: "Wu, Jiaxin" <jiaxin.wu@intel.com>
Subject: Re: [edk2-devel] reg: [edk2] [PATCH v1] NetworkPkg/SNPDxe: Validate the Memory BAR as per UEFI Spec
Date: Tue, 14 Jan 2020 13:37:11 +0100 [thread overview]
Message-ID: <3d077ab7-dd2b-af78-55a1-25fc2a3d15b0@linux.intel.com> (raw)
In-Reply-To: <B4DE137BDB63634BAC03BD9DE765F197029AE4D966@VENUS1.in.megatrends.com>
[-- Attachment #1: Type: text/plain, Size: 2502 bytes --]
Hello Siva,
Which tools did you use to generate this patch? I cannot apply it via
'git am' command.
Did you follow the edk2 git guide (using git format-patch && git
send-email commands)?
https://github.com/tianocore/tianocore.github.io/wiki/Laszlo's-unkempt-git-guide-for-edk2-contributors-and-maintainers
Thanks,
Maciej
On 04-Dec-19 11:06, Sivaraman Nainar wrote:
>
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2335
> <https://bugzilla.tianocore.org/show_bug.cgi?id=2335>
>
> This patch is to check the PCI Memory Base Address Register is valid
> or not.
>
> *** a\NetworkPkg\SnpDxe\Snp.c 2019-11-11 16:53:40.773300500 +0530
>
> --- b\NetworkPkg\SnpDxe\Snp.c 2019-11-03 18:46:02.000000000 +0530
>
> *************** SimpleNetworkDriverStart (
>
> *** 266,272 ****
>
> UINT8 BarIndex;
>
> PXE_STATFLAGS InitStatFlags;
>
> EFI_PCI_IO_PROTOCOL *PciIo;
>
> ! EFI_ACPI_QWORD_ADDRESS_SPACE_DESCRIPTOR *BarDesc = NULL;
>
> BOOLEAN FoundIoBar;
>
> BOOLEAN FoundMemoryBar;
>
> --- 266,272 ----
>
> UINT8 BarIndex;
>
> PXE_STATFLAGS InitStatFlags;
>
> EFI_PCI_IO_PROTOCOL *PciIo;
>
> ! EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *BarDesc;
>
> BOOLEAN FoundIoBar;
>
> BOOLEAN FoundMemoryBar;
>
> *************** SimpleNetworkDriverStart (
>
> *** 481,494 ****
>
> } else if (EFI_ERROR (Status)) {
>
> goto Error_DeleteSNP;
>
> }
>
> ! //PXE boot fails with cards having non-continuous BAR.
>
> ! // From UEFI Spec, GetBarAttributes can have only
> descriptors of type ACPI_QWORD_ADDRESS_SPACE_DESCRIPTOR
>
> ! // and ACPI_END_TAG_DESCRIPTOR.
>
> ! if( BarDesc->Header.Header.Byte !=
> ACPI_QWORD_ADDRESS_SPACE_DESCRIPTOR ) {
>
> ! FreePool (BarDesc);
>
> ! continue;
>
> ! }
>
> !
>
> if ((!FoundMemoryBar) && (BarDesc->ResType ==
> ACPI_ADDRESS_SPACE_TYPE_MEM)) {
>
> Snp->MemoryBarIndex = BarIndex;
>
> FoundMemoryBar = TRUE;
>
> --- 481,487 ----
>
> } else if (EFI_ERROR (Status)) {
>
> goto Error_DeleteSNP;
>
> }
>
> !
>
> if ((!FoundMemoryBar) && (BarDesc->ResType ==
> ACPI_ADDRESS_SPACE_TYPE_MEM)) {
>
> Snp->MemoryBarIndex = BarIndex;
>
> FoundMemoryBar = TRUE;
>
>
[-- Attachment #2: Type: text/html, Size: 7420 bytes --]
prev parent reply other threads:[~2020-01-14 12:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-04 10:06 reg: [edk2] [PATCH v1] NetworkPkg/SNPDxe: Validate the Memory BAR as per UEFI Spec Sivaraman Nainar
2020-01-14 12:37 ` Maciej Rabeda [this message]
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=3d077ab7-dd2b-af78-55a1-25fc2a3d15b0@linux.intel.com \
--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