FS#8961 - Anti-Aliased Fonts.
[kugel-rb.git] / firmware / export / ohci.h
blob4a82781c5dc0ea39e561bdc9e5301b1e8ddc50b2
1 /***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 * $Id$
10 * OHCI data structures and registers
12 * Copyright (C) 2009 by Frank Gevaerts
14 * This program is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU General Public License
16 * as published by the Free Software Foundation; either version 2
17 * of the License, or (at your option) any later version.
19 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
20 * KIND, either express or implied.
22 ****************************************************************************/
24 #define OHCI_REVISION (*(volatile unsigned int *)(OHCI_BASE+0x00))
25 #define OHCI_CONTROL (*(volatile unsigned int *)(OHCI_BASE+0x04))
26 #define OHCI_COMMAND_STATUS (*(volatile unsigned int *)(OHCI_BASE+0x08))
27 #define OHCI_INTERRUPT_STATUS (*(volatile unsigned int *)(OHCI_BASE+0x0C))
28 #define OHCI_INTERRUPT_ENABLE (*(volatile unsigned int *)(OHCI_BASE+0x10))
29 #define OHCI_INTERRUPT_DISABLE (*(volatile unsigned int *)(OHCI_BASE+0x14))
30 #define OHCI_HCCA (*(volatile unsigned int *)(OHCI_BASE+0x18))
31 #define OHCI_PERIOD_CURRENT_ED (*(volatile unsigned int *)(OHCI_BASE+0x1C))
32 #define OHCI_CONTROL_HEAD_ED (*(volatile unsigned int *)(OHCI_BASE+0x20))
33 #define OHCI_CONTROL_CURRENT_ED (*(volatile unsigned int *)(OHCI_BASE+0x24))
34 #define OHCI_BULK_HEAD_ED (*(volatile unsigned int *)(OHCI_BASE+0x28))
35 #define OHCI_BULK_CURRENT_ED (*(volatile unsigned int *)(OHCI_BASE+0x2C))
36 #define OHCI_DONE_HEAD (*(volatile unsigned int *)(OHCI_BASE+0x30))
37 #define OHCI_FM_INTERVAL (*(volatile unsigned int *)(OHCI_BASE+0x34))
38 #define OHCI_FM_REMAINING (*(volatile unsigned int *)(OHCI_BASE+0x38))
39 #define OHCI_FM_NUMBER (*(volatile unsigned int *)(OHCI_BASE+0x3C))
40 #define OHCI_PERIODIC_START (*(volatile unsigned int *)(OHCI_BASE+0x40))
41 #define OHCI_LS_THRESHOLD (*(volatile unsigned int *)(OHCI_BASE+0x44))
42 #define OHCI_RH_DESCRIPTOR_A (*(volatile unsigned int *)(OHCI_BASE+0x48))
43 #define OHCI_RH_DESCRIPTOR_B (*(volatile unsigned int *)(OHCI_BASE+0x4C))
44 #define OHCI_RH_STATUS (*(volatile unsigned int *)(OHCI_BASE+0x50))
45 #define OHCI_RH_PORT_STATUS_1 (*(volatile unsigned int *)(OHCI_BASE+0x54))
46 #define OHCI_RH_PORT_STATUS_2 (*(volatile unsigned int *)(OHCI_BASE+0x58))
48 /* Transfer Descriptor */
49 struct ohci_td
51 uint32_t td_config;
52 void *current_buffer_pointer;
53 struct ohci_td *nextTD;
54 void *buffer_end;
57 /* Endpoint Descriptor */
58 struct ohci_ed
60 uint32_t ep_config;
61 struct ohci_td *tail;
62 struct ohct_td *head;
63 struct ohci_ed *nextED;
66 /* Host Controller Communications Area */
67 struct ohci_hcca
69 struct ohci_ed (*interrupt_ed_table)[32];
70 unsigned short frame_number;
71 unsigned short pad1;
72 uint32_t done_head;
73 unsigned char reserved[116];