public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib
@ 2018-01-16 10:59 Joakim Bech
  2018-01-17  0:36 ` Wu, Jiaxin
  0 siblings, 1 reply; 3+ messages in thread
From: Joakim Bech @ 2018-01-16 10:59 UTC (permalink / raw)
  To: fan.wang
  Cc: edk2-devel, jiaxin.wu, siyuan.fu, Ard Biesheuvel,
	team-security-wg, Leif Lindholm

Hi,

With recent patches being merged in EDK2 we get an assert when booting:
--------------------------------------------------------------------------
...
InstallProtocolInterface: 41D94CD2-35B6-455A-8258-D4E51334AADD 7BA990A0
InstallProtocolInterface: 83F01464-99BD-45E5-B383-AF6305D8E9E6 7BA99B20
ASSERT [Udp4Dxe]
/mnt/sshd/devel/optee_projects/qemu_v8/edk2/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c(1750):
(IpInfo->IpVersion == 4) || (IpInfo->IpVersion == 6)
--------------------------------------------------------------------------


I've bisected it to this commit:
--------------------------------------------------------------------------
$ git bisect bad
2b2087478c861b967394f1ce31531d27ab541b02 is the first bad commit
commit 2b2087478c861b967394f1ce31531d27ab541b02
Author: Wang Fan <fan.wang@intel.com>
Date:   Wed Jan 10 11:09:28 2018 +0800

    MdeModulePkg: Did some code enhancement for DxeIpIoLib

    * In DxeIpIo, there are several places use ASSERT() to check input
      parameters without and descriptions or error handling. This patch
      fixed this issue.
    * Fixed some incorrect descriptions in code commence.
    * Remove unneeded Exit tag in function IpIoOpen and IpIoConfigIp.
    * Add EFIAPI tag for function IpIoRefreshNeighbor.

    Cc: Jiaxin Wu <jiaxin.wu@intel.com>
    Cc: Ye Ting <ting.ye@intel.com>
    Cc: Fu Siyuan <siyuan.fu@intel.com>
    Contributed-under: TianoCore Contribution Agreement 1.0
    Signed-off-by: Wang Fan <fan.wang@intel.com>
    Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
    Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>

:040000 040000 2c60fa2019178c75556b238dbf877927917531f0
080ccf675bf7ee498eccccc89f76bfd14fd61ff9 M      MdeModulePkg
--------------------------------------------------------------------------


This EKD2 build is being used in a QEMU Arm v8 setup running AArch64
(aarch64-linux-gnu-) and for reference here are the build parameters:
--------------------------------------------------------------------------

make -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2/BaseTools
&& \
GCC49_AARCH64_PREFIX=/mnt/sshd/devel/optee_projects/qemu_v8/build/../toolchains/aarch64-legacy/bin/aarch64-linux-gnu-
make -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2 -f
ArmPlatformPkg/Scripts/Makefile EDK2_ARCH=AARCH64
EDK2_DSC=ArmVirtPkg/ArmVirtQemuKernel.dsc EDK2_TOOLCHAIN=GCC49
EDK2_BUILD=DEBUG EDK2_MACROS="-n 6" all
--------------------------------------------------------------------------

Is this something an EDK2 developer could look into or give advice how to
resolve it? Set IP_VERSION_4 or IP_VERSION_6 somewhere?

Regards,
Joakim


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib
  2018-01-16 10:59 Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib Joakim Bech
@ 2018-01-17  0:36 ` Wu, Jiaxin
  2018-01-17  0:43   ` Joakim Bech
  0 siblings, 1 reply; 3+ messages in thread
From: Wu, Jiaxin @ 2018-01-17  0:36 UTC (permalink / raw)
  To: Joakim Bech, Wang, Fan
  Cc: edk2-devel@lists.01.org, Fu, Siyuan, Ard Biesheuvel,
	team-security-wg, Leif Lindholm

Hi Joakim,

It has been fixed in EDK2 trunk. The commit log is shown as below:

SHA-1: 6478baf891524348451d75a37f4e4692b835a45b

* MdeModulePkg/DxeIpIoLib: Fixed the error ASSERT incorrectly used in IpIoAddIp().

* In DxeIpIo, an ASSERT check is incorrectly used in IpIoAddIp(), which result
  debug image hang when this API is called, this patch is to fix this issue.

Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wang Fan <fan.wang@intel.com>
Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>

Thanks,
Jiaxin


From: Joakim Bech [mailto:joakim.bech@linaro.org]
Sent: Tuesday, January 16, 2018 6:59 PM
To: Wang, Fan <fan.wang@intel.com>
Cc: edk2-devel@lists.01.org; Wu, Jiaxin <jiaxin.wu@intel.com>; Fu, Siyuan <siyuan.fu@intel.com>; Ard Biesheuvel <ard.biesheuvel@linaro.org>; team-security-wg <team-security-wg@linaro.org>; Leif Lindholm <leif.lindholm@linaro.org>
Subject: [edk2] Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib

Hi,

With recent patches being merged in EDK2 we get an assert when booting:
--------------------------------------------------------------------------
...
InstallProtocolInterface: 41D94CD2-35B6-455A-8258-D4E51334AADD 7BA990A0
InstallProtocolInterface: 83F01464-99BD-45E5-B383-AF6305D8E9E6 7BA99B20
ASSERT [Udp4Dxe] /mnt/sshd/devel/optee_projects/qemu_v8/edk2/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c(1750): (IpInfo->IpVersion == 4) || (IpInfo->IpVersion == 6)
--------------------------------------------------------------------------


I've bisected it to this commit:
--------------------------------------------------------------------------
$ git bisect bad
2b2087478c861b967394f1ce31531d27ab541b02 is the first bad commit
commit 2b2087478c861b967394f1ce31531d27ab541b02
Author: Wang Fan <fan.wang@intel.com<mailto:fan.wang@intel.com>>
Date:   Wed Jan 10 11:09:28 2018 +0800

    MdeModulePkg: Did some code enhancement for DxeIpIoLib

    * In DxeIpIo, there are several places use ASSERT() to check input
      parameters without and descriptions or error handling. This patch
      fixed this issue.
    * Fixed some incorrect descriptions in code commence.
    * Remove unneeded Exit tag in function IpIoOpen and IpIoConfigIp.
    * Add EFIAPI tag for function IpIoRefreshNeighbor.

    Cc: Jiaxin Wu <jiaxin.wu@intel.com<mailto:jiaxin.wu@intel.com>>
    Cc: Ye Ting <ting.ye@intel.com<mailto:ting.ye@intel.com>>
    Cc: Fu Siyuan <siyuan.fu@intel.com<mailto:siyuan.fu@intel.com>>
    Contributed-under: TianoCore Contribution Agreement 1.0
    Signed-off-by: Wang Fan <fan.wang@intel.com<mailto:fan.wang@intel.com>>
    Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com<mailto:jiaxin.wu@intel.com>>
    Reviewed-by: Fu Siyuan <siyuan.fu@intel.com<mailto:siyuan.fu@intel.com>>

:040000 040000 2c60fa2019178c75556b238dbf877927917531f0 080ccf675bf7ee498eccccc89f76bfd14fd61ff9 M      MdeModulePkg
--------------------------------------------------------------------------


This EKD2 build is being used in a QEMU Arm v8 setup running AArch64 (aarch64-linux-gnu-) and for reference here are the build parameters:
--------------------------------------------------------------------------
make -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2/BaseTools && \  GCC49_AARCH64_PREFIX=/mnt/sshd/devel/optee_projects/qemu_v8/build/../toolchains/aarch64-legacy/bin/aarch64-linux-gnu- make -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2 -f ArmPlatformPkg/Scripts/Makefile EDK2_ARCH=AARCH64 EDK2_DSC=ArmVirtPkg/ArmVirtQemuKernel.dsc EDK2_TOOLCHAIN=GCC49 EDK2_BUILD=DEBUG EDK2_MACROS="-n 6" all
--------------------------------------------------------------------------

Is this something an EDK2 developer could look into or give advice how to resolve it? Set IP_VERSION_4 or IP_VERSION_6 somewhere?

Regards,
Joakim

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib
  2018-01-17  0:36 ` Wu, Jiaxin
@ 2018-01-17  0:43   ` Joakim Bech
  0 siblings, 0 replies; 3+ messages in thread
From: Joakim Bech @ 2018-01-17  0:43 UTC (permalink / raw)
  To: Wu, Jiaxin
  Cc: Wang, Fan, edk2-devel@lists.01.org, Fu, Siyuan, Ard Biesheuvel,
	team-security-wg, Leif Lindholm

Hi Jiaxin,

I just gave it a try and I can confirm that your patch fixed the issue.

Thanks for the quick turnaround time!

Regards,
Joakim

On 17 January 2018 at 01:36, Wu, Jiaxin <jiaxin.wu@intel.com> wrote:

> Hi Joakim,
>
>
>
> It has been fixed in EDK2 trunk. The commit log is shown as below:
>
>
>
> SHA-1: 6478baf891524348451d75a37f4e4692b835a45b
>
>
>
> ** MdeModulePkg/DxeIpIoLib: Fixed the error ASSERT incorrectly used in
> IpIoAddIp().*
>
>
>
> * In DxeIpIo, an ASSERT check is incorrectly used in IpIoAddIp(), which
> result
>
>   debug image hang when this API is called, this patch is to fix this
> issue.
>
>
>
> Cc: Jiaxin Wu <jiaxin.wu@intel.com>
>
> Cc: Fu Siyuan <siyuan.fu@intel.com>
>
> Contributed-under: TianoCore Contribution Agreement 1.0
>
> Signed-off-by: Wang Fan <fan.wang@intel.com>
>
> Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
>
>
>
> Thanks,
>
> Jiaxin
>
>
>
>
>
> *From:* Joakim Bech [mailto:joakim.bech@linaro.org]
> *Sent:* Tuesday, January 16, 2018 6:59 PM
> *To:* Wang, Fan <fan.wang@intel.com>
> *Cc:* edk2-devel@lists.01.org; Wu, Jiaxin <jiaxin.wu@intel.com>; Fu,
> Siyuan <siyuan.fu@intel.com>; Ard Biesheuvel <ard.biesheuvel@linaro.org>;
> team-security-wg <team-security-wg@linaro.org>; Leif Lindholm <
> leif.lindholm@linaro.org>
> *Subject:* [edk2] Regression/Assert : MdeModulePkg: Did some code
> enhancement for DxeIpIoLib
>
>
>
> Hi,
>
>
>
> With recent patches being merged in EDK2 we get an assert when booting:
>
> --------------------------------------------------------------------------
>
> ...
>
> InstallProtocolInterface: 41D94CD2-35B6-455A-8258-D4E51334AADD 7BA990A0
>
> InstallProtocolInterface: 83F01464-99BD-45E5-B383-AF6305D8E9E6 7BA99B20
>
> ASSERT [Udp4Dxe] /mnt/sshd/devel/optee_projects/qemu_v8/edk2/
> MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c(1750): (IpInfo->IpVersion ==
> 4) || (IpInfo->IpVersion == 6)
>
> --------------------------------------------------------------------------
>
>
>
>
>
> I've bisected it to this commit:
>
> --------------------------------------------------------------------------
>
> $ git bisect bad
>
> 2b2087478c861b967394f1ce31531d27ab541b02 is the first bad commit
>
> commit 2b2087478c861b967394f1ce31531d27ab541b02
>
> Author: Wang Fan <fan.wang@intel.com>
>
> Date:   Wed Jan 10 11:09:28 2018 +0800
>
>
>
>     MdeModulePkg: Did some code enhancement for DxeIpIoLib
>
>
>
>     * In DxeIpIo, there are several places use ASSERT() to check input
>
>       parameters without and descriptions or error handling. This patch
>
>       fixed this issue.
>
>     * Fixed some incorrect descriptions in code commence.
>
>     * Remove unneeded Exit tag in function IpIoOpen and IpIoConfigIp.
>
>     * Add EFIAPI tag for function IpIoRefreshNeighbor.
>
>
>
>     Cc: Jiaxin Wu <jiaxin.wu@intel.com>
>
>     Cc: Ye Ting <ting.ye@intel.com>
>
>     Cc: Fu Siyuan <siyuan.fu@intel.com>
>
>     Contributed-under: TianoCore Contribution Agreement 1.0
>
>     Signed-off-by: Wang Fan <fan.wang@intel.com>
>
>     Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
>
>     Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
>
>
>
> :040000 040000 2c60fa2019178c75556b238dbf877927917531f0
> 080ccf675bf7ee498eccccc89f76bfd14fd61ff9 M      MdeModulePkg
>
> --------------------------------------------------------------------------
>
>
>
>
>
> This EKD2 build is being used in a QEMU Arm v8 setup running AArch64
> (aarch64-linux-gnu-) and for reference here are the build parameters:
>
> --------------------------------------------------------------------------
>
>
> make -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2/BaseTools
> && \  GCC49_AARCH64_PREFIX=/mnt/sshd/devel/optee_projects/
> qemu_v8/build/../toolchains/aarch64-legacy/bin/aarch64-linux-gnu- make
> -j1 -C /mnt/sshd/devel/optee_projects/qemu_v8/build/../edk2 -f
> ArmPlatformPkg/Scripts/Makefile EDK2_ARCH=AARCH64 EDK2_DSC=ArmVirtPkg/ArmVirtQemuKernel.dsc
> EDK2_TOOLCHAIN=GCC49 EDK2_BUILD=DEBUG EDK2_MACROS="-n 6" all
>
> --------------------------------------------------------------------------
>
>
>
> Is this something an EDK2 developer could look into or give advice how to
> resolve it? Set IP_VERSION_4 or IP_VERSION_6 somewhere?
>
>
> Regards,
>
> Joakim
>


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-01-17  0:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-16 10:59 Regression/Assert : MdeModulePkg: Did some code enhancement for DxeIpIoLib Joakim Bech
2018-01-17  0:36 ` Wu, Jiaxin
2018-01-17  0:43   ` Joakim Bech

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox