summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ipw2x00/ipw2100.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-08-06 13:30:43 -0700
committerDavid S. Miller <davem@davemloft.net>2010-08-06 13:30:43 -0700
commite225567960db50e9810a152c8621c7a6ed94de71 (patch)
treed0129e2988f8aea56d4f00f04c4818c2e8cc07a2 /drivers/net/wireless/ipw2x00/ipw2100.c
parent4b030d4288a569d6bdeca884d7f102d951f097f2 (diff)
parenta24d52f390a77ce90dc8cf0cd75d27ec0a6ea3f8 (diff)
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
Diffstat (limited to 'drivers/net/wireless/ipw2x00/ipw2100.c')
-rw-r--r--drivers/net/wireless/ipw2x00/ipw2100.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wireless/ipw2x00/ipw2100.c
index c24c5efeae1..16bbfa3189a 100644
--- a/drivers/net/wireless/ipw2x00/ipw2100.c
+++ b/drivers/net/wireless/ipw2x00/ipw2100.c
@@ -1924,6 +1924,10 @@ static int ipw2100_net_init(struct net_device *dev)
bg_band->channels =
kzalloc(geo->bg_channels *
sizeof(struct ieee80211_channel), GFP_KERNEL);
+ if (!bg_band->channels) {
+ ipw2100_down(priv);
+ return -ENOMEM;
+ }
/* translate geo->bg to bg_band.channels */
for (i = 0; i < geo->bg_channels; i++) {
bg_band->channels[i].band = IEEE80211_BAND_2GHZ;