From patchwork Thu Feb 18 09:45:29 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 80232 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o1I9kSAe024298 for ; Thu, 18 Feb 2010 09:46:28 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754835Ab0BRJpw (ORCPT ); Thu, 18 Feb 2010 04:45:52 -0500 Received: from mail-fx0-f220.google.com ([209.85.220.220]:56854 "EHLO mail-fx0-f220.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753656Ab0BRJpt (ORCPT ); Thu, 18 Feb 2010 04:45:49 -0500 Received: by fxm20 with SMTP id 20so8777698fxm.21 for ; Thu, 18 Feb 2010 01:45:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:mail-followup-to:mime-version:content-type :content-disposition:user-agent; bh=MLc3Xqo67fKVpu1ADMfqQelYUDxbiaz+Xu9L1eHB9y8=; b=WaHjO3KnjEnjAwb0CP6gg4GQVkP4aQU3vwtyEzRjTU+7EboIOrbTAkqwQHhCDRs54A 824PZuhV3589yJrfUBBGYNCenQ6NrDxIZUTfaDhD98kD+H49QQfgdEvkJomnvfXt1N/B BgfjsmDi0wkBarrYXUZ2ViZ+DBkNajUOn8HnA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:mail-followup-to:mime-version :content-type:content-disposition:user-agent; b=gn2Mx+kRWv+sbQ3uukhUq93fxUZS/rZHVFTkPxlZorxjPx8HTjuxXlTXk+S+DHRme2 9aTL5LD5b3kaQMAE/RLFElSklA8V2WVtpCDP68BuZKni5Kb2gOYpooArB3gZ2O5RBsvX 6DqoPusSeEnknropsZUzQxlsjaAsxvHTAlDiU= Received: by 10.223.15.154 with SMTP id k26mr7115076faa.77.1266486345064; Thu, 18 Feb 2010 01:45:45 -0800 (PST) Received: from bicker (adsl-cl.utlonline.co.ug [196.0.7.1]) by mx.google.com with ESMTPS id 13sm4579655fxm.5.2010.02.18.01.45.39 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 18 Feb 2010 01:45:43 -0800 (PST) Date: Thu, 18 Feb 2010 12:45:29 +0300 From: Dan Carpenter To: Zhu Yi Cc: Reinette Chatre , Intel Linux Wireless , "John W. Linville" , Wey-Yi Guy , Abhijeet Kolekar , Johannes Berg , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] iwlwifi: testing the wrong variable Message-ID: <20100218094529.GA1298@bicker> Mail-Followup-To: Dan Carpenter , Zhu Yi , Reinette Chatre , Intel Linux Wireless , "John W. Linville" , Wey-Yi Guy , Abhijeet Kolekar , Johannes Berg , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 18 Feb 2010 09:46:29 +0000 (UTC) diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wireless/iwlwifi/iwl-5000.c index de45f30..b45150d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-5000.c +++ b/drivers/net/wireless/iwlwifi/iwl-5000.c @@ -781,7 +781,7 @@ void iwl5000_txq_update_byte_cnt_tbl(struct iwl_priv *priv, scd_bc_tbl[txq_id].tfd_offset[write_ptr] = bc_ent; - if (txq->q.write_ptr < TFD_QUEUE_SIZE_BC_DUP) + if (write_ptr < TFD_QUEUE_SIZE_BC_DUP) scd_bc_tbl[txq_id]. tfd_offset[TFD_QUEUE_SIZE_MAX + write_ptr] = bc_ent; } @@ -803,7 +803,7 @@ void iwl5000_txq_inval_byte_cnt_tbl(struct iwl_priv *priv, bc_ent = cpu_to_le16(1 | (sta_id << 12)); scd_bc_tbl[txq_id].tfd_offset[read_ptr] = bc_ent; - if (txq->q.write_ptr < TFD_QUEUE_SIZE_BC_DUP) + if (read_ptr < TFD_QUEUE_SIZE_BC_DUP) scd_bc_tbl[txq_id]. tfd_offset[TFD_QUEUE_SIZE_MAX + read_ptr] = bc_ent; }