All of lore.kernel.org
 help / color / mirror / Atom feed
* mediatek: duplicate usb devices
@ 2019-03-05 18:33 Xose Vazquez Perez
  2019-03-06  5:14 ` Kalle Valo
  2019-03-06  7:50 ` Stanislaw Gruszka
  0 siblings, 2 replies; 8+ messages in thread
From: Xose Vazquez Perez @ 2019-03-05 18:33 UTC (permalink / raw)
  To: Felix Fietkau, Lorenzo Bianconi, Stanislaw Gruszka, linux-wireless

Hi,


There a three duplicate devices at:

mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */

mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },

mt76/mt76x0/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax / Elecom  */
mt76/mt76x2/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax EW 7722 UAC */


Thanks.

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

* Re: mediatek: duplicate usb devices
  2019-03-05 18:33 mediatek: duplicate usb devices Xose Vazquez Perez
@ 2019-03-06  5:14 ` Kalle Valo
  2019-03-06  7:50 ` Stanislaw Gruszka
  1 sibling, 0 replies; 8+ messages in thread
From: Kalle Valo @ 2019-03-06  5:14 UTC (permalink / raw)
  To: Xose Vazquez Perez
  Cc: Felix Fietkau, Lorenzo Bianconi, Stanislaw Gruszka,
	linux-wireless, Jakub Kicinski

+ jakub

Xose Vazquez Perez <xose.vazquez@gmail.com> writes:

> There a three duplicate devices at:

[...]

> mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },

This is not good, two drivers should not be competing about the same
device. So which driver should support this device?

-- 
Kalle Valo

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

* Re: mediatek: duplicate usb devices
  2019-03-05 18:33 mediatek: duplicate usb devices Xose Vazquez Perez
  2019-03-06  5:14 ` Kalle Valo
@ 2019-03-06  7:50 ` Stanislaw Gruszka
  2019-03-06  9:16   ` Lorenzo Bianconi
  2019-03-06 10:09   ` Lorenzo Bianconi
  1 sibling, 2 replies; 8+ messages in thread
From: Stanislaw Gruszka @ 2019-03-06  7:50 UTC (permalink / raw)
  To: Xose Vazquez Perez
  Cc: Felix Fietkau, Lorenzo Bianconi, linux-wireless, Jakub Kicinski

On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:
> There a three duplicate devices at:
> 
> mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */
One duplicated entry should be removed.

> mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },
Not sure about this.

> mt76/mt76x0/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax / Elecom  */
> mt76/mt76x2/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax EW 7722 UAC */
According to wikidevi we really have duplicated IDs:

https://wikidevi.com/wiki/Edimax_EW-7722UAC
https://wikidevi.com/wiki/Elecom_WDC-433SU2M

I think we can handle this by checking ASIC version from the EEPROM 
or registers at the beginning of probe and exit if it does not mach.
This should assure we will load proper driver.

Stanislaw

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

* Re: mediatek: duplicate usb devices
  2019-03-06  7:50 ` Stanislaw Gruszka
@ 2019-03-06  9:16   ` Lorenzo Bianconi
  2019-03-06 10:09   ` Lorenzo Bianconi
  1 sibling, 0 replies; 8+ messages in thread
From: Lorenzo Bianconi @ 2019-03-06  9:16 UTC (permalink / raw)
  To: Stanislaw Gruszka
  Cc: Xose Vazquez Perez, Felix Fietkau, Lorenzo Bianconi,
	linux-wireless, Jakub Kicinski

>
> On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:
> > There a three duplicate devices at:
> >
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */

This has been introduced in commit 62a25dc56990a, I will post a fix

Regards,
Lorenzo

> One duplicated entry should be removed.
>
> > mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> > mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },
> Not sure about this.
>
> > mt76/mt76x0/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax / Elecom  */
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax EW 7722 UAC */
> According to wikidevi we really have duplicated IDs:
>
> https://wikidevi.com/wiki/Edimax_EW-7722UAC
> https://wikidevi.com/wiki/Elecom_WDC-433SU2M
>
> I think we can handle this by checking ASIC version from the EEPROM
> or registers at the beginning of probe and exit if it does not mach.
> This should assure we will load proper driver.
>
> Stanislaw

-- 
UNIX is Sexy: who | grep -i blonde | talk; cd ~; wine; talk; touch;
unzip; touch; strip; gasp; finger; gasp; mount; fsck; more; yes; gasp;
umount; make clean; sleep

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

* Re: mediatek: duplicate usb devices
  2019-03-06  7:50 ` Stanislaw Gruszka
  2019-03-06  9:16   ` Lorenzo Bianconi
@ 2019-03-06 10:09   ` Lorenzo Bianconi
  2019-03-06 11:03     ` Stanislaw Gruszka
  1 sibling, 1 reply; 8+ messages in thread
From: Lorenzo Bianconi @ 2019-03-06 10:09 UTC (permalink / raw)
  To: Stanislaw Gruszka
  Cc: Xose Vazquez Perez, Felix Fietkau, Lorenzo Bianconi,
	linux-wireless, Jakub Kicinski

>
> On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:
> > There a three duplicate devices at:
> >
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */
> One duplicated entry should be removed.
>
> > mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> > mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },

IIUC this is not in the mt7601u driver available on mtk website.
@Jakub: should we remove it from mt7601u driver?

> Not sure about this.
>
> > mt76/mt76x0/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax / Elecom  */
> > mt76/mt76x2/usb.c:      { USB_DEVICE(0x7392, 0xb711) }, /* Edimax EW 7722 UAC */
> According to wikidevi we really have duplicated IDs:
>
> https://wikidevi.com/wiki/Edimax_EW-7722UAC
> https://wikidevi.com/wiki/Elecom_WDC-433SU2M
>
> I think we can handle this by checking ASIC version from the EEPROM
> or registers at the beginning of probe and exit if it does not mach.
> This should assure we will load proper driver.
>
> Stanislaw



-- 
UNIX is Sexy: who | grep -i blonde | talk; cd ~; wine; talk; touch;
unzip; touch; strip; gasp; finger; gasp; mount; fsck; more; yes; gasp;
umount; make clean; sleep

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

* Re: mediatek: duplicate usb devices
  2019-03-06 10:09   ` Lorenzo Bianconi
@ 2019-03-06 11:03     ` Stanislaw Gruszka
  2019-03-06 18:42       ` Jakub Kicinski
  0 siblings, 1 reply; 8+ messages in thread
From: Stanislaw Gruszka @ 2019-03-06 11:03 UTC (permalink / raw)
  To: Lorenzo Bianconi
  Cc: Xose Vazquez Perez, Felix Fietkau, Lorenzo Bianconi,
	linux-wireless, Jakub Kicinski, Hans Ulli Kroll

On Wed, Mar 06, 2019 at 11:09:12AM +0100, Lorenzo Bianconi wrote:
> >
> > On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:
> > > There a three duplicate devices at:
> > >
> > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */
> > One duplicated entry should be removed.
> >
> > > mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> > > mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },
> 
> IIUC this is not in the mt7601u driver available on mtk website.

The same apply to mt7610u. Vendor driver have only IDs for some
reference devices. Both mt7601u and mt7610u drivers do not include
0x7610.

For mt76x0u ids were provided by Hans 
https://lore.kernel.org/linux-wireless/alpine.LNX.2.00.1804092042320.8369@T420s/
I'm not sure where they came from.

Stanislaw


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

* Re: mediatek: duplicate usb devices
  2019-03-06 11:03     ` Stanislaw Gruszka
@ 2019-03-06 18:42       ` Jakub Kicinski
  2019-03-07 10:21         ` Stanislaw Gruszka
  0 siblings, 1 reply; 8+ messages in thread
From: Jakub Kicinski @ 2019-03-06 18:42 UTC (permalink / raw)
  To: Stanislaw Gruszka
  Cc: Lorenzo Bianconi, Xose Vazquez Perez, Felix Fietkau,
	Lorenzo Bianconi, linux-wireless, Hans Ulli Kroll

On Wed, 6 Mar 2019 12:03:30 +0100, Stanislaw Gruszka wrote:
> On Wed, Mar 06, 2019 at 11:09:12AM +0100, Lorenzo Bianconi wrote:
> > >
> > > On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:  
> > > > There a three duplicate devices at:
> > > >
> > > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> > > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */  
> > > One duplicated entry should be removed.
> > >  
> > > > mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> > > > mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },  
> > 
> > IIUC this is not in the mt7601u driver available on mtk website.  
> 
> The same apply to mt7610u. Vendor driver have only IDs for some
> reference devices. Both mt7601u and mt7610u drivers do not include
> 0x7610.
> 
> For mt76x0u ids were provided by Hans 
> https://lore.kernel.org/linux-wireless/alpine.LNX.2.00.1804092042320.8369@T420s/
> I'm not sure where they came from.

The ones in mt7601u came from Xose, the GitHub repo has fuller history:

https://github.com/kuba-moo/mt7601u/commit/5e6b565301d9882aab9af46b396a5cf489db6c78

I don't really mind which one stays :)

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

* Re: mediatek: duplicate usb devices
  2019-03-06 18:42       ` Jakub Kicinski
@ 2019-03-07 10:21         ` Stanislaw Gruszka
  0 siblings, 0 replies; 8+ messages in thread
From: Stanislaw Gruszka @ 2019-03-07 10:21 UTC (permalink / raw)
  To: Jakub Kicinski
  Cc: Lorenzo Bianconi, Xose Vazquez Perez, Felix Fietkau,
	Lorenzo Bianconi, linux-wireless, Hans Ulli Kroll

On Wed, Mar 06, 2019 at 10:42:40AM -0800, Jakub Kicinski wrote:
> On Wed, 6 Mar 2019 12:03:30 +0100, Stanislaw Gruszka wrote:
> > On Wed, Mar 06, 2019 at 11:09:12AM +0100, Lorenzo Bianconi wrote:
> > > >
> > > > On Tue, Mar 05, 2019 at 07:33:51PM +0100, Xose Vazquez Perez wrote:  
> > > > > There a three duplicate devices at:
> > > > >
> > > > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Alfa AWUS036ACM */
> > > > > mt76/mt76x2/usb.c:      { USB_DEVICE(0x0e8d, 0x7612) }, /* Aukey USB-AC1200 */  
> > > > One duplicated entry should be removed.
> > > >  
> > > > > mt76/mt76x0/usb.c:      { USB_DEVICE(0x148f, 0x760a) }, /* TP-Link unknown */
> > > > > mt7601u/usb.c:          { USB_DEVICE(0x148f, 0x760a) },  
> > > 
> > > IIUC this is not in the mt7601u driver available on mtk website.  
> > 
> > The same apply to mt7610u. Vendor driver have only IDs for some
> > reference devices. Both mt7601u and mt7610u drivers do not include
> > 0x7610.
> > 
> > For mt76x0u ids were provided by Hans 
> > https://lore.kernel.org/linux-wireless/alpine.LNX.2.00.1804092042320.8369@T420s/
> > I'm not sure where they came from.
> 
> The ones in mt7601u came from Xose, the GitHub repo has fuller history:
> 
> https://github.com/kuba-moo/mt7601u/commit/5e6b565301d9882aab9af46b396a5cf489db6c78
> 
> I don't really mind which one stays :)

I think this is same case as with duplicated id's for mt76x0u and
mt76x2u. We should not remove the IDs. I will just post patches that
will check chip version. 

Stanislaw
 

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

end of thread, other threads:[~2019-03-07 10:21 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-05 18:33 mediatek: duplicate usb devices Xose Vazquez Perez
2019-03-06  5:14 ` Kalle Valo
2019-03-06  7:50 ` Stanislaw Gruszka
2019-03-06  9:16   ` Lorenzo Bianconi
2019-03-06 10:09   ` Lorenzo Bianconi
2019-03-06 11:03     ` Stanislaw Gruszka
2019-03-06 18:42       ` Jakub Kicinski
2019-03-07 10:21         ` Stanislaw Gruszka

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.