1 | /*␊ |
2 | * ATI injector␊ |
3 | *␊ |
4 | * Copyright (C) 2009 Jasmin Fazlic, iNDi, netkas␊ |
5 | *␊ |
6 | * ATI injector is free software: you can redistribute it and/or modify␊ |
7 | * it under the terms of the GNU General Public License as published by␊ |
8 | * the Free Software Foundation, either version 3 of the License, or␊ |
9 | * (at your option) any later version.␊ |
10 | *␊ |
11 | * ATI driver and injector is distributed in the hope that it will be useful,␊ |
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of␊ |
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the␊ |
14 | * GNU General Public License for more details.␊ |
15 | *␊ |
16 | * You should have received a copy of the GNU General Public License␊ |
17 | * along with ATI injector. If not, see <http://www.gnu.org/licenses/>.␊ |
18 | */␊ |
19 | /*␊ |
20 | * Alternatively you can choose to comply with APSL␊ |
21 | */␊ |
22 | ␊ |
23 | ␊ |
24 | #ifndef __LIBSAIO_ATI_H␊ |
25 | #define __LIBSAIO_ATI_H␊ |
26 | ␊ |
27 | bool setup_ati_devprop(pci_dt_t *ati_dev);␊ |
28 | ␊ |
29 | struct ati_chipsets_t {␊ |
30 | ␉unsigned device;␊ |
31 | ␉char *name;␊ |
32 | };␊ |
33 | ␊ |
34 | struct ati_data_key {␊ |
35 | ␉uint32_t size;␊ |
36 | ␉char *name;␊ |
37 | ␉uint8_t data[];␊ |
38 | };␊ |
39 | ␊ |
40 | ␊ |
41 | #define DCB_MAX_NUM_ENTRIES 16␊ |
42 | #define DCB_MAX_NUM_I2C_ENTRIES 16␊ |
43 | ␊ |
44 | #define DCB_LOC_ON_CHIP 0␊ |
45 | ␊ |
46 | struct bios {␊ |
47 | ␉uint16_t␉signature;␉␉/* 0x55AA */␊ |
48 | ␉uint8_t␉␉size;␉␉␉/* Size in multiples of 512 */␊ |
49 | };␊ |
50 | ␊ |
51 | #define REG8(reg) ((volatile uint8_t *)regs)[(reg)]␊ |
52 | #define REG16(reg) ((volatile uint16_t *)regs)[(reg) >> 1]␊ |
53 | #define REG32R(reg) ((volatile uint32_t *)regs)[(reg) >> 2]␊ |
54 | #define REG32W(reg, val) ((volatile uint32_t *)regs)[(reg) >> 2] = (val)␊ |
55 | ␊ |
56 | ␊ |
57 | #endif /* !__LIBSAIO_ATI_H */␊ |
58 | |