blob: a5af3f42e3f4ff3f5386369155c9bb4a2723b52f [file] [log] [blame]
Christopher Ferrisa9750ed2021-05-03 14:02:49 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef _UAPI_SPI_H
20#define _UAPI_SPI_H
21#include <linux/const.h>
22#define SPI_CPHA _BITUL(0)
23#define SPI_CPOL _BITUL(1)
24#define SPI_MODE_0 (0 | 0)
25#define SPI_MODE_1 (0 | SPI_CPHA)
26#define SPI_MODE_2 (SPI_CPOL | 0)
27#define SPI_MODE_3 (SPI_CPOL | SPI_CPHA)
28#define SPI_MODE_X_MASK (SPI_CPOL | SPI_CPHA)
29#define SPI_CS_HIGH _BITUL(2)
30#define SPI_LSB_FIRST _BITUL(3)
31#define SPI_3WIRE _BITUL(4)
32#define SPI_LOOP _BITUL(5)
33#define SPI_NO_CS _BITUL(6)
34#define SPI_READY _BITUL(7)
35#define SPI_TX_DUAL _BITUL(8)
36#define SPI_TX_QUAD _BITUL(9)
37#define SPI_RX_DUAL _BITUL(10)
38#define SPI_RX_QUAD _BITUL(11)
39#define SPI_CS_WORD _BITUL(12)
40#define SPI_TX_OCTAL _BITUL(13)
41#define SPI_RX_OCTAL _BITUL(14)
42#define SPI_3WIRE_HIZ _BITUL(15)
Christopher Ferris80ae69d2022-08-02 16:32:21 -070043#define SPI_RX_CPHA_FLIP _BITUL(16)
Christopher Ferris8666d042023-09-06 14:55:31 -070044#define SPI_MOSI_IDLE_LOW _BITUL(17)
45#define SPI_MODE_USER_MASK (_BITUL(18) - 1)
Christopher Ferrisa9750ed2021-05-03 14:02:49 -070046#endif