Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 108834
b: refs/heads/master
c: 69bbc7d
h: refs/heads/master
v: v3
  • Loading branch information
Christian Lamparter authored and John W. Linville committed Aug 18, 2008
1 parent 7c8b3d5 commit 179c24c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6f14792610905fe006c0c3c4d9e1478fb6be7cec
refs/heads/master: 69bbc7dc9f59fedb6067c7f9f9f9bc1da27407ad
20 changes: 11 additions & 9 deletions trunk/drivers/net/wireless/p54/p54common.c
Original file line number Diff line number Diff line change
Expand Up @@ -837,10 +837,21 @@ static int p54_start(struct ieee80211_hw *dev)
struct p54_common *priv = dev->priv;
int err;

if (!priv->cached_vdcf) {
priv->cached_vdcf = kzalloc(sizeof(struct p54_tx_control_vdcf)+
priv->tx_hdr_len + sizeof(struct p54_control_hdr),
GFP_KERNEL);

if (!priv->cached_vdcf)
return -ENOMEM;
}

err = priv->open(dev);
if (!err)
priv->mode = IEEE80211_IF_TYPE_MNTR;

p54_init_vdcf(dev);

return err;
}

Expand Down Expand Up @@ -1020,15 +1031,6 @@ struct ieee80211_hw *p54_init_common(size_t priv_data_len)
dev->extra_tx_headroom = sizeof(struct p54_control_hdr) + 4 +
sizeof(struct p54_tx_control_allocdata);

priv->cached_vdcf = kzalloc(sizeof(struct p54_tx_control_vdcf) +
priv->tx_hdr_len + sizeof(struct p54_control_hdr), GFP_KERNEL);

if (!priv->cached_vdcf) {
ieee80211_free_hw(dev);
return NULL;
}

p54_init_vdcf(dev);
mutex_init(&priv->conf_mutex);

return dev;
Expand Down

0 comments on commit 179c24c

Please sign in to comment.