| 61 | | /* Call private ioctl "rfmontx" to enable raw TX */ |
| 62 | | if (iwconfig_set_intpriv(in_tx->ifname, "rfmontx", 1, 0, errstr) != 0) { |
| 63 | | snprintf(in_tx->errstr, TX80211_STATUS_MAX, |
| 64 | | "Error enabling rfmontx private ioctl: %s\n", |
| 65 | | errstr); |
| 66 | | return -1; |
| 67 | | } |
| | 59 | /* Call rfmontx to enable raw tx. |
| | 60 | * Some drivers prefer set_intpriv, others charpriv. Try both. |
| | 61 | */ |
| 69 | | return(wtinj_open(in_tx)); |
| | 63 | if (iwconfig_set_charpriv(in_tx->ifname, "rfmontx", "1", errstr) >= 0) |
| | 64 | return(wtinj_open(in_tx)); |
| | 65 | |
| | 66 | if (iwconfig_set_intpriv(in_tx->ifname, "rfmontx", 1, 0, errstr) >= 0) |
| | 67 | return(wtinj_open(in_tx)); |
| | 68 | |
| | 69 | /* If we reach this point, failed to enable rfmontx */ |
| | 70 | |
| | 71 | fprintf(stderr, "Error enabling rfmontx private ioctl: %s\n", errstr); |
| | 72 | return -1; |