diff options
author | Joe Perches <joe@perches.com> | 2013-02-03 12:28:14 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-02-04 13:22:34 -0500 |
commit | 0d2e7a5c608063f72048899d20505c2ee130566c (patch) | |
tree | 4eae4acaf7c04bb60337389aaef8065c00b1737a /drivers/net/wireless/libertas | |
parent | 9d11bd1592fba0b9231d3ce8ab61977db7e03e27 (diff) |
wireless: Remove unnecessary alloc/OOM messages, alloc cleanups
alloc failures already get standardized OOM
messages and a dump_stack.
Convert kzalloc's with multiplies to kcalloc.
Convert kmalloc's with multiplies to kmalloc_array.
Remove now unused variables.
Remove unnecessary memset after kzalloc->kcalloc.
Whitespace cleanups for these changes.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wireless/libertas')
-rw-r--r-- | drivers/net/wireless/libertas/cfg.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/wireless/libertas/cfg.c b/drivers/net/wireless/libertas/cfg.c index 230f8ebbe289..a7dcb2e5eccc 100644 --- a/drivers/net/wireless/libertas/cfg.c +++ b/drivers/net/wireless/libertas/cfg.c | |||
@@ -2081,10 +2081,8 @@ struct wireless_dev *lbs_cfg_alloc(struct device *dev) | |||
2081 | lbs_deb_enter(LBS_DEB_CFG80211); | 2081 | lbs_deb_enter(LBS_DEB_CFG80211); |
2082 | 2082 | ||
2083 | wdev = kzalloc(sizeof(struct wireless_dev), GFP_KERNEL); | 2083 | wdev = kzalloc(sizeof(struct wireless_dev), GFP_KERNEL); |
2084 | if (!wdev) { | 2084 | if (!wdev) |
2085 | dev_err(dev, "cannot allocate wireless device\n"); | ||
2086 | return ERR_PTR(-ENOMEM); | 2085 | return ERR_PTR(-ENOMEM); |
2087 | } | ||
2088 | 2086 | ||
2089 | wdev->wiphy = wiphy_new(&lbs_cfg80211_ops, sizeof(struct lbs_private)); | 2087 | wdev->wiphy = wiphy_new(&lbs_cfg80211_ops, sizeof(struct lbs_private)); |
2090 | if (!wdev->wiphy) { | 2088 | if (!wdev->wiphy) { |