public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Re: [RESEND][USB IF]Mismatch between EDK2 and a USB vendor
@ 2016-10-20 11:49 Yosuke Katayama1
  2016-10-21  5:31 ` Tian, Feng
  0 siblings, 1 reply; 3+ messages in thread
From: Yosuke Katayama1 @ 2016-10-20 11:49 UTC (permalink / raw)
  To: Tian, Feng; +Cc: edk2-devel@lists.01.org

Hello Feng,

This is just a reminder.
Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Tuesday, October 18, 2016 7:01 PM
To: Tian, Feng
Cc: edk2-devel@lists.01.org
Subject: Re: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

We haven't get any feedback from USB.org yet but could you provide us with the patch?
We found a new issue probably caused by this mismatch in our current products and I want to check if the patch could fix the issue or not at least.

Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Yosuke Katayama1 
Sent: Wednesday, September 21, 2016 5:15 PM
To: 'Tian, Feng'
Cc: edk2-devel@lists.01.org
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

Thank you for the reply.

Please wait for creating the fix. 

Currently the USB vendor is contacting USB organization to check if the vendor's interpretation of the IF spec is valid or not. I will let you know when the vendor has received the answer from the organization, then you can decide whether to fix or not. 

What do you think of this plan?

PS: We are using XHCI.

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Tian, Feng [mailto:feng.tian@intel.com] 
Sent: Wednesday, September 21, 2016 3:14 PM
To: Yosuke Katayama1; edk2-devel@lists.01.org
Cc: Tian, Feng
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hi, Katayama

We never receive such feedback on inconsecutive usb interface number. I agree EDKII usb driver should be able to handle this.

I am working on a fix, but I have no such device at hand. Could you help me verify it when the patch is ready? 

PS: what host controller are you using? EHCI or XHCI?

Thanks
Feng

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Wednesday, September 21, 2016 8:05 AM
To: edk2-devel@lists.01.org
Subject: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello, 

This is relating to my previous post "[edk2] Is this a right place to discuss EDK2's USB IF implementation?" 
We found a mismatch between EDK2 source code and our USB vendor's implementation. Could you give us your opinions?


bInterfaceNumber , 9.6.5 Interface from Universal Serial Bus 3.1 Specification Rev 1.0 says;
--
Number of this interface. Zero-based value identifying the index in the array of concurrent interfaces supported by this configuration.
--


Regarding this.
EDK2 source code (UsbDesc.c) says:
--
  //
  // If a configuration has several interfaces, these interfaces are
  // numbered from zero to n...
  //
--


The USB vendor says:
--
* Numbering is not necessarily consecutive * Each interface can be independently turned on/off * Solution allows any combination of interfaces without re-defining the interface number * One general lookup table can tell you what interface is assigned to what interface number.
* For these reasons, the interface definition is like this on our products.
* The interface definition has remained the same from the previous products, and other products before that.
* Current interface numbering is supported by all Microsoft OS * Other PC OEM customers have never raised this issue
--

As a result, the vendor's USB IF looks like below.

===>Configuration Descriptor<===
...
bNumInterfaces:                    0x02				<<<<
bConfigurationValue:               0x01
iConfiguration:                    0x00
bmAttributes:                      0xA0  -> Bus Powered
  -> Remote Wakeup
...
          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0C				<<<<	Interface Number starts from 0x0C instead of 0. [comment from Yosuke]
bAlternateSetting:                 0x00
bNumEndpoints:                     0x01
...

          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0D                            <<<<
bAlternateSetting:                 0x00
bNumEndpoints:                     0x00
...


and it hits the following ON_ERROR in UsbDesc.c.
--
    } else if (Setting->Desc.InterfaceNumber >= NumIf) {
      DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: mal-formated interface descriptor\n"));

      UsbFreeInterfaceDesc (Setting);
      goto ON_ERROR;
    }
--


What do you think the vendor's implementation?
Also, have you ever had such a USB IF mismatch between EDK2 and USB vendors before? If so, how are you handling such cases in general?

Kind regards,
Yosuke
_______________________________________________
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] 3+ messages in thread

* Re: [RESEND][USB IF]Mismatch between EDK2 and a USB vendor
  2016-10-20 11:49 [RESEND][USB IF]Mismatch between EDK2 and a USB vendor Yosuke Katayama1
@ 2016-10-21  5:31 ` Tian, Feng
  2016-10-24 11:06   ` Yosuke Katayama1
  0 siblings, 1 reply; 3+ messages in thread
From: Tian, Feng @ 2016-10-21  5:31 UTC (permalink / raw)
  To: Yosuke Katayama1; +Cc: edk2-devel@lists.01.org, Tian, Feng

I am working on a patch, will get back to you when I am ready.

Thanks
Feng

-----Original Message-----
From: Yosuke Katayama1 [mailto:ykatayama1@lenovo.com] 
Sent: Thursday, October 20, 2016 7:50 PM
To: Tian, Feng <feng.tian@intel.com>
Cc: edk2-devel@lists.01.org
Subject: RE: [RESEND][EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

This is just a reminder.
Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Tuesday, October 18, 2016 7:01 PM
To: Tian, Feng
Cc: edk2-devel@lists.01.org
Subject: Re: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

We haven't get any feedback from USB.org yet but could you provide us with the patch?
We found a new issue probably caused by this mismatch in our current products and I want to check if the patch could fix the issue or not at least.

Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Yosuke Katayama1 
Sent: Wednesday, September 21, 2016 5:15 PM
To: 'Tian, Feng'
Cc: edk2-devel@lists.01.org
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

Thank you for the reply.

Please wait for creating the fix. 

Currently the USB vendor is contacting USB organization to check if the vendor's interpretation of the IF spec is valid or not. I will let you know when the vendor has received the answer from the organization, then you can decide whether to fix or not. 

What do you think of this plan?

PS: We are using XHCI.

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Tian, Feng [mailto:feng.tian@intel.com] 
Sent: Wednesday, September 21, 2016 3:14 PM
To: Yosuke Katayama1; edk2-devel@lists.01.org
Cc: Tian, Feng
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hi, Katayama

We never receive such feedback on inconsecutive usb interface number. I agree EDKII usb driver should be able to handle this.

I am working on a fix, but I have no such device at hand. Could you help me verify it when the patch is ready? 

PS: what host controller are you using? EHCI or XHCI?

Thanks
Feng

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Wednesday, September 21, 2016 8:05 AM
To: edk2-devel@lists.01.org
Subject: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello, 

This is relating to my previous post "[edk2] Is this a right place to discuss EDK2's USB IF implementation?" 
We found a mismatch between EDK2 source code and our USB vendor's implementation. Could you give us your opinions?


bInterfaceNumber , 9.6.5 Interface from Universal Serial Bus 3.1 Specification Rev 1.0 says;
--
Number of this interface. Zero-based value identifying the index in the array of concurrent interfaces supported by this configuration.
--


Regarding this.
EDK2 source code (UsbDesc.c) says:
--
  //
  // If a configuration has several interfaces, these interfaces are
  // numbered from zero to n...
  //
--


The USB vendor says:
--
* Numbering is not necessarily consecutive * Each interface can be independently turned on/off * Solution allows any combination of interfaces without re-defining the interface number * One general lookup table can tell you what interface is assigned to what interface number.
* For these reasons, the interface definition is like this on our products.
* The interface definition has remained the same from the previous products, and other products before that.
* Current interface numbering is supported by all Microsoft OS * Other PC OEM customers have never raised this issue
--

As a result, the vendor's USB IF looks like below.

===>Configuration Descriptor<===
...
bNumInterfaces:                    0x02				<<<<
bConfigurationValue:               0x01
iConfiguration:                    0x00
bmAttributes:                      0xA0  -> Bus Powered
  -> Remote Wakeup
...
          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0C				<<<<	Interface Number starts from 0x0C instead of 0. [comment from Yosuke]
bAlternateSetting:                 0x00
bNumEndpoints:                     0x01
...

          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0D                            <<<<
bAlternateSetting:                 0x00
bNumEndpoints:                     0x00
...


and it hits the following ON_ERROR in UsbDesc.c.
--
    } else if (Setting->Desc.InterfaceNumber >= NumIf) {
      DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: mal-formated interface descriptor\n"));

      UsbFreeInterfaceDesc (Setting);
      goto ON_ERROR;
    }
--


What do you think the vendor's implementation?
Also, have you ever had such a USB IF mismatch between EDK2 and USB vendors before? If so, how are you handling such cases in general?

Kind regards,
Yosuke
_______________________________________________
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] 3+ messages in thread

* Re: [RESEND][USB IF]Mismatch between EDK2 and a USB vendor
  2016-10-21  5:31 ` Tian, Feng
@ 2016-10-24 11:06   ` Yosuke Katayama1
  0 siblings, 0 replies; 3+ messages in thread
From: Yosuke Katayama1 @ 2016-10-24 11:06 UTC (permalink / raw)
  To: Tian, Feng; +Cc: edk2-devel@lists.01.org

Hello Feng,

Thank you for working on it.
When do you think you can prepare the patch?
I just want to know it to make our BIOS release plan. 

By the way, the USB vendor haven't received from USB.org yet.

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Tian, Feng [mailto:feng.tian@intel.com] 
Sent: Friday, October 21, 2016 2:31 PM
To: Yosuke Katayama1
Cc: edk2-devel@lists.01.org; Tian, Feng
Subject: RE: [RESEND][EDK2][USB IF]Mismatch between EDK2 and a USB vendor

I am working on a patch, will get back to you when I am ready.

Thanks
Feng

-----Original Message-----
From: Yosuke Katayama1 [mailto:ykatayama1@lenovo.com] 
Sent: Thursday, October 20, 2016 7:50 PM
To: Tian, Feng <feng.tian@intel.com>
Cc: edk2-devel@lists.01.org
Subject: RE: [RESEND][EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

This is just a reminder.
Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Tuesday, October 18, 2016 7:01 PM
To: Tian, Feng
Cc: edk2-devel@lists.01.org
Subject: Re: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

We haven't get any feedback from USB.org yet but could you provide us with the patch?
We found a new issue probably caused by this mismatch in our current products and I want to check if the patch could fix the issue or not at least.

Thank you for all your support!

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Yosuke Katayama1 
Sent: Wednesday, September 21, 2016 5:15 PM
To: 'Tian, Feng'
Cc: edk2-devel@lists.01.org
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello Feng,

Thank you for the reply.

Please wait for creating the fix. 

Currently the USB vendor is contacting USB organization to check if the vendor's interpretation of the IF spec is valid or not. I will let you know when the vendor has received the answer from the organization, then you can decide whether to fix or not. 

What do you think of this plan?

PS: We are using XHCI.

Kind regards,
Yosuke Katayama

-----Original Message-----
From: Tian, Feng [mailto:feng.tian@intel.com] 
Sent: Wednesday, September 21, 2016 3:14 PM
To: Yosuke Katayama1; edk2-devel@lists.01.org
Cc: Tian, Feng
Subject: RE: [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hi, Katayama

We never receive such feedback on inconsecutive usb interface number. I agree EDKII usb driver should be able to handle this.

I am working on a fix, but I have no such device at hand. Could you help me verify it when the patch is ready? 

PS: what host controller are you using? EHCI or XHCI?

Thanks
Feng

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Yosuke Katayama1
Sent: Wednesday, September 21, 2016 8:05 AM
To: edk2-devel@lists.01.org
Subject: [edk2] [EDK2][USB IF]Mismatch between EDK2 and a USB vendor

Hello, 

This is relating to my previous post "[edk2] Is this a right place to discuss EDK2's USB IF implementation?" 
We found a mismatch between EDK2 source code and our USB vendor's implementation. Could you give us your opinions?


bInterfaceNumber , 9.6.5 Interface from Universal Serial Bus 3.1 Specification Rev 1.0 says;
--
Number of this interface. Zero-based value identifying the index in the array of concurrent interfaces supported by this configuration.
--


Regarding this.
EDK2 source code (UsbDesc.c) says:
--
  //
  // If a configuration has several interfaces, these interfaces are
  // numbered from zero to n...
  //
--


The USB vendor says:
--
* Numbering is not necessarily consecutive * Each interface can be independently turned on/off * Solution allows any combination of interfaces without re-defining the interface number * One general lookup table can tell you what interface is assigned to what interface number.
* For these reasons, the interface definition is like this on our products.
* The interface definition has remained the same from the previous products, and other products before that.
* Current interface numbering is supported by all Microsoft OS * Other PC OEM customers have never raised this issue
--

As a result, the vendor's USB IF looks like below.

===>Configuration Descriptor<===
...
bNumInterfaces:                    0x02				<<<<
bConfigurationValue:               0x01
iConfiguration:                    0x00
bmAttributes:                      0xA0  -> Bus Powered
  -> Remote Wakeup
...
          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0C				<<<<	Interface Number starts from 0x0C instead of 0. [comment from Yosuke]
bAlternateSetting:                 0x00
bNumEndpoints:                     0x01
...

          ===>Interface Descriptor<===
...
bInterfaceNumber:                  0x0D                            <<<<
bAlternateSetting:                 0x00
bNumEndpoints:                     0x00
...


and it hits the following ON_ERROR in UsbDesc.c.
--
    } else if (Setting->Desc.InterfaceNumber >= NumIf) {
      DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: mal-formated interface descriptor\n"));

      UsbFreeInterfaceDesc (Setting);
      goto ON_ERROR;
    }
--


What do you think the vendor's implementation?
Also, have you ever had such a USB IF mismatch between EDK2 and USB vendors before? If so, how are you handling such cases in general?

Kind regards,
Yosuke
_______________________________________________
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] 3+ messages in thread

end of thread, other threads:[~2016-10-24 11:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-20 11:49 [RESEND][USB IF]Mismatch between EDK2 and a USB vendor Yosuke Katayama1
2016-10-21  5:31 ` Tian, Feng
2016-10-24 11:06   ` Yosuke Katayama1

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