| 1 | /* $Id: irqos2.h,v 1.1.1.1 2003/07/02 13:56:58 eleph Exp $ */
|
|---|
| 2 | /*
|
|---|
| 3 | * Header for IRQ definitions & structures
|
|---|
| 4 | *
|
|---|
| 5 | * (C) 2000-2002 InnoTek Systemberatung GmbH
|
|---|
| 6 | *
|
|---|
| 7 | * This program is free software; you can redistribute it and/or
|
|---|
| 8 | * modify it under the terms of the GNU General Public License as
|
|---|
| 9 | * published by the Free Software Foundation; either version 2 of
|
|---|
| 10 | * the License, or (at your option) any later version.
|
|---|
| 11 | *
|
|---|
| 12 | * This program is distributed in the hope that it will be useful,
|
|---|
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 15 | * GNU General Public License for more details.
|
|---|
| 16 | *
|
|---|
| 17 | * You should have received a copy of the GNU General Public
|
|---|
| 18 | * License along with this program; if not, write to the Free
|
|---|
| 19 | * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
|
|---|
| 20 | * USA.
|
|---|
| 21 | *
|
|---|
| 22 | */
|
|---|
| 23 |
|
|---|
| 24 | #ifndef __IRQOS2_H__
|
|---|
| 25 | #define __IRQOS2_H__
|
|---|
| 26 |
|
|---|
| 27 | #define MAX_SHAREDIRQS 8
|
|---|
| 28 | #define MAX_IRQ_SLOTS 8
|
|---|
| 29 |
|
|---|
| 30 |
|
|---|
| 31 | typedef int irqreturn_t;
|
|---|
| 32 | typedef irqreturn_t (*snd_irq_handler_t)(int, void *);
|
|---|
| 33 | #define irq_handler_t snd_irq_handler_t
|
|---|
| 34 | #undef irq_handler_t
|
|---|
| 35 | #define irq_handler_t snd_irq_handler_t
|
|---|
| 36 |
|
|---|
| 37 | typedef struct {
|
|---|
| 38 | irq_handler_t handler;
|
|---|
| 39 | ULONG x0;
|
|---|
| 40 | char *x1;
|
|---|
| 41 | void *x2;
|
|---|
| 42 | } IRQHANDLER_INFO;
|
|---|
| 43 |
|
|---|
| 44 | typedef struct
|
|---|
| 45 | {
|
|---|
| 46 | unsigned irqNo;
|
|---|
| 47 | unsigned fEOI;
|
|---|
| 48 | unsigned flHandlers;
|
|---|
| 49 | IRQHANDLER_INFO irqHandlers[MAX_SHAREDIRQS];
|
|---|
| 50 | } IRQ_SLOT;
|
|---|
| 51 |
|
|---|
| 52 |
|
|---|
| 53 | #ifdef __cplusplus
|
|---|
| 54 | extern "C" {
|
|---|
| 55 | #endif
|
|---|
| 56 |
|
|---|
| 57 | BOOL ALSA_SetIrq(ULONG ulIrq, ULONG ulSlotNo, BOOL fShared);
|
|---|
| 58 | BOOL ALSA_FreeIrq(ULONG ulIrq);
|
|---|
| 59 |
|
|---|
| 60 | BOOL process_interrupt(ULONG ulSlotNo, ULONG *pulIrq);
|
|---|
| 61 |
|
|---|
| 62 | ULONG os2gettimemsec();
|
|---|
| 63 | ULONG os2gettimesec();
|
|---|
| 64 |
|
|---|
| 65 | #ifdef __cplusplus
|
|---|
| 66 | }
|
|---|
| 67 | #endif
|
|---|
| 68 |
|
|---|
| 69 | #endif //__IRQOS2_H__
|
|---|
| 70 |
|
|---|