mirror of
https://github.com/hak5/wifipineapple-openwrt.git
synced 2025-10-29 16:57:19 +00:00
[package] iwinfo: factor txpower offset into info display output, recompile if driver selection changes
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@29634 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@@ -391,9 +391,14 @@ static char * print_frequency(const struct iwinfo_ops *iw, const char *ifname)
|
||||
|
||||
static char * print_txpower(const struct iwinfo_ops *iw, const char *ifname)
|
||||
{
|
||||
int pwr;
|
||||
int pwr, off;
|
||||
if (iw->txpower_offset(ifname, &off))
|
||||
off = 0;
|
||||
|
||||
if (iw->txpower(ifname, &pwr))
|
||||
pwr = -1;
|
||||
else
|
||||
pwr += off;
|
||||
|
||||
return format_txpower(pwr);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user