Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Revert "iw: Add antenna configuration commands"

This reverts commit 024630b.

Depended on fucked up stuff.
  • Loading branch information...
commit febdd8756141e23c2f023d45abb8830004ffb686 1 parent 90afd50
@jmberg jmberg authored
Showing with 0 additions and 46 deletions.
  1. +0 −7 info.c
  2. +0 −39 phy.c
View
7 info.c
@@ -168,13 +168,6 @@ static int print_phy_handler(struct nl_msg *msg, void *arg)
printf("\tCoverage class: %d (up to %dm)\n", coverage, 450 * coverage);
}
- if (tb_msg[NL80211_ATTR_WIPHY_ANTENNA_TX] &&
- tb_msg[NL80211_ATTR_WIPHY_ANTENNA_RX]) {
- printf("\tAntenna: TX %#x RX %#x\n",
- nla_get_u32(tb_msg[NL80211_ATTR_WIPHY_ANTENNA_TX]),
- nla_get_u32(tb_msg[NL80211_ATTR_WIPHY_ANTENNA_RX]));
- }
-
if (tb_msg[NL80211_ATTR_SUPPORTED_IFTYPES]) {
printf("\tSupported interface modes:\n");
nla_for_each_nested(nl_mode, tb_msg[NL80211_ATTR_SUPPORTED_IFTYPES], rem_mode)
View
39 phy.c
@@ -307,42 +307,3 @@ COMMAND(set, txpower, "<auto|fixed|limit> [<tx power in mBm>]",
COMMAND(set, txpower, "<auto|fixed|limit> [<tx power in mBm>]",
NL80211_CMD_SET_WIPHY, 0, CIB_NETDEV, handle_txpower,
"Specify transmit power level and setting type.");
-
-static int handle_antenna(struct nl80211_state *state,
- struct nl_cb *cb,
- struct nl_msg *msg,
- int argc, char **argv)
-{
- char *end;
- uint32_t tx_ant = 0, rx_ant = 0;
-
- if (argc == 1 && strcmp(argv[0], "all") == 0) {
- tx_ant = 0xffffffff;
- rx_ant = 0xffffffff;
- } else if (argc == 1) {
- tx_ant = rx_ant = strtoul(argv[0], &end, 0);
- if (*end)
- return 1;
- }
- else if (argc == 2) {
- tx_ant = strtoul(argv[0], &end, 0);
- if (*end)
- return 1;
- rx_ant = strtoul(argv[1], &end, 0);
- if (*end)
- return 1;
- } else
- return 1;
-
- NLA_PUT_U32(msg, NL80211_ATTR_WIPHY_ANTENNA_TX, tx_ant);
- NLA_PUT_U32(msg, NL80211_ATTR_WIPHY_ANTENNA_RX, rx_ant);
-
- return 0;
-
- nla_put_failure:
- return -ENOBUFS;
-}
-COMMAND(set, antenna, "<bitmap> | all | <tx bitmap> <rx bitmap>",
- NL80211_CMD_SET_WIPHY, 0, CIB_PHY, handle_antenna,
- "Set a bitmap of allowed antennas to use for TX and RX.\n"
- "The driver may reject antenna configurations it cannot support.");
Please sign in to comment.
Something went wrong with that request. Please try again.