public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* SNP transmit print
@ 2017-09-21 10:06 Meenakshi Aggarwal
  2017-09-21 11:50 ` Udit Kumar
  0 siblings, 1 reply; 7+ messages in thread
From: Meenakshi Aggarwal @ 2017-09-21 10:06 UTC (permalink / raw)
  To: edk2-devel@lists.01.org

Hi,


While performing tftp using PCI interface, below message is coming continuously:

Snp->undi.transmit()  8000h:4h

Snp->undi.transmit()  8000h:4h                                                                                    [======================================> ]   34812 Kb
Snp->undi.transmit()  8000h:4h

Snp->undi.transmit()  8000h:4h

Snp->undi.transmit()  8000h:4h

Snp->undi.transmit()  8000h:4h


It is coming from file "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"

  DEBUG (
    (EFI_D_ERROR,
    "\nSnp->undi.transmit()  %xh:%xh\n",
    Snp->Cdb.StatFlags,
    Snp->Cdb.StatCode)
    );


I want to know if it is really an error message because tftp and ping are working perfectly, but this error message is coming.


Thanks,
Meenakshi





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

* Re: SNP transmit print
  2017-09-21 10:06 SNP transmit print Meenakshi Aggarwal
@ 2017-09-21 11:50 ` Udit Kumar
  2017-09-22 10:25   ` Meenakshi Aggarwal
  0 siblings, 1 reply; 7+ messages in thread
From: Udit Kumar @ 2017-09-21 11:50 UTC (permalink / raw)
  To: Meenakshi Aggarwal, edk2-devel@lists.01.org

I think these error prints should be check against Status 

Regards
Udit

> -----Original Message-----
> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
> Meenakshi Aggarwal
> Sent: Thursday, September 21, 2017 3:36 PM
> To: edk2-devel@lists.01.org
> Subject: [edk2] SNP transmit print
> 
> Hi,
> 
> 
> While performing tftp using PCI interface, below message is coming
> continuously:
> 
> Snp->undi.transmit()  8000h:4h
> 
> Snp->undi.transmit()  8000h:4h
> [======================================> ]   34812 Kb
> Snp->undi.transmit()  8000h:4h
> 
> Snp->undi.transmit()  8000h:4h
> 
> Snp->undi.transmit()  8000h:4h
> 
> Snp->undi.transmit()  8000h:4h
> 
> 
> It is coming from file "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> 
>   DEBUG (
>     (EFI_D_ERROR,
>     "\nSnp->undi.transmit()  %xh:%xh\n",
>     Snp->Cdb.StatFlags,
>     Snp->Cdb.StatCode)
>     );
> 
> 
> I want to know if it is really an error message because tftp and ping are working
> perfectly, but this error message is coming.
> 
> 
> Thanks,
> Meenakshi
> 
> 
> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel


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

* Re: SNP transmit print
  2017-09-21 11:50 ` Udit Kumar
@ 2017-09-22 10:25   ` Meenakshi Aggarwal
  2017-09-22 11:03     ` Udit Kumar
  0 siblings, 1 reply; 7+ messages in thread
From: Meenakshi Aggarwal @ 2017-09-22 10:25 UTC (permalink / raw)
  To: Udit Kumar, edk2-devel@lists.01.org
  Cc: feng.tian@intel.com, star.zeng@intel.com

Hi Udit,

Yes, I think we should print this message is Status is EFI_DEVICE_ERROR because in case of EFI_NOT_READY, we are retrying:

  //
  // Transmit the packet through SNP.
  //
  Status = Snp->Transmit (
                  Snp,
                  HeaderSize,
                  Length,
                  Packet,
                  TxData->SourceAddress,
                  TxData->DestinationAddress,
                  &ProtocolType
                  );
  if (Status == EFI_NOT_READY) {
    Status = MnpRecycleTxBuf (MnpDeviceData);
    if (EFI_ERROR (Status)) {
      Token->Status = EFI_DEVICE_ERROR;
      goto SIGNAL_TOKEN;
    }

    DEBUG ((EFI_D_ERROR, "Snp->Transmit  retry\n"));
    Status = Snp->Transmit (
                    Snp,
                    HeaderSize,
                    Length,
                    Packet,
                    TxData->SourceAddress,
                    TxData->DestinationAddress,
                    &ProtocolType
                    );
  }

(MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c)


Please suggest if we can remove this print in case of BUSY status.

Thanks,
Meenakshi

> -----Original Message-----
> From: Udit Kumar
> Sent: Thursday, September 21, 2017 5:21 PM
> To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-
> devel@lists.01.org
> Subject: RE: SNP transmit print
> 
> I think these error prints should be check against Status
> 
> Regards
> Udit
> 
> > -----Original Message-----
> > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
> > Meenakshi Aggarwal
> > Sent: Thursday, September 21, 2017 3:36 PM
> > To: edk2-devel@lists.01.org
> > Subject: [edk2] SNP transmit print
> >
> > Hi,
> >
> >
> > While performing tftp using PCI interface, below message is coming
> > continuously:
> >
> > Snp->undi.transmit()  8000h:4h
> >
> > Snp->undi.transmit()  8000h:4h
> > [======================================> ]   34812 Kb
> > Snp->undi.transmit()  8000h:4h
> >
> > Snp->undi.transmit()  8000h:4h
> >
> > Snp->undi.transmit()  8000h:4h
> >
> > Snp->undi.transmit()  8000h:4h
> >
> >
> > It is coming from file
> "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> >
> >   DEBUG (
> >     (EFI_D_ERROR,
> >     "\nSnp->undi.transmit()  %xh:%xh\n",
> >     Snp->Cdb.StatFlags,
> >     Snp->Cdb.StatCode)
> >     );
> >
> >
> > I want to know if it is really an error message because tftp and ping
> > are working perfectly, but this error message is coming.
> >
> >
> > Thanks,
> > Meenakshi
> >
> >
> >
> > _______________________________________________
> > edk2-devel mailing list
> > edk2-devel@lists.01.org
> > https://lists.01.org/mailman/listinfo/edk2-devel


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

* Re: SNP transmit print
  2017-09-22 10:25   ` Meenakshi Aggarwal
@ 2017-09-22 11:03     ` Udit Kumar
  2017-09-22 13:27       ` Zeng, Star
  2017-09-25  0:58       ` Fu, Siyuan
  0 siblings, 2 replies; 7+ messages in thread
From: Udit Kumar @ 2017-09-22 11:03 UTC (permalink / raw)
  To: Meenakshi Aggarwal, edk2-devel@lists.01.org
  Cc: feng.tian@intel.com, star.zeng@intel.com

Thanks Meenakshi for digging a bit more 

If we have use like below 
Library/DxeNetLib/DxeNetLib.c
Status = Snp->Transmit (Snp, 0, Length, Packet, NULL, NULL, NULL);
    if ((Status != EFI_SUCCESS) && (Status != EFI_NOT_READY)) {
      Status = EFI_DEVICE_ERROR;
      break;
    }
Then, we can simple put print when Status is EFI_DEVICE_ERROR;

But with below We are retrying once ☹ ,  What I think if first time if you got error 
EFI_NOT_READY, then after MnpRecycleTxBuf we likely not to get this error. 
I am not 100% sure here. 

What I think, in MdeModulePkg/Universal/Network/SnpDxe/Transmit.c 
Have print only for EFI_NOT_READY. 
And in MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c, print error as well 
for second case. 
Hope this helps 

Thanks
Udit

> -----Original Message-----
> From: Meenakshi Aggarwal
> Sent: Friday, September 22, 2017 3:56 PM
> To: Udit Kumar <udit.kumar@nxp.com>; edk2-devel@lists.01.org
> Cc: feng.tian@intel.com; star.zeng@intel.com
> Subject: RE: SNP transmit print
> 
> Hi Udit,
> 
> Yes, I think we should print this message is Status is EFI_DEVICE_ERROR because
> in case of EFI_NOT_READY, we are retrying:
> 
>   //
>   // Transmit the packet through SNP.
>   //
>   Status = Snp->Transmit (
>                   Snp,
>                   HeaderSize,
>                   Length,
>                   Packet,
>                   TxData->SourceAddress,
>                   TxData->DestinationAddress,
>                   &ProtocolType
>                   );
>   if (Status == EFI_NOT_READY) {
>     Status = MnpRecycleTxBuf (MnpDeviceData);
>     if (EFI_ERROR (Status)) {
>       Token->Status = EFI_DEVICE_ERROR;
>       goto SIGNAL_TOKEN;
>     }
> 
>     DEBUG ((EFI_D_ERROR, "Snp->Transmit  retry\n"));
>     Status = Snp->Transmit (
>                     Snp,
>                     HeaderSize,
>                     Length,
>                     Packet,
>                     TxData->SourceAddress,
>                     TxData->DestinationAddress,
>                     &ProtocolType
>                     );
>   }
> 
> (MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c)
> 
> 
> Please suggest if we can remove this print in case of BUSY status.
> 
> Thanks,
> Meenakshi
> 
> > -----Original Message-----
> > From: Udit Kumar
> > Sent: Thursday, September 21, 2017 5:21 PM
> > To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-
> > devel@lists.01.org
> > Subject: RE: SNP transmit print
> >
> > I think these error prints should be check against Status
> >
> > Regards
> > Udit
> >
> > > -----Original Message-----
> > > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf
> > > Of Meenakshi Aggarwal
> > > Sent: Thursday, September 21, 2017 3:36 PM
> > > To: edk2-devel@lists.01.org
> > > Subject: [edk2] SNP transmit print
> > >
> > > Hi,
> > >
> > >
> > > While performing tftp using PCI interface, below message is coming
> > > continuously:
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > > [======================================> ]   34812 Kb
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > >
> > > It is coming from file
> > "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> > >
> > >   DEBUG (
> > >     (EFI_D_ERROR,
> > >     "\nSnp->undi.transmit()  %xh:%xh\n",
> > >     Snp->Cdb.StatFlags,
> > >     Snp->Cdb.StatCode)
> > >     );
> > >
> > >
> > > I want to know if it is really an error message because tftp and
> > > ping are working perfectly, but this error message is coming.
> > >
> > >
> > > Thanks,
> > > Meenakshi
> > >
> > >
> > >
> > > _______________________________________________
> > > edk2-devel mailing list
> > > edk2-devel@lists.01.org
> > > https://lists.01.org/mailman/listinfo/edk2-devel

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

* Re: SNP transmit print
  2017-09-22 11:03     ` Udit Kumar
@ 2017-09-22 13:27       ` Zeng, Star
  2017-09-25  0:58       ` Fu, Siyuan
  1 sibling, 0 replies; 7+ messages in thread
From: Zeng, Star @ 2017-09-22 13:27 UTC (permalink / raw)
  To: Udit Kumar, Meenakshi Aggarwal, edk2-devel@lists.01.org
  Cc: Ye, Ting, Fu, Siyuan, Wu, Jiaxin, Zeng, Star

Cc Ting, Siyuan and Jiaxin.

Thanks,
Star
-----Original Message-----
From: Udit Kumar [mailto:udit.kumar@nxp.com] 
Sent: Friday, September 22, 2017 7:04 PM
To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-devel@lists.01.org
Cc: Tian, Feng <feng.tian@intel.com>; Zeng, Star <star.zeng@intel.com>
Subject: RE: SNP transmit print

Thanks Meenakshi for digging a bit more 

If we have use like below
Library/DxeNetLib/DxeNetLib.c
Status = Snp->Transmit (Snp, 0, Length, Packet, NULL, NULL, NULL);
    if ((Status != EFI_SUCCESS) && (Status != EFI_NOT_READY)) {
      Status = EFI_DEVICE_ERROR;
      break;
    }
Then, we can simple put print when Status is EFI_DEVICE_ERROR;

But with below We are retrying once ☹ ,  What I think if first time if you got error EFI_NOT_READY, then after MnpRecycleTxBuf we likely not to get this error. 
I am not 100% sure here. 

What I think, in MdeModulePkg/Universal/Network/SnpDxe/Transmit.c
Have print only for EFI_NOT_READY. 
And in MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c, print error as well for second case. 
Hope this helps 

Thanks
Udit

> -----Original Message-----
> From: Meenakshi Aggarwal
> Sent: Friday, September 22, 2017 3:56 PM
> To: Udit Kumar <udit.kumar@nxp.com>; edk2-devel@lists.01.org
> Cc: feng.tian@intel.com; star.zeng@intel.com
> Subject: RE: SNP transmit print
> 
> Hi Udit,
> 
> Yes, I think we should print this message is Status is 
> EFI_DEVICE_ERROR because in case of EFI_NOT_READY, we are retrying:
> 
>   //
>   // Transmit the packet through SNP.
>   //
>   Status = Snp->Transmit (
>                   Snp,
>                   HeaderSize,
>                   Length,
>                   Packet,
>                   TxData->SourceAddress,
>                   TxData->DestinationAddress,
>                   &ProtocolType
>                   );
>   if (Status == EFI_NOT_READY) {
>     Status = MnpRecycleTxBuf (MnpDeviceData);
>     if (EFI_ERROR (Status)) {
>       Token->Status = EFI_DEVICE_ERROR;
>       goto SIGNAL_TOKEN;
>     }
> 
>     DEBUG ((EFI_D_ERROR, "Snp->Transmit  retry\n"));
>     Status = Snp->Transmit (
>                     Snp,
>                     HeaderSize,
>                     Length,
>                     Packet,
>                     TxData->SourceAddress,
>                     TxData->DestinationAddress,
>                     &ProtocolType
>                     );
>   }
> 
> (MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c)
> 
> 
> Please suggest if we can remove this print in case of BUSY status.
> 
> Thanks,
> Meenakshi
> 
> > -----Original Message-----
> > From: Udit Kumar
> > Sent: Thursday, September 21, 2017 5:21 PM
> > To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2- 
> > devel@lists.01.org
> > Subject: RE: SNP transmit print
> >
> > I think these error prints should be check against Status
> >
> > Regards
> > Udit
> >
> > > -----Original Message-----
> > > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On 
> > > Behalf Of Meenakshi Aggarwal
> > > Sent: Thursday, September 21, 2017 3:36 PM
> > > To: edk2-devel@lists.01.org
> > > Subject: [edk2] SNP transmit print
> > >
> > > Hi,
> > >
> > >
> > > While performing tftp using PCI interface, below message is coming
> > > continuously:
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > > [======================================> ]   34812 Kb
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > >
> > > It is coming from file
> > "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> > >
> > >   DEBUG (
> > >     (EFI_D_ERROR,
> > >     "\nSnp->undi.transmit()  %xh:%xh\n",
> > >     Snp->Cdb.StatFlags,
> > >     Snp->Cdb.StatCode)
> > >     );
> > >
> > >
> > > I want to know if it is really an error message because tftp and 
> > > ping are working perfectly, but this error message is coming.
> > >
> > >
> > > Thanks,
> > > Meenakshi
> > >
> > >
> > >
> > > _______________________________________________
> > > edk2-devel mailing list
> > > edk2-devel@lists.01.org
> > > https://lists.01.org/mailman/listinfo/edk2-devel

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

* Re: SNP transmit print
  2017-09-22 11:03     ` Udit Kumar
  2017-09-22 13:27       ` Zeng, Star
@ 2017-09-25  0:58       ` Fu, Siyuan
  2017-09-25  5:44         ` Meenakshi Aggarwal
  1 sibling, 1 reply; 7+ messages in thread
From: Fu, Siyuan @ 2017-09-25  0:58 UTC (permalink / raw)
  To: Udit Kumar, Meenakshi Aggarwal, edk2-devel@lists.01.org
  Cc: Tian, Feng, Zeng, Star

Hi, Meenakshi

You are correct that it's a bug in SNP driver to print error information for successfully transmitted packet. Please create a Bugzilla ticket for this issue and we will follow it. Thanks.


BestRegards
Fu Siyuan


-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Udit Kumar
Sent: Friday, September 22, 2017 7:04 PM
To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-devel@lists.01.org
Cc: Tian, Feng <feng.tian@intel.com>; Zeng, Star <star.zeng@intel.com>
Subject: Re: [edk2] SNP transmit print

Thanks Meenakshi for digging a bit more 

If we have use like below 
Library/DxeNetLib/DxeNetLib.c
Status = Snp->Transmit (Snp, 0, Length, Packet, NULL, NULL, NULL);
    if ((Status != EFI_SUCCESS) && (Status != EFI_NOT_READY)) {
      Status = EFI_DEVICE_ERROR;
      break;
    }
Then, we can simple put print when Status is EFI_DEVICE_ERROR;

But with below We are retrying once ☹ ,  What I think if first time if you got error 
EFI_NOT_READY, then after MnpRecycleTxBuf we likely not to get this error. 
I am not 100% sure here. 

What I think, in MdeModulePkg/Universal/Network/SnpDxe/Transmit.c 
Have print only for EFI_NOT_READY. 
And in MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c, print error as well 
for second case. 
Hope this helps 

Thanks
Udit

> -----Original Message-----
> From: Meenakshi Aggarwal
> Sent: Friday, September 22, 2017 3:56 PM
> To: Udit Kumar <udit.kumar@nxp.com>; edk2-devel@lists.01.org
> Cc: feng.tian@intel.com; star.zeng@intel.com
> Subject: RE: SNP transmit print
> 
> Hi Udit,
> 
> Yes, I think we should print this message is Status is EFI_DEVICE_ERROR because
> in case of EFI_NOT_READY, we are retrying:
> 
>   //
>   // Transmit the packet through SNP.
>   //
>   Status = Snp->Transmit (
>                   Snp,
>                   HeaderSize,
>                   Length,
>                   Packet,
>                   TxData->SourceAddress,
>                   TxData->DestinationAddress,
>                   &ProtocolType
>                   );
>   if (Status == EFI_NOT_READY) {
>     Status = MnpRecycleTxBuf (MnpDeviceData);
>     if (EFI_ERROR (Status)) {
>       Token->Status = EFI_DEVICE_ERROR;
>       goto SIGNAL_TOKEN;
>     }
> 
>     DEBUG ((EFI_D_ERROR, "Snp->Transmit  retry\n"));
>     Status = Snp->Transmit (
>                     Snp,
>                     HeaderSize,
>                     Length,
>                     Packet,
>                     TxData->SourceAddress,
>                     TxData->DestinationAddress,
>                     &ProtocolType
>                     );
>   }
> 
> (MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c)
> 
> 
> Please suggest if we can remove this print in case of BUSY status.
> 
> Thanks,
> Meenakshi
> 
> > -----Original Message-----
> > From: Udit Kumar
> > Sent: Thursday, September 21, 2017 5:21 PM
> > To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-
> > devel@lists.01.org
> > Subject: RE: SNP transmit print
> >
> > I think these error prints should be check against Status
> >
> > Regards
> > Udit
> >
> > > -----Original Message-----
> > > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf
> > > Of Meenakshi Aggarwal
> > > Sent: Thursday, September 21, 2017 3:36 PM
> > > To: edk2-devel@lists.01.org
> > > Subject: [edk2] SNP transmit print
> > >
> > > Hi,
> > >
> > >
> > > While performing tftp using PCI interface, below message is coming
> > > continuously:
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > > [======================================> ]   34812 Kb
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > > Snp->undi.transmit()  8000h:4h
> > >
> > >
> > > It is coming from file
> > "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> > >
> > >   DEBUG (
> > >     (EFI_D_ERROR,
> > >     "\nSnp->undi.transmit()  %xh:%xh\n",
> > >     Snp->Cdb.StatFlags,
> > >     Snp->Cdb.StatCode)
> > >     );
> > >
> > >
> > > I want to know if it is really an error message because tftp and
> > > ping are working perfectly, but this error message is coming.
> > >
> > >
> > > Thanks,
> > > Meenakshi
> > >
> > >
> > >
> > > _______________________________________________
> > > edk2-devel mailing list
> > > edk2-devel@lists.01.org
> > > https://lists.01.org/mailman/listinfo/edk2-devel
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

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

* Re: SNP transmit print
  2017-09-25  0:58       ` Fu, Siyuan
@ 2017-09-25  5:44         ` Meenakshi Aggarwal
  0 siblings, 0 replies; 7+ messages in thread
From: Meenakshi Aggarwal @ 2017-09-25  5:44 UTC (permalink / raw)
  To: Fu, Siyuan, Udit Kumar, edk2-devel@lists.01.org; +Cc: Tian, Feng, Zeng, Star

Hi,

Created bug:

https://bugzilla.tianocore.org/show_bug.cgi?id=719

Thanks,
Meenakshi

> -----Original Message-----
> From: Fu, Siyuan [mailto:siyuan.fu@intel.com]
> Sent: Monday, September 25, 2017 6:29 AM
> To: Udit Kumar <udit.kumar@nxp.com>; Meenakshi Aggarwal
> <meenakshi.aggarwal@nxp.com>; edk2-devel@lists.01.org
> Cc: Tian, Feng <feng.tian@intel.com>; Zeng, Star <star.zeng@intel.com>
> Subject: RE: SNP transmit print
> 
> Hi, Meenakshi
> 
> You are correct that it's a bug in SNP driver to print error information for
> successfully transmitted packet. Please create a Bugzilla ticket for this issue
> and we will follow it. Thanks.
> 
> 
> BestRegards
> Fu Siyuan
> 
> 
> -----Original Message-----
> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
> Udit Kumar
> Sent: Friday, September 22, 2017 7:04 PM
> To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-
> devel@lists.01.org
> Cc: Tian, Feng <feng.tian@intel.com>; Zeng, Star <star.zeng@intel.com>
> Subject: Re: [edk2] SNP transmit print
> 
> Thanks Meenakshi for digging a bit more
> 
> If we have use like below
> Library/DxeNetLib/DxeNetLib.c
> Status = Snp->Transmit (Snp, 0, Length, Packet, NULL, NULL, NULL);
>     if ((Status != EFI_SUCCESS) && (Status != EFI_NOT_READY)) {
>       Status = EFI_DEVICE_ERROR;
>       break;
>     }
> Then, we can simple put print when Status is EFI_DEVICE_ERROR;
> 
> But with below We are retrying once ☹ ,  What I think if first time if you got
> error EFI_NOT_READY, then after MnpRecycleTxBuf we likely not to get this
> error.
> I am not 100% sure here.
> 
> What I think, in MdeModulePkg/Universal/Network/SnpDxe/Transmit.c
> Have print only for EFI_NOT_READY.
> And in MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c, print error as
> well for second case.
> Hope this helps
> 
> Thanks
> Udit
> 
> > -----Original Message-----
> > From: Meenakshi Aggarwal
> > Sent: Friday, September 22, 2017 3:56 PM
> > To: Udit Kumar <udit.kumar@nxp.com>; edk2-devel@lists.01.org
> > Cc: feng.tian@intel.com; star.zeng@intel.com
> > Subject: RE: SNP transmit print
> >
> > Hi Udit,
> >
> > Yes, I think we should print this message is Status is
> > EFI_DEVICE_ERROR because in case of EFI_NOT_READY, we are retrying:
> >
> >   //
> >   // Transmit the packet through SNP.
> >   //
> >   Status = Snp->Transmit (
> >                   Snp,
> >                   HeaderSize,
> >                   Length,
> >                   Packet,
> >                   TxData->SourceAddress,
> >                   TxData->DestinationAddress,
> >                   &ProtocolType
> >                   );
> >   if (Status == EFI_NOT_READY) {
> >     Status = MnpRecycleTxBuf (MnpDeviceData);
> >     if (EFI_ERROR (Status)) {
> >       Token->Status = EFI_DEVICE_ERROR;
> >       goto SIGNAL_TOKEN;
> >     }
> >
> >     DEBUG ((EFI_D_ERROR, "Snp->Transmit  retry\n"));
> >     Status = Snp->Transmit (
> >                     Snp,
> >                     HeaderSize,
> >                     Length,
> >                     Packet,
> >                     TxData->SourceAddress,
> >                     TxData->DestinationAddress,
> >                     &ProtocolType
> >                     );
> >   }
> >
> > (MdeModulePkg/Universal/Network/MnpDxe/MnpIo.c)
> >
> >
> > Please suggest if we can remove this print in case of BUSY status.
> >
> > Thanks,
> > Meenakshi
> >
> > > -----Original Message-----
> > > From: Udit Kumar
> > > Sent: Thursday, September 21, 2017 5:21 PM
> > > To: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>; edk2-
> > > devel@lists.01.org
> > > Subject: RE: SNP transmit print
> > >
> > > I think these error prints should be check against Status
> > >
> > > Regards
> > > Udit
> > >
> > > > -----Original Message-----
> > > > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On
> > > > Behalf Of Meenakshi Aggarwal
> > > > Sent: Thursday, September 21, 2017 3:36 PM
> > > > To: edk2-devel@lists.01.org
> > > > Subject: [edk2] SNP transmit print
> > > >
> > > > Hi,
> > > >
> > > >
> > > > While performing tftp using PCI interface, below message is coming
> > > > continuously:
> > > >
> > > > Snp->undi.transmit()  8000h:4h
> > > >
> > > > Snp->undi.transmit()  8000h:4h
> > > > [======================================> ]   34812 Kb
> > > > Snp->undi.transmit()  8000h:4h
> > > >
> > > > Snp->undi.transmit()  8000h:4h
> > > >
> > > > Snp->undi.transmit()  8000h:4h
> > > >
> > > > Snp->undi.transmit()  8000h:4h
> > > >
> > > >
> > > > It is coming from file
> > > "MdeModulePkg/Universal/Network/SnpDxe/Transmit.c"
> > > >
> > > >   DEBUG (
> > > >     (EFI_D_ERROR,
> > > >     "\nSnp->undi.transmit()  %xh:%xh\n",
> > > >     Snp->Cdb.StatFlags,
> > > >     Snp->Cdb.StatCode)
> > > >     );
> > > >
> > > >
> > > > I want to know if it is really an error message because tftp and
> > > > ping are working perfectly, but this error message is coming.
> > > >
> > > >
> > > > Thanks,
> > > > Meenakshi
> > > >
> > > >
> > > >
> > > > _______________________________________________
> > > > edk2-devel mailing list
> > > > edk2-devel@lists.01.org
> > > > https://lists.01.org/mailman/listinfo/edk2-devel
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel

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

end of thread, other threads:[~2017-09-25  5:40 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-21 10:06 SNP transmit print Meenakshi Aggarwal
2017-09-21 11:50 ` Udit Kumar
2017-09-22 10:25   ` Meenakshi Aggarwal
2017-09-22 11:03     ` Udit Kumar
2017-09-22 13:27       ` Zeng, Star
2017-09-25  0:58       ` Fu, Siyuan
2017-09-25  5:44         ` Meenakshi Aggarwal

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