From patchwork Tue Nov 3 22:34:40 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 57390 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nA3MajJ8014546 for ; Tue, 3 Nov 2009 22:36:46 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754954AbZKCWgB (ORCPT ); Tue, 3 Nov 2009 17:36:01 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754409AbZKCWfu (ORCPT ); Tue, 3 Nov 2009 17:35:50 -0500 Received: from mail-ew0-f207.google.com ([209.85.219.207]:53862 "EHLO mail-ew0-f207.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753164AbZKCWfs (ORCPT ); Tue, 3 Nov 2009 17:35:48 -0500 Received: by ewy3 with SMTP id 3so2513941ewy.37 for ; Tue, 03 Nov 2009 14:35:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:message-id :content-type:content-transfer-encoding; bh=+YJ2zIe3Aw8iE6MRVVEhhG10FzJVWAyBFqxAYKq62Wo=; b=ai0dDVc3CLuWt4lKNUad//eX9K94xvWwTRBkiylZzUycPZ0i2cbNFnVzvoQHLvfO6J lUzzzcxIVjRfUJbms25yba98+dZq8uNE81zUpZH6xIWeqNJEFb8hWb0qun0d/33wnz28 ANNVa1VEXB8z02eX0+oOLOTam/JHK7G2Q+Q80= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:message-id:content-type:content-transfer-encoding; b=vEI1yMKz8unvd21d9CcU9WYE0sp9tJJwLstd2AVB5I7cH4QqGqknvnFyhmnqNj8SFl 2thoyJ2B/ysV5dpj0xmjI/boAxreR/nl1ciDMeSFIlRbW4obp9pDo2/zN4iHtWYpQb67 zYsM2gzidrrBYGBIZaD9F6a6c8zX9+/+eUk+g= Received: by 10.213.96.65 with SMTP id g1mr292486ebn.44.1257287752536; Tue, 03 Nov 2009 14:35:52 -0800 (PST) Received: from szaki.localnet (chello089079027028.chello.pl [89.79.27.28]) by mx.google.com with ESMTPS id 7sm1585585eyg.17.2009.11.03.14.35.51 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 03 Nov 2009 14:35:51 -0800 (PST) From: Bartlomiej Zolnierkiewicz To: Ivo van Doorn Subject: Re: [announce] new rt2800 drivers for Ralink wireless & project tree Date: Tue, 3 Nov 2009 23:34:40 +0100 User-Agent: KMail/1.12.2 (Linux/2.6.31.5-96.fc12.x86_64; KDE/4.3.2; x86_64; ; ) Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Randy Dunlap , Luis Correia , "John W. Linville" , Ingo Molnar , Johannes Berg , Jarek Poplawski , Pekka Enberg , David Miller References: <200911031951.05235.bzolnier@gmail.com> <200911032244.11946.bzolnier@gmail.com> <200911032301.32907.IvDoorn@gmail.com> In-Reply-To: <200911032301.32907.IvDoorn@gmail.com> MIME-Version: 1.0 Message-Id: <200911032334.40547.bzolnier@gmail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Index: b/drivers/net/wireless/rt2x00/rt2x00.h =================================================================== --- a/drivers/net/wireless/rt2x00/rt2x00.h +++ b/drivers/net/wireless/rt2x00/rt2x00.h @@ -144,6 +144,11 @@ struct avg_val { int avg_weight; }; +enum rt2x00_chip_intf { + RT2X00_CHIP_INTF_PCI, + RT2X00_CHIP_INTF_USB, +}; + /* * Chipset identification * The chipset on the device is composed of a RT and RF chip. @@ -169,6 +174,8 @@ struct rt2x00_chip { u16 rf; u32 rev; + + enum rt2x00_chip_intf intf; }; /* @@ -937,6 +944,18 @@ static inline bool rt2x00_check_rev(cons return ((chipset->rev & mask) == rev); } +static inline void rt2x00_set_chip_intf(struct rt2x00_dev *rt2x00dev, + enum rt2x00_chip_intf intf) +{ + rt2x00dev->chip.intf = intf; +} + +static inline bool rt2x00_intf(const struct rt2x00_chip *chipset, + enum rt2x00_chip_intf intf) +{ + return (chipset->intf == intf); +} + /** * rt2x00queue_map_txskb - Map a skb into DMA for TX purposes. * @rt2x00dev: Pointer to &struct rt2x00_dev.