NOTE: this page is for archival only, see the note at the end of the page.

Go back –> Atheros Linux wireless drivers

ath9k_htc

ath9k_htc provides hardware support for all wireless Atheros AR9001 and AR9002 family hardware which uses the HTC framework for communication with an embedded target CPU.

Component modules

ath9k_htc alone only provides the mac80211 callbacks for 802.11n HTC devices. HTC devices use different transports, such as USB, SDIO. Each transport module claims their own device and registers it with ath_htc. We currently have three HTC related modules:

  • ath9k_htc - Atheros 9000 Hardware family support driver which require HTC

  • ath_htc - Atheros Host Target Communications module

  • ath_hif_usb - Atheros USB Host InterFace transport module

Device initialization

A transport module (ath_hif_usb) claims a USB vendor:device ID, it registers it to ath_htc and informs ath_htc of the hardware family that its vendor:device falls under. The ar9271 device falls under the AR9K hardware family. ath_htc then requests the mac80211 hardware family module to be loaded – this is ath9k_htc for ar9271. The mac80211 hardware family module, ath9k_htc for AR9K HTC family, then registers a set of operations to HTC for HIF devices under the same hardware family. HTC finally has a notion of the transport and hardware family that an HTC device falls under, it will use this for sending HTC messages to the transport and also relaying replies back the to mac80211 hardware family driver.

Mailing list

Since ar9271 support is not yet upstream and the driver is still being worked on we use the Linux driver project mailing list to track its development and patches:

http://driverdev.linuxdriverproject.org/mailman/listinfo/devel

Status

ar9271 support is still under development. Below you can keep track of its progress.

  • Monitor mode works
  • Scanning works

Next goals:

  • Write some initial TX code, ping!

Available devices

See the ath9k_htc device list.

Development

If you'd like to work on development for ar9271 get the code first:

git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/ath9k_htc.git

If you do not have hardware and are serious about working on a mac80211 driver for ar9271 please contact mcgrof@gmail.com, Atheros is looking to work with the community by providing hardware samples to interested developers. Prior to contacting mcgrof@gmail.com for a device though please consider sending patches to help with the existing code. The HTC/HIF code could use a lot of help to be more upstream-friendly first. You will need hardware once we start working on the mac80211 driver.

Setting up your environment

To work on this you'll need to git clone wireless-testing:

git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-testing.git

Configuring your kernel

You'll need to compile and install wireless-testing, before you do so be sure to enable these configuration options:

CONFIG_ATH_COMMON=m
CONFIG_ATH9K=m
CONFIG_ATH_DEBUG=y

ATH9K is not required but we require you to select it to enable ATH9K_HW for now as ATH9K_HTC is not yet an option upstream.

Boot into your new kernel and you can begin hacking.

Firmware

ar9271 requires firmware, you can get ar9271fw from:

http://www.kernel.org/pub/linux/kernel/people/mcgrof/firmware/ar9271/ar9271.fw
sha1sum 9ee744d58e68e531cb2ca910c3980e1f23985226

This firmware was built from an original driver hexed string and converted for use with request_firmware(). For details you can check out:

git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/athfw2lnx.git

Open firmware ?

We are first trying to write the driver for ar9271, however one interested community member has expressed interest in working on an open firmware for ar9271. We are working with this community member on trying to get this done but we have nothing certain or guaranteed.

TODO

  • More HTC/HIF/WMI cleanup - for upstream inclusion
  • Fill in gaps on the mac80211 driver, ath9k_htc.c (mcgrof, but more help is welcomed)

Long term:

  • Use device and bus to probe a new ath_htc device instead of using request_firmware. Look at ssb_bus_register() for an example of how to do this. This is not an upstream requirement but more of an architectural implementation change which will help more as we add more ath_htc devices.

Patches

You can send patches to:

To: mcgrof@gmail.com
Cc: devel@linuxdriverproject.org

Debugging

You can use the module parameter debug and use it as with ath9k. Since you may be enabling debugging all the time the easier option is to always enable it by using a modprobe.d conf file. For example create a file

/etc/modprobe.d/atheros.conf

In it put:

options ath9k_htc debug=0xfffffff

To enable full debugging.


This is a static dump of the old wiki, taken after locking it in January 2015. The new wiki is at https://wireless.wiki.kernel.org/.
versions of this page: last, v101, v100, v99, v98, v97, v96, v95, v94, v93, v92, v91, v90, v89, v88, v87, v86, v85, v84, v83, v82, v81, v80, v79, v78, v77, v76, v75, v74, v73, v72, v71, v70, v69, v68, v67, v66, v65, v64, v63, v62, v61, v60, v59, v58, v57, v56, v55, v54, v53, v52, v51, v50, v49, v48, v47, v46, v45, v44, v43, v42, v41, v40, v39, v38, v37, v36, v35, v34, v33, v32, v31, v30, v29, v28, v27, v26, v25, v24, v23, v22, v21, v20, v19, v18, v17, v16, v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1