public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts
@ 2018-11-21 15:35 Vijayenthiran Subramaniam
  2018-11-23  6:23 ` Fu, Siyuan
  2018-11-23  6:51 ` Wu, Jiaxin
  0 siblings, 2 replies; 3+ messages in thread
From: Vijayenthiran Subramaniam @ 2018-11-21 15:35 UTC (permalink / raw)
  To: edk2-devel, siyuan.fu, jiaxin.wu; +Cc: Vijayenthiran Subramaniam

Add debug messages for failed attempts to write to a variable.

Cc: Siyuan Fu <siyuan.fu@intel.com>
Cc: Jiaxin Wu <jiaxin.wu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Vijayenthiran Subramaniam <vijayenthiran.subramaniam@arm.com>
---
Made the log messages bit more useful. 

Thanks,
Vijayenthiran

 NetworkPkg/IScsiDxe/IScsiMisc.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c b/NetworkPkg/IScsiDxe/IScsiMisc.c
index dd0d32dcda16..7bed95a8fba3 100644
--- a/NetworkPkg/IScsiDxe/IScsiMisc.c
+++ b/NetworkPkg/IScsiDxe/IScsiMisc.c
@@ -845,6 +845,10 @@ IScsiCreateAttempts (
                     );
     FreePool (AttemptConfigOrder);
     if (EFI_ERROR (Status)) {
+      DEBUG ((DEBUG_ERROR,
+        "%a: Failed to set 'InitialAttemptOrder' with Guid (%g): "
+        "%r\n",
+        __FUNCTION__, &gIScsiConfigGuid, Status));
       return Status;
     }
 
@@ -887,6 +891,10 @@ IScsiCreateAttempts (
                     );
     FreePool (AttemptConfigData);
     if (EFI_ERROR (Status)) {
+        DEBUG ((DEBUG_ERROR,
+          "%a: Failed to set variable (mPrivate->PortString) with Guid (%g): "
+          "%r\n",
+          __FUNCTION__, &gEfiIScsiInitiatorNameProtocolGuid, Status));
       return Status;
     }
   }
-- 
2.17.1



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

* Re: [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts
  2018-11-21 15:35 [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts Vijayenthiran Subramaniam
@ 2018-11-23  6:23 ` Fu, Siyuan
  2018-11-23  6:51 ` Wu, Jiaxin
  1 sibling, 0 replies; 3+ messages in thread
From: Fu, Siyuan @ 2018-11-23  6:23 UTC (permalink / raw)
  To: Vijayenthiran Subramaniam, edk2-devel@lists.01.org, Wu, Jiaxin

Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>

> -----Original Message-----
> From: Vijayenthiran Subramaniam [mailto:vijayenthiran.subramaniam@arm.com]
> Sent: Wednesday, November 21, 2018 11:36 PM
> To: edk2-devel@lists.01.org; Fu, Siyuan <siyuan.fu@intel.com>; Wu, Jiaxin
> <jiaxin.wu@intel.com>
> Cc: Vijayenthiran Subramaniam <vijayenthiran.subramaniam@arm.com>
> Subject: [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed
> SetVariable attempts
> 
> Add debug messages for failed attempts to write to a variable.
> 
> Cc: Siyuan Fu <siyuan.fu@intel.com>
> Cc: Jiaxin Wu <jiaxin.wu@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.1
> Signed-off-by: Vijayenthiran Subramaniam
> <vijayenthiran.subramaniam@arm.com>
> ---
> Made the log messages bit more useful.
> 
> Thanks,
> Vijayenthiran
> 
>  NetworkPkg/IScsiDxe/IScsiMisc.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c
> b/NetworkPkg/IScsiDxe/IScsiMisc.c
> index dd0d32dcda16..7bed95a8fba3 100644
> --- a/NetworkPkg/IScsiDxe/IScsiMisc.c
> +++ b/NetworkPkg/IScsiDxe/IScsiMisc.c
> @@ -845,6 +845,10 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigOrder);
>      if (EFI_ERROR (Status)) {
> +      DEBUG ((DEBUG_ERROR,
> +        "%a: Failed to set 'InitialAttemptOrder' with Guid (%g): "
> +        "%r\n",
> +        __FUNCTION__, &gIScsiConfigGuid, Status));
>        return Status;
>      }
> 
> @@ -887,6 +891,10 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigData);
>      if (EFI_ERROR (Status)) {
> +        DEBUG ((DEBUG_ERROR,
> +          "%a: Failed to set variable (mPrivate->PortString) with Guid
> (%g): "
> +          "%r\n",
> +          __FUNCTION__, &gEfiIScsiInitiatorNameProtocolGuid, Status));
>        return Status;
>      }
>    }
> --
> 2.17.1



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

* Re: [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts
  2018-11-21 15:35 [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts Vijayenthiran Subramaniam
  2018-11-23  6:23 ` Fu, Siyuan
@ 2018-11-23  6:51 ` Wu, Jiaxin
  1 sibling, 0 replies; 3+ messages in thread
From: Wu, Jiaxin @ 2018-11-23  6:51 UTC (permalink / raw)
  To: Vijayenthiran Subramaniam, edk2-devel@lists.01.org, Fu, Siyuan

Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>


> -----Original Message-----
> From: Vijayenthiran Subramaniam
> [mailto:vijayenthiran.subramaniam@arm.com]
> Sent: Wednesday, November 21, 2018 11:36 PM
> To: edk2-devel@lists.01.org; Fu, Siyuan <siyuan.fu@intel.com>; Wu, Jiaxin
> <jiaxin.wu@intel.com>
> Cc: Vijayenthiran Subramaniam <vijayenthiran.subramaniam@arm.com>
> Subject: [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable
> attempts
> 
> Add debug messages for failed attempts to write to a variable.
> 
> Cc: Siyuan Fu <siyuan.fu@intel.com>
> Cc: Jiaxin Wu <jiaxin.wu@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.1
> Signed-off-by: Vijayenthiran Subramaniam
> <vijayenthiran.subramaniam@arm.com>
> ---
> Made the log messages bit more useful.
> 
> Thanks,
> Vijayenthiran
> 
>  NetworkPkg/IScsiDxe/IScsiMisc.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c b/NetworkPkg/IScsiDxe/IScsiMisc.c
> index dd0d32dcda16..7bed95a8fba3 100644
> --- a/NetworkPkg/IScsiDxe/IScsiMisc.c
> +++ b/NetworkPkg/IScsiDxe/IScsiMisc.c
> @@ -845,6 +845,10 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigOrder);
>      if (EFI_ERROR (Status)) {
> +      DEBUG ((DEBUG_ERROR,
> +        "%a: Failed to set 'InitialAttemptOrder' with Guid (%g): "
> +        "%r\n",
> +        __FUNCTION__, &gIScsiConfigGuid, Status));
>        return Status;
>      }
> 
> @@ -887,6 +891,10 @@ IScsiCreateAttempts (
>                      );
>      FreePool (AttemptConfigData);
>      if (EFI_ERROR (Status)) {
> +        DEBUG ((DEBUG_ERROR,
> +          "%a: Failed to set variable (mPrivate->PortString) with Guid (%g): "
> +          "%r\n",
> +          __FUNCTION__, &gEfiIScsiInitiatorNameProtocolGuid, Status));
>        return Status;
>      }
>    }
> --
> 2.17.1



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

end of thread, other threads:[~2018-11-23  6:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-21 15:35 [PATCH v2] NetworkPkg/IScsiDxe: add debug logs for failed SetVariable attempts Vijayenthiran Subramaniam
2018-11-23  6:23 ` Fu, Siyuan
2018-11-23  6:51 ` Wu, Jiaxin

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