X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/c02a9bd7aaf1e6fbfa829ec2e1b66cefce3268c5..a46cfc6bccf2343230f701e86fa88be1404ca1ce:/package/iwinfo/src/iwinfo_wl.c diff --git a/package/iwinfo/src/iwinfo_wl.c b/package/iwinfo/src/iwinfo_wl.c index 76984de33..7b39a9b86 100644 --- a/package/iwinfo/src/iwinfo_wl.c +++ b/package/iwinfo/src/iwinfo_wl.c @@ -585,3 +585,28 @@ int wl_get_hardware_name(const char *ifname, char *buf) return 0; } + +int wl_get_txpower_offset(const char *ifname, int *buf) +{ + FILE *p; + char off[8]; + + *buf = 0; + + if ((p = popen("/usr/sbin/nvram get opo", "r")) != NULL) + { + if (fread(off, 1, sizeof(off), p)) + *buf = strtoul(off, NULL, 16); + + pclose(p); + } + + return 0; +} + +int wl_get_frequency_offset(const char *ifname, int *buf) +{ + /* Stub */ + *buf = 0; + return -1; +}