From: Michael Wu <flamingice@sourmilk.net>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Jiri Benc <jbenc@suse.cz>,
Bcm43xx-dev@lists.berlios.de, linux-wireless@vger.kernel.org
Subject: Re: [PATCH] mac80211: Add support for SIOCGIWRATE ioctl to provide rate information
Date: Wed, 2 May 2007 10:31:32 -0400 [thread overview]
Message-ID: <200705021031.40728.flamingice@sourmilk.net> (raw)
In-Reply-To: <46389ff5.oRExYGz42A2aZRmj%Larry.Finger@lwfinger.net>
[-- Attachment #1: Type: text/plain, Size: 618 bytes --]
On Wednesday 02 May 2007 10:28, Larry Finger wrote:
> +static int ieee80211_ioctl_giwrate(struct net_device *dev,
> + struct iw_request_info *info,
> + struct iw_param *rate, char *extra)
> +{
> + struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
> + struct sta_info * sta;
> + struct ieee80211_sub_if_data * sdata;
> +
> + sdata = IEEE80211_DEV_TO_SUB_IF(dev);
> + sta = sta_info_get(local, sdata->u.sta.bssid);
> + if (!sta)
> + return -ENODEV;
> + rate->value = local->oper_hw_mode->rates[sta->txrate].rate * 100000;
> + return 0;
> +}
> +
Memory leak. You need a sta_info_put.
-Michael Wu
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2007-05-02 14:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-02 14:28 [PATCH] mac80211: Add support for SIOCGIWRATE ioctl to provide rate information Larry Finger
2007-05-02 14:31 ` Michael Wu [this message]
[not found] <20070610.181704.73383002.davem@davemloft.net>
2007-06-12 1:22 ` mac80211 patches for 2.6.23 John W. Linville
2007-06-12 1:23 ` [PATCH] mac80211: Add support for SIOCGIWRATE ioctl to provide rate information John W. Linville
2007-07-03 5:38 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200705021031.40728.flamingice@sourmilk.net \
--to=flamingice@sourmilk.net \
--cc=Bcm43xx-dev@lists.berlios.de \
--cc=Larry.Finger@lwfinger.net \
--cc=jbenc@suse.cz \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).