diff options
Diffstat (limited to 'arch/mips/ath25/devices.h')
-rw-r--r-- | arch/mips/ath25/devices.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/arch/mips/ath25/devices.h b/arch/mips/ath25/devices.h new file mode 100644 index 000000000000..e25a3262256d --- /dev/null +++ b/arch/mips/ath25/devices.h @@ -0,0 +1,18 @@ +#ifndef __ATH25_DEVICES_H +#define __ATH25_DEVICES_H + +#include <linux/cpu.h> + +#define ATH25_REG_MS(_val, _field) (((_val) & _field##_M) >> _field##_S) + +static inline bool is_ar2315(void) +{ + return (current_cpu_data.cputype == CPU_4KEC); +} + +static inline bool is_ar5312(void) +{ + return !is_ar2315(); +} + +#endif |