> -----Original Message-----
> From: edk2-devel <edk2-devel-boun...@lists.01.org> On Behalf Of
> Vijayenthiran Subramaniam
> Sent: Tuesday, November 20, 2018 4:10 PM
> To: edk2-devel@lists.01.org; siyuan...@intel.com; jiaxin...@intel.com
> Cc: Vijayenthiran Subramaniam <vijayenthiran.subraman...@arm.com>
> Subject: [edk2] [PATCH] NetworkPkg/IScsiDxe: add debug logs for failed
> SetVariable attempts
> 
> Add debug messages for failed attempts to write to a variable.
> 
> Cc: Siyuan Fu <siyuan...@intel.com>
> Cc: Jiaxin Wu <jiaxin...@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.1
> Signed-off-by: Vijayenthiran Subramaniam
> <vijayenthiran.subraman...@arm.com>
> ---
>  NetworkPkg/IScsiDxe/IScsiMisc.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c b/NetworkPkg/IScsiDxe/IScsiMisc.c
> index dd0d32dcda16..46760d79a8f3 100644
> --- a/NetworkPkg/IScsiDxe/IScsiMisc.c
> +++ b/NetworkPkg/IScsiDxe/IScsiMisc.c
> @@ -845,6 +845,8 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigOrder);
>      if (EFI_ERROR (Status)) {
> +      DEBUG ((DEBUG_ERROR, "%a: SetVariable failed with return: %r\n",
> +        __FUNCTION__, Status));
>        return Status;
>      }
> 
> @@ -887,6 +889,8 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigData);
>      if (EFI_ERROR (Status)) {
> +      DEBUG ((DEBUG_ERROR, "%a: SetVariable failed with return: %r\n",
> +        __FUNCTION__, Status));
>        return Status;
>      }
>    }

Since you are printing, same text for both failure , how will you decide which 
SetVariable is failed 
You can choose to have different text or __LINE__ should help 


> --
> 2.17.1
> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.01
> .org%2Fmailman%2Flistinfo%2Fedk2-
> devel&amp;data=02%7C01%7Cudit.kumar%40nxp.com%7C5faa1c1f546046d1f1
> a708d64ed7ff20%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C1%7C6367
> 83086961408415&amp;sdata=RZdmCRaq8x0ps9gu13YAoWf8lsGS9zH2fAdnDLbP
> 3rE%3D&amp;reserved=0
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to