Best thing to do is look at the code that disables ACK in the TX descriptor and set that.
There's also the DIAG register, as mentioned. For ath9k: reg.h:#define AR_DIAG_SW 0x8048 reg.h:#define AR_DIAG_ACK_DIS 0x00000002 Find where AR_DIAG_SW is set in the ath9k code (it's fiddled with in a few places) and call the REG_SET_BIT() appropriately. Do the same for ath5k once you find the right register/field definition. HTH, Adrian On 9 June 2011 15:03, Liang <leonc...@gmail.com> wrote: > Hi Adrian, > Thank you. May I ask how to set these registers to disable the ACK in the > ath5k/ath9k driver? > Best, > Leon > > On Thu, Jun 9, 2011 at 2:32 PM, Adrian Chadd <adr...@freebsd.org> wrote: >> >> No, retry doesn't stop ack's, it just stops the hardware from retrying >> a packet if it hasn't heard an ACK. >> >> You can fiddle with the diag register, or you can just ensure that the >> relevant bit in the TX descriptor isn't set. >> >> fgrep NOACK ath9k/*.h >> mac.h:#define ATH9K_TXDESC_NOACK 0x0002 >> >> fgrep NOACK ath5k/*.h >> >> fgrep NOACK *h >> desc.h:#define AR5K_2W_TX_DESC_CTL1_NOACK_5211 0x00800000 /* >> [5211] no ACK */ >> desc.h:#define AR5K_4W_TX_DESC_CTL1_NOACK 0x01000000 /* no >> ACK */ >> desc.h:#define AR5K_TXDESC_NOACK 0x0002 /*[5211+]*/ >> >> There's likely some API you can use at a higher level to signify to >> the TX code that no, you don't want an ACK for the packet. >> >> Eg, look at ath9k/setup_tx_flags(): >> >> struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb); >> ... >> if (tx_info->flags & IEEE80211_TX_CTL_NO_ACK) >> flags |= ATH9K_TXDESC_NOACK; >> >> HTH, >> >> >> Adrian >> >> On 9 June 2011 13:55, Liang <leonc...@gmail.com> wrote: >> > Hi, >> > I want to know if the ACK at 802.11 MAC layer can be turned off in the >> > ath5k/ath9k, and how can it be done? >> > On the other hand, does the command "iwconfig wlan0 retry 0" disable the >> > MAC >> > retransmission? Is it the same to turnoff the ACK? >> > Thank you! >> > Best, >> > Leon >> > _______________________________________________ >> > ath5k-devel mailing list >> > ath5k-devel@lists.ath5k.org >> > https://lists.ath5k.org/mailman/listinfo/ath5k-devel >> > >> > > > _______________________________________________ ath5k-devel mailing list ath5k-devel@lists.ath5k.org https://lists.ath5k.org/mailman/listinfo/ath5k-devel