User Tools

Site Tools


en:users:drivers:ath10k:codingstyle

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
en:users:drivers:ath10k:codingstyle [2023/08/01 21:12]
Jeff Johnson [Error path]
en:users:drivers:ath10k:codingstyle [2024/04/30 05:40]
Kalle Valo Write about tools, mention ath11k and ath12k
Line 5: Line 5:
  
  
-===== ath10k Coding Style =====+===== ath10k/​ath11k/​ath12k ​Coding Style =====
  
 +==== Introduction ====
  
-==== Linux coding style ====+This is the coding style document for [[en/​users/​Drivers/​ath10k|ath10k]],​ [[en/​users/​Drivers/​ath11k|ath11k]] and [[en/​users/​Drivers/​ath12k|ath12k]] drivers. Read this before writing any code. 
 + 
 +==== Tools ===== 
 + 
 +Use latest GCC which you can download from [[https://​mirrors.edge.kernel.org/​pub/​tools/​crosstool/​|crosstool]]. Setting it up is easy, unpack it to a directory and create a GNUmakefile:​ 
 + 
 +<​code>​ 
 +ARCH=x86 
 +CROSS_COMPILE=/​opt/​cross/​gcc-13.2.0-nolibc/​x86_64-linux/​bin/​x86_64-linux- 
 + 
 +export ARCH 
 +export CROSS_COMPILE 
 +</​code>​
  
-ath10k mostly follows ​[[https://www.kernel.org/​doc/html/​latest/​process/​coding-style.html|Linux Coding Style]], so read that first+You will need [[https://docs.kernel.org/​dev-tools/sparse.html#getting-sparse|the latest sparse from git]]. Linux distros usually have too old sparse and you will see wrong errors!
  
 ==== Checking code ==== ==== Checking code ====
Line 46: Line 59:
 ~/ath$ ~/ath$
 </​code>​ </​code>​
 +
 +==== Linux coding style ====
 +
 +ath10k/​ath11k/​ath12k mostly follows [[https://​docs.kernel.org/​process/​coding-style.html|Linux Coding Style]], so read that first. ​
  
 ==== Status/​error variables ==== ==== Status/​error variables ====
en/users/drivers/ath10k/codingstyle.txt · Last modified: 2024/05/05 04:24 by Kalle Valo