Source file rc.c for ath9k rate control disappear after linux kernel version 2.6.30

I'm interested in how the Wi-Fi driver ath9k rate control operates, so I went to source and check it out.

A wierd thing is, the rate control source file rc.c is open in the source tree before linux kernel version 2.6.30. But after that version, I cannot find that file no more. It seems they move the code down to hardware.

I don't know if anyone had this observation and feel interested in that, just raise this question here.

I am curious why do they stop opening this file, any discuss is welcome.

If that kernel isn’t so ancient as to be before git, check the commit.


commit 203c4805e917
Author: Luis R. Rodriguez <>
Date:   Mon Mar 30 22:30:33 2009 -0400

    atheros: put atheros wireless drivers into ath/
 git diff --name-status 203c4805e917^ 203c4805e917

seems pretty clear as to why it "disappeared" after 2.6.29

1 Like

Sorry that I don't quite understand.

Do you mean it's because they move the file into ath/? But I was under the ath/ folder, and all the other files can be found except the file rc.c.

Could you please explain more? I am actually not that sophiscated in this area. Thanks a lot.

It was removed from Linux in February 2014.
"ath9k: Remove ath9k rate control"

They apparently moved it in 2009 to a new location, to which act jeff referenced above, but then 5 years later (and 5 years ago) they removed it totally...


Many thanks. But then I have another problem.

It seems the minstrel is actually not the current default rate control algorithm for ath9k. Given the fact that the original ath9k rate control is removed, then what is the current rate control scheme that ath9k use by default?

Any clue on that?

root@OpenWrt:~# iw phy0 info | grep TXQS
		* [ TXQS ]: FQ-CoDel-enabled intermediate TXQs

Thanks. But I think this CoDel scheme targets on the problem of packet queueing and buffering, which is not that related the rate adaptation scheme.

By rate adaptation, I'm talking about the rate selection for each Wi-Fi frame when conduct transmission. When a Wi-Fi frame is sent into the wireless channel, the driver decides the optimal data rate that makes full use of the channel capacity.

1 Like

OK, cool.

Did you read about it on the Wiki page you posted?

As ath9k uses the mac80211 framework, doesn't it then use minstrel?

Yes I read it. That describes some general concepts on rate adaptation, but cannot answer my question about the rate selection scheme of ath9k on my router.

1 Like

I need to manually switch from the default rate selection scheme to minstrel. I think it doesn't use minstrel by default.

Which exact OpenWrt version you are currently using?

1 Like

It seems I'm using OpenWrt SNAPSHOT. As shown here:

root@OpenWrt:~# cat /etc/os-release
ID_LIKE="lede openwrt"
LEDE_RELEASE="OpenWrt SNAPSHOT r0-a783018"

To my knowledge there has never been a commit "a783018", so you are likely using somebody's private version, modified somehow.


Yes, it does use minstrel (or more exactly, minstrel_ht).