From patchwork Sun Mar 28 11:55:00 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 88763 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 o2SBtitj004652 for ; Sun, 28 Mar 2010 11:55:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754209Ab0C1LzP (ORCPT ); Sun, 28 Mar 2010 07:55:15 -0400 Received: from mail-bw0-f209.google.com ([209.85.218.209]:59450 "EHLO mail-bw0-f209.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754026Ab0C1LzM (ORCPT ); Sun, 28 Mar 2010 07:55:12 -0400 Received: by bwz1 with SMTP id 1so2886056bwz.21 for ; Sun, 28 Mar 2010 04:55:10 -0700 (PDT) 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=iZYmHrD9Fv/pTAfJd27VpzcrMS28Bp4SXKZvw+YUXLY=; b=HHJGd0Fqiov++WyzRR2bx2CrZLeEFVW+7Q74pRXSCu8eKT8j7HVcWTAAaWF3U+gaSx T78ONe0VTWu3P7ljcDO6ZB7EgNkF8PClVmMlyXG/tttEvlsTXInvnCZgRLGM9vCbNLVO RoydtYVNZN0xs9IeJjrIogRx2CnNZjWtQTV0w= 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=SiVn9lyMqM7GpHpRLVslYgiP+soOvUlB6wlHATwn4G4gNdOWq3L3QgsExwMynUC7HN GO4UYvwkpIl75ZmbOqCL0kVLiW17+knvLclPBqc21hIv/a9ajXcxnhvp7+MewDPHKyPU uGQdBylWWkytlrAZEOc7+jM4MxktdW8XRVEX0= Received: by 10.204.6.212 with SMTP id a20mr5169025bka.22.1269777310141; Sun, 28 Mar 2010 04:55:10 -0700 (PDT) Received: from bicker ([196.43.68.183]) by mx.google.com with ESMTPS id x16sm27407111bku.11.2010.03.28.04.55.05 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 28 Mar 2010 04:55:09 -0700 (PDT) Date: Sun, 28 Mar 2010 14:55:00 +0300 From: Dan Carpenter To: Zhu Yi Cc: Reinette Chatre , Intel Linux Wireless , "John W. Linville" , Abhijeet Kolekar , Johannes Berg , Wey-Yi Guy , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] iwlwifi: range checking issue Message-ID: <20100328115500.GX5069@bicker> Mail-Followup-To: Dan Carpenter , Zhu Yi , Reinette Chatre , Intel Linux Wireless , "John W. Linville" , Abhijeet Kolekar , Johannes Berg , Wey-Yi Guy , 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]); Sun, 28 Mar 2010 11:55:45 +0000 (UTC) diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 54daa38..7d3806a 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c @@ -1955,7 +1955,7 @@ static void iwl3945_init_hw_rates(struct iwl_priv *priv, { int i; - for (i = 0; i < IWL_RATE_COUNT; i++) { + for (i = 0; i < IWL_RATE_COUNT_LEGACY; i++) { rates[i].bitrate = iwl3945_rates[i].ieee * 5; rates[i].hw_value = i; /* Rate scaling will work on indexes */ rates[i].hw_value_short = i;