public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* MCEUSB: falsly claims mass storage device
@ 2011-01-09 17:36 Patrick Boettcher
  2011-02-09  1:38 ` Lucian Muresan
  0 siblings, 1 reply; 6+ messages in thread
From: Patrick Boettcher @ 2011-01-09 17:36 UTC (permalink / raw)
  To: Jarod Wilson; +Cc: Linux Media Mailing List

Hi Jarod,

I'm using an MultiCard-reader which exposes itself like shown below.

It is falsly claimed by the mceusb-driver from (2.6.36 from debian-
experimental) . 

Would be good to create an exception for this one if possible. Let me know if 
you need more information or if you want me to take other actions.

>From dmesg:

[22389.084024] Registered IR keymap rc-rc6-mce
[22389.084288] input: Media Center Ed. eHome Infrared Remote Transceiver 
(0bda:0161) as /devices/virtual/rc/rc0/input8
[22389.084484] rc0: Media Center Ed. eHome Infrared Remote Transceiver 
(0bda:0161) as /devices/virtual/rc/rc0
[22389.084877] rc rc0: lirc_dev: driver ir-lirc-codec (mceusb) registered at 
minor = 1
[22389.085515] mceusb 1-2:1.0: Registered Generic USB2.0-CRW on usb1:6
[22389.164964] Registered IR keymap rc-rc6-mce
[22389.165264] input: Media Center Ed. eHome Infrared Remote Transceiver 
(0bda:0161) as /devices/virtual/rc/rc1/input9
[22389.165402] rc1: Media Center Ed. eHome Infrared Remote Transceiver 
(0bda:0161) as /devices/virtual/rc/rc1
[22389.171179] rc rc1: lirc_dev: driver ir-lirc-codec (mceusb) registered at 
minor = 2
[22389.171995] mceusb 1-2:1.1: Registered Generic USB2.0-CRW on usb1:6

lsusb -v: 

Bus 001 Device 007: ID 0bda:0161 Realtek Semiconductor Corp. Mass Storage 
Device
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0 
  bDeviceProtocol         0 
  bMaxPacketSize0        64
  idVendor           0x0bda Realtek Semiconductor Corp.
  idProduct          0x0161 Mass Storage Device
  bcdDevice           61.10
  iManufacturer           1 
  iProduct                2 
  iSerial                 3 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength          116
    bNumInterfaces          2
    bConfigurationValue     1
    iConfiguration          4 
    bmAttributes         0x80
      (Bus Powered)
    MaxPower              500mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      bInterfaceClass        11 Chip/SmartCard
      bInterfaceSubClass      0 
      bInterfaceProtocol      0 
      iInterface              6 
      ChipCard Interface Descriptor:
        bLength                54
        bDescriptorType        33
        bcdCCID              1.10  (Warning: Only accurate for version 1.0)
        nMaxSlotIndex           0
        bVoltageSupport         7  5.0V 3.0V 1.8V 
        dwProtocols             3  T=0 T=1
        dwDefaultClock       3750
        dwMaxiumumClock      7500
        bNumClockSupported      0
        dwDataRate          10080 bps
        dwMaxDataRate      312500 bps
        bNumDataRatesSupp.      0
        dwMaxIFSD             254
        dwSyncProtocols  00000000 
        dwMechanical     00000000 
        dwFeatures       00010030
          Auto clock change
          Auto baud rate change
          TPDU level exchange
        dwMaxCCIDMsgLen       271
        bClassGetResponse      00
        bClassEnvelope         00
        wlcdLayout           none
        bPINSupport             0 
        bMaxCCIDBusySlots       1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x05  EP 5 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x86  EP 6 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     80 Bulk (Zip)
      iInterface              5 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0

best regards,
--
Patrick Boettcher - KernelLabs
http://www.kernellabs.com/

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

* Re: MCEUSB: falsly claims mass storage device
  2011-01-09 17:36 MCEUSB: falsly claims mass storage device Patrick Boettcher
@ 2011-02-09  1:38 ` Lucian Muresan
  2011-02-09  5:19   ` Jarod Wilson
  0 siblings, 1 reply; 6+ messages in thread
From: Lucian Muresan @ 2011-02-09  1:38 UTC (permalink / raw)
  To: Linux Media Mailing List; +Cc: Patrick Boettcher, Jarod Wilson

On 09.01.2011 18:36, Patrick Boettcher wrote:
> Hi Jarod,
> 
> I'm using an MultiCard-reader which exposes itself like shown below.
> 
> It is falsly claimed by the mceusb-driver from (2.6.36 from debian-
> experimental) . 


Hi there,

I also bought a similar Multi-Cardreader, which also comes with a MCE
remote control. It seems that the Realtek chip inside (RTS5161 I've
found in other posts on the net) can really do it all: flash card
reader, CCID compatible smartcard reader and MCE remote, maybe that's
why on some readers using it, the wrong module claim it, or on some,
like mine, claim "too much"?

My problem on a 2.6.38-rc2 kernel self-built on Gentoo is that the
mceusb module registers 2 LIRC devices /dev/lirc0 and /dev/lirc1, as
well as 2 input devices, and in that situation, the smartcard part of
the reader is not usale by openct. Once I managed, after manually
removing the mceusb module, to load it and have it register only one
such device, and then openct-tool at least found a CCID-compatible
reader, but somehow it only happened once. So there seem to be problems
in the mceusb module with this chip... Is there currently someone
working on this problem? Below, see the output of lsusb for my
multi-reader/MCE RC...

Best Regards,
Lucian


lsusb -v -d 0bda:0161

Bus 001 Device 002: ID 0bda:0161 Realtek Semiconductor Corp. Mass
Storage Device
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0        64
  idVendor           0x0bda Realtek Semiconductor Corp.
  idProduct          0x0161 Mass Storage Device
  bcdDevice           61.10
  iManufacturer           1 Generic
  iProduct                2 USB2.0-CRW
  iSerial                 3 20070818000000000
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength          139
    bNumInterfaces          3
    bConfigurationValue     1
    iConfiguration          4 CARD READER
    bmAttributes         0xa0
      (Bus Powered)
      Remote Wakeup
    MaxPower              500mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      bInterfaceClass        11 Chip/SmartCard
      bInterfaceSubClass      0
      bInterfaceProtocol      0
      iInterface              6 Smart Card Reader Interface
      ChipCard Interface Descriptor:
        bLength                54
        bDescriptorType        33
        bcdCCID              1.10  (Warning: Only accurate for version 1.0)
        nMaxSlotIndex           0
        bVoltageSupport         7  5.0V 3.0V 1.8V
        dwProtocols             3  T=0 T=1
        dwDefaultClock       3750
        dwMaxiumumClock      7500
        bNumClockSupported      0
        dwDataRate          10080 bps
        dwMaxDataRate      312500 bps
        bNumDataRatesSupp.      0
        dwMaxIFSD             254
        dwSyncProtocols  00000000
        dwMechanical     00000000
        dwFeatures       00010030
          Auto clock change
          Auto baud rate change
          TPDU level exchange
        dwMaxCCIDMsgLen       271
        bClassGetResponse      00
        bClassEnvelope         00
        wlcdLayout           none
        bPINSupport             0
        bMaxCCIDBusySlots       1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x05  EP 5 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x86  EP 6 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        1
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     80 Bulk (Zip)
      iInterface              5 Bulk-In, Bulk-Out, Interface
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        2
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass    255 Vendor Specific Subclass
      bInterfaceProtocol    255 Vendor Specific Protocol
      iInterface              7 eHome Infrared Receiver
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x07  EP 7 OUT
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x88  EP 8 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               8
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0000
  (Bus Powered)

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

* Re: MCEUSB: falsly claims mass storage device
  2011-02-09  1:38 ` Lucian Muresan
@ 2011-02-09  5:19   ` Jarod Wilson
  2011-02-17 11:46     ` Lucian Muresan
  0 siblings, 1 reply; 6+ messages in thread
From: Jarod Wilson @ 2011-02-09  5:19 UTC (permalink / raw)
  To: Lucian Muresan; +Cc: Linux Media Mailing List, Patrick Boettcher

On Feb 8, 2011, at 8:38 PM, Lucian Muresan wrote:

> On 09.01.2011 18:36, Patrick Boettcher wrote:
>> Hi Jarod,
>> 
>> I'm using an MultiCard-reader which exposes itself like shown below.
>> 
>> It is falsly claimed by the mceusb-driver from (2.6.36 from debian-
>> experimental) .

Bah. First up, apologies, Patrick, it seems I somehow missed your
mail.


> Hi there,
> 
> I also bought a similar Multi-Cardreader, which also comes with a MCE
> remote control. It seems that the Realtek chip inside (RTS5161 I've
> found in other posts on the net) can really do it all: flash card
> reader, CCID compatible smartcard reader and MCE remote, maybe that's
> why on some readers using it, the wrong module claim it, or on some,
> like mine, claim "too much"?

Well, there are some relatively new cx231xx-based usb capture devices
that similarly are claimed by the mceusb driver, but we had to add an
explicit quirk that says only bind to those devices on a specific
interface (usb_host_interface->desc.bInterfaceNumber == 0). I suspect
that we probably just need to do something similar for this device.


> My problem on a 2.6.38-rc2 kernel self-built on Gentoo is that the
> mceusb module registers 2 LIRC devices /dev/lirc0 and /dev/lirc1, as
> well as 2 input devices, and in that situation, the smartcard part of
> the reader is not usale by openct. Once I managed, after manually
> removing the mceusb module, to load it and have it register only one
> such device, and then openct-tool at least found a CCID-compatible
> reader, but somehow it only happened once. So there seem to be problems
> in the mceusb module with this chip... Is there currently someone
> working on this problem? Below, see the output of lsusb for my
> multi-reader/MCE RC...
> 
> Best Regards,
> Lucian
> 
> 
> lsusb -v -d 0bda:0161
> 
> Bus 001 Device 002: ID 0bda:0161 Realtek Semiconductor Corp. Mass
> Storage Device
> Device Descriptor:
>  bLength                18
>  bDescriptorType         1
>  bcdUSB               2.00
>  bDeviceClass            0 (Defined at Interface level)
>  bDeviceSubClass         0
>  bDeviceProtocol         0
>  bMaxPacketSize0        64
>  idVendor           0x0bda Realtek Semiconductor Corp.
>  idProduct          0x0161 Mass Storage Device
>  bcdDevice           61.10
>  iManufacturer           1 Generic
>  iProduct                2 USB2.0-CRW
>  iSerial                 3 20070818000000000
>  bNumConfigurations      1
>  Configuration Descriptor:
>    bLength                 9
>    bDescriptorType         2
>    wTotalLength          139
>    bNumInterfaces          3
...
>    Interface Descriptor:
>      bLength                 9
>      bDescriptorType         4
>      bInterfaceNumber        2
>      bAlternateSetting       0
>      bNumEndpoints           2
>      bInterfaceClass       255 Vendor Specific Class
>      bInterfaceSubClass    255 Vendor Specific Subclass
>      bInterfaceProtocol    255 Vendor Specific Protocol
>      iInterface              7 eHome Infrared Receiver

Looks like bInterfaceNumber == 2 on this device. The patch to handle this
similar to the conexant polaris devices should be pretty trivial. I'll
try to get something together tomorrow.

-- 
Jarod Wilson
jarod@wilsonet.com




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

* Re: MCEUSB: falsly claims mass storage device
  2011-02-09  5:19   ` Jarod Wilson
@ 2011-02-17 11:46     ` Lucian Muresan
  2011-02-28 22:34       ` Jarod Wilson
  0 siblings, 1 reply; 6+ messages in thread
From: Lucian Muresan @ 2011-02-17 11:46 UTC (permalink / raw)
  To: Linux Media Mailing List

On 09.02.2011 06:19, Jarod Wilson wrote:
[...]
> Looks like bInterfaceNumber == 2 on this device. The patch to handle this
> similar to the conexant polaris devices should be pretty trivial. I'll
> try to get something together tomorrow.

Hi,

any news on this one?

Regards,
Lucian

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

* Re: MCEUSB: falsly claims mass storage device
  2011-02-17 11:46     ` Lucian Muresan
@ 2011-02-28 22:34       ` Jarod Wilson
  2011-03-01 16:14         ` Jarod Wilson
  0 siblings, 1 reply; 6+ messages in thread
From: Jarod Wilson @ 2011-02-28 22:34 UTC (permalink / raw)
  To: Lucian Muresan; +Cc: Linux Media Mailing List

On Feb 17, 2011, at 6:46 AM, Lucian Muresan wrote:

> On 09.02.2011 06:19, Jarod Wilson wrote:
> [...]
>> Looks like bInterfaceNumber == 2 on this device. The patch to handle this
>> similar to the conexant polaris devices should be pretty trivial. I'll
>> try to get something together tomorrow.
> 
> Hi,
> 
> any news on this one?

I suck, but I have a patch in my local tree now. Need to build and
quickly test it to make sure it doesn't break the devices I've got,
then I'll get it posted.

-- 
Jarod Wilson
jarod@wilsonet.com




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

* Re: MCEUSB: falsly claims mass storage device
  2011-02-28 22:34       ` Jarod Wilson
@ 2011-03-01 16:14         ` Jarod Wilson
  0 siblings, 0 replies; 6+ messages in thread
From: Jarod Wilson @ 2011-03-01 16:14 UTC (permalink / raw)
  To: Linux Media Mailing List; +Cc: Lucian Muresan

On Feb 28, 2011, at 5:34 PM, Jarod Wilson wrote:

> On Feb 17, 2011, at 6:46 AM, Lucian Muresan wrote:
> 
>> On 09.02.2011 06:19, Jarod Wilson wrote:
>> [...]
>>> Looks like bInterfaceNumber == 2 on this device. The patch to handle this
>>> similar to the conexant polaris devices should be pretty trivial. I'll
>>> try to get something together tomorrow.
>> 
>> Hi,
>> 
>> any news on this one?
> 
> I suck, but I have a patch in my local tree now. Need to build and
> quickly test it to make sure it doesn't break the devices I've got,
> then I'll get it posted.

Patch is posted.

https://patchwork.kernel.org/patch/599711/

-- 
Jarod Wilson
jarod@wilsonet.com




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

end of thread, other threads:[~2011-03-01 16:14 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-09 17:36 MCEUSB: falsly claims mass storage device Patrick Boettcher
2011-02-09  1:38 ` Lucian Muresan
2011-02-09  5:19   ` Jarod Wilson
2011-02-17 11:46     ` Lucian Muresan
2011-02-28 22:34       ` Jarod Wilson
2011-03-01 16:14         ` Jarod Wilson

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