From: Marcel Holtmann <marcel@holtmann.org>
To: "Luis R. Rodriguez" <lrodriguez@atheros.com>
Cc: linux-wireless@vger.kernel.org, jal2@gmx.de,
Peter.Grabienski@Atheros.com, Stephen.Chen@Atheros.com,
Michael.Fortin@Atheros.com, Johnny.Cheng@Atheros.com,
Yuan-Gu.Wei@atheros.com, otus-devel@lists.madwifi-project.org
Subject: Re: [RFT 2/2] ar9170: add AVM FRITZ devices
Date: Thu, 28 May 2009 09:17:51 +0200 [thread overview]
Message-ID: <1243495071.16631.4.camel@localhost.localdomain> (raw)
In-Reply-To: <1243475326-28867-3-git-send-email-lrodriguez@atheros.com>
Hi Luis,
> This adds:
>
> USB 0x057C:0x8401 AVM FRITZ!WLAN USB Stick N
> USB 0x057C:0x8402 AVM FRITZ!WLAN USB Stick N 2.4
>
> These devices require the 1-stage firmware, if not present we
> don't continue.
>
> Cc: Peter Grabienski <Peter.Grabienski@Atheros.com>
> Cc: Stephen Chen <Stephen.Chen@Atheros.com>
> Cc: Michael Fortin <Michael.Fortin@Atheros.com>
> Cc: Johnny Cheng <Johnny.Cheng@Atheros.com>
> Cc: Yuan-Gu Wei <Yuan-Gu.Wei@atheros.com>
> Cc: Joerg Albert <jal2@gmx.de>
> Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
> ---
> drivers/net/wireless/ath/ar9170/usb.c | 28 ++++++++++++++++++++++++++++
> drivers/net/wireless/ath/ar9170/usb.h | 2 ++
> 2 files changed, 30 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ar9170/usb.c b/drivers/net/wireless/ath/ar9170/usb.c
> index 3c97c09..45b5291 100644
> --- a/drivers/net/wireless/ath/ar9170/usb.c
> +++ b/drivers/net/wireless/ath/ar9170/usb.c
> @@ -82,6 +82,10 @@ static struct usb_device_id ar9170_usb_ids[] = {
> { USB_DEVICE(0x2019, 0x5304) },
> /* IO-Data WNGDNUS2 */
> { USB_DEVICE(0x04bb, 0x093f) },
> + /* AVM FRITZ!WLAN USB Stick N */
> + { USB_DEVICE(0x057C, 0x8401) },
> + /* AVM FRITZ!WLAN USB Stick N 2.4 */
> + { USB_DEVICE(0x057C, 0x8402) },
>
> /* terminate */
> {}
> @@ -512,6 +516,12 @@ static int ar9170_usb_request_firmware(struct ar9170_usb *aru)
> return 0;
> }
>
> + if (aru->req_one_stage_fw) {
> + dev_err(&aru->udev->dev, "ar9170.fw firmware file "
> + "not found and is required for this device\n");
> + return -EINVAL;
> + }
> +
> dev_err(&aru->udev->dev, "ar9170.fw firmware file "
> "not found, trying old firmware...\n");
>
> @@ -668,6 +678,22 @@ err_out:
> return err;
> }
>
> +static bool ar9170_requires_one_stage(const struct usb_device_id *id)
> +{
> + /* AVM FRITZ only */
> + if (id->idVendor != 0x057C)
> + return false;
> +
> + switch (id->idProduct) {
> + case 0x8401: /* AVM FRITZ!WLAN USB Stick N */
> + case 0x8402: /* AVM FRITZ!WLAN USB Stick N 2.4 */
> + return true;
> + default:
> + return false;
> + }
> + return false;
> +}
> +
can't you make this part of use_device_id table? Syncing up with product
ids in two places is not a good idea.
Regards
Marcel
next prev parent reply other threads:[~2009-05-28 7:18 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-28 1:48 [RFT 0/2] ar9170: initial stage 1 firmware support / AVM fritz Luis R. Rodriguez
2009-05-28 1:48 ` [RFT 1/2] ar9170: add initial support for 1-stage firmware Luis R. Rodriguez
2009-05-28 16:03 ` Christian Lamparter
2009-05-28 19:26 ` Luis R. Rodriguez
2009-05-28 21:16 ` [otus-devel] " Luis R. Rodriguez
2009-05-28 1:48 ` [RFT 2/2] ar9170: add AVM FRITZ devices Luis R. Rodriguez
2009-05-28 7:17 ` Marcel Holtmann [this message]
2009-05-28 15:22 ` Pavel Roskin
2009-05-28 19:29 ` Luis R. Rodriguez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1243495071.16631.4.camel@localhost.localdomain \
--to=marcel@holtmann.org \
--cc=Johnny.Cheng@Atheros.com \
--cc=Michael.Fortin@Atheros.com \
--cc=Peter.Grabienski@Atheros.com \
--cc=Stephen.Chen@Atheros.com \
--cc=Yuan-Gu.Wei@atheros.com \
--cc=jal2@gmx.de \
--cc=linux-wireless@vger.kernel.org \
--cc=lrodriguez@atheros.com \
--cc=otus-devel@lists.madwifi-project.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.