blob: f8e47a14f943b625c295046e086fcc66c65d94a0 [file] [log] [blame]
Christopher Ferris38062f92014-07-09 15:33:25 -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_LINUX_ZORRO_H
20#define _UAPI_LINUX_ZORRO_H
21#include <linux/types.h>
22#define ZORRO_MANUF(id) ((id) >> 16)
Christopher Ferris38062f92014-07-09 15:33:25 -070023#define ZORRO_PROD(id) (((id) >> 8) & 0xff)
24#define ZORRO_EPC(id) ((id) & 0xff)
Tao Baod7db5942015-01-28 10:07:51 -080025#define ZORRO_ID(manuf,prod,epc) ((ZORRO_MANUF_ ##manuf << 16) | ((prod) << 8) | (epc))
Christopher Ferris38062f92014-07-09 15:33:25 -070026typedef __u32 zorro_id;
Christopher Ferris38062f92014-07-09 15:33:25 -070027#include <linux/zorro_ids.h>
28#define GVP_PRODMASK (0xf8)
29#define GVP_SCSICLKMASK (0x01)
30enum GVP_flags {
Tao Baod7db5942015-01-28 10:07:51 -080031 GVP_IO = 0x01,
32 GVP_ACCEL = 0x02,
33 GVP_SCSI = 0x04,
34 GVP_24BITDMA = 0x08,
Tao Baod7db5942015-01-28 10:07:51 -080035 GVP_25BITDMA = 0x10,
36 GVP_NOBANK = 0x20,
37 GVP_14MHZ = 0x40,
Christopher Ferris38062f92014-07-09 15:33:25 -070038};
Christopher Ferris38062f92014-07-09 15:33:25 -070039struct Node {
Tao Baod7db5942015-01-28 10:07:51 -080040 __be32 ln_Succ;
41 __be32 ln_Pred;
42 __u8 ln_Type;
Tao Baod7db5942015-01-28 10:07:51 -080043 __s8 ln_Pri;
44 __be32 ln_Name;
Christopher Ferris38062f92014-07-09 15:33:25 -070045} __packed;
46struct ExpansionRom {
Tao Baod7db5942015-01-28 10:07:51 -080047 __u8 er_Type;
48 __u8 er_Product;
49 __u8 er_Flags;
50 __u8 er_Reserved03;
Tao Baod7db5942015-01-28 10:07:51 -080051 __be16 er_Manufacturer;
52 __be32 er_SerialNumber;
53 __be16 er_InitDiagVec;
54 __u8 er_Reserved0c;
Tao Baod7db5942015-01-28 10:07:51 -080055 __u8 er_Reserved0d;
56 __u8 er_Reserved0e;
57 __u8 er_Reserved0f;
Christopher Ferris38062f92014-07-09 15:33:25 -070058} __packed;
Christopher Ferris38062f92014-07-09 15:33:25 -070059#define ERT_TYPEMASK 0xc0
60#define ERT_ZORROII 0xc0
61#define ERT_ZORROIII 0x80
62#define ERTB_MEMLIST 5
Tao Baod7db5942015-01-28 10:07:51 -080063#define ERTF_MEMLIST (1 << 5)
Christopher Ferris38062f92014-07-09 15:33:25 -070064struct ConfigDev {
Tao Baod7db5942015-01-28 10:07:51 -080065 struct Node cd_Node;
66 __u8 cd_Flags;
Tao Baod7db5942015-01-28 10:07:51 -080067 __u8 cd_Pad;
68 struct ExpansionRom cd_Rom;
69 __be32 cd_BoardAddr;
70 __be32 cd_BoardSize;
Tao Baod7db5942015-01-28 10:07:51 -080071 __be16 cd_SlotAddr;
72 __be16 cd_SlotSize;
73 __be32 cd_Driver;
74 __be32 cd_NextCD;
Tao Baod7db5942015-01-28 10:07:51 -080075 __be32 cd_Unused[4];
Christopher Ferris38062f92014-07-09 15:33:25 -070076} __packed;
77#define ZORRO_NUM_AUTO 16
78#endif