Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 1 | /* |
| 2 | ************************************************************************* |
| 3 | * Ralink Tech Inc. |
| 4 | * 5F., No.36, Taiyuan St., Jhubei City, |
| 5 | * Hsinchu County 302, |
| 6 | * Taiwan, R.O.C. |
| 7 | * |
| 8 | * (c) Copyright 2002-2007, Ralink Technology, Inc. |
| 9 | * |
| 10 | * This program is free software; you can redistribute it and/or modify * |
| 11 | * it under the terms of the GNU General Public License as published by * |
| 12 | * the Free Software Foundation; either version 2 of the License, or * |
| 13 | * (at your option) any later version. * |
| 14 | * * |
| 15 | * This program is distributed in the hope that it will be useful, * |
| 16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
| 17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
| 18 | * GNU General Public License for more details. * |
| 19 | * * |
| 20 | * You should have received a copy of the GNU General Public License * |
| 21 | * along with this program; if not, write to the * |
| 22 | * Free Software Foundation, Inc., * |
| 23 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
| 24 | * * |
| 25 | ************************************************************************* |
| 26 | |
| 27 | Module Name: |
| 28 | rtmp_type.h |
| 29 | |
| 30 | Abstract: |
| 31 | |
| 32 | Revision History: |
| 33 | Who When What |
| 34 | -------- ---------- ---------------------------------------------- |
| 35 | Name Date Modification logs |
| 36 | Paul Lin 1-2-2004 |
| 37 | */ |
| 38 | #ifndef __RTMP_TYPE_H__ |
| 39 | #define __RTMP_TYPE_H__ |
| 40 | |
| 41 | #define PACKED __attribute__ ((packed)) |
| 42 | |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 43 | #ifdef LINUX |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 44 | // Put platform dependent declaration here |
| 45 | // For example, linux type definition |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 46 | typedef unsigned char UINT8; |
| 47 | typedef unsigned short UINT16; |
| 48 | typedef unsigned int UINT32; |
| 49 | typedef unsigned long long UINT64; |
| 50 | typedef int INT32; |
| 51 | typedef long long INT64; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 52 | #endif // LINUX // |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 53 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 54 | typedef unsigned char *PUINT8; |
| 55 | typedef unsigned short *PUINT16; |
| 56 | typedef unsigned int *PUINT32; |
| 57 | typedef unsigned long long *PUINT64; |
| 58 | typedef int *PINT32; |
| 59 | typedef long long *PINT64; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 60 | |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 61 | // modified for fixing compile warning on Sigma 8634 platform |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 62 | typedef char STRING; |
| 63 | typedef signed char CHAR; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 64 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 65 | typedef signed short SHORT; |
| 66 | typedef signed int INT; |
| 67 | typedef signed long LONG; |
| 68 | typedef signed long long LONGLONG; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 69 | |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 70 | #ifdef LINUX |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 71 | typedef unsigned char UCHAR; |
| 72 | typedef unsigned short USHORT; |
| 73 | typedef unsigned int UINT; |
| 74 | typedef unsigned long ULONG; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 75 | #endif // LINUX // |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 76 | typedef unsigned long long ULONGLONG; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 77 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 78 | typedef unsigned char BOOLEAN; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 79 | #ifdef LINUX |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 80 | typedef void VOID; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 81 | #endif // LINUX // |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 82 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 83 | typedef char *PSTRING; |
| 84 | typedef VOID *PVOID; |
| 85 | typedef CHAR *PCHAR; |
| 86 | typedef UCHAR *PUCHAR; |
| 87 | typedef USHORT *PUSHORT; |
| 88 | typedef LONG *PLONG; |
| 89 | typedef ULONG *PULONG; |
| 90 | typedef UINT *PUINT; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 91 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 92 | typedef unsigned int NDIS_MEDIA_STATE; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 93 | |
| 94 | typedef union _LARGE_INTEGER { |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 95 | struct { |
| 96 | UINT LowPart; |
| 97 | INT32 HighPart; |
| 98 | } u; |
| 99 | INT64 QuadPart; |
Greg Kroah-Hartman | 9198099 | 2008-10-28 14:48:09 -0700 | [diff] [blame] | 100 | } LARGE_INTEGER; |
| 101 | |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 102 | // |
| 103 | // Register set pair for initialzation register set definition |
| 104 | // |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 105 | typedef struct _RTMP_REG_PAIR { |
| 106 | ULONG Register; |
| 107 | ULONG Value; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 108 | } RTMP_REG_PAIR, *PRTMP_REG_PAIR; |
| 109 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 110 | typedef struct _REG_PAIR { |
| 111 | UCHAR Register; |
| 112 | UCHAR Value; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 113 | } REG_PAIR, *PREG_PAIR; |
| 114 | |
| 115 | // |
| 116 | // Register set pair for initialzation register set definition |
| 117 | // |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 118 | typedef struct _RTMP_RF_REGS { |
| 119 | UCHAR Channel; |
| 120 | ULONG R1; |
| 121 | ULONG R2; |
| 122 | ULONG R3; |
| 123 | ULONG R4; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 124 | } RTMP_RF_REGS, *PRTMP_RF_REGS; |
| 125 | |
| 126 | typedef struct _FREQUENCY_ITEM { |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 127 | UCHAR Channel; |
| 128 | UCHAR N; |
| 129 | UCHAR R; |
| 130 | UCHAR K; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 131 | } FREQUENCY_ITEM, *PFREQUENCY_ITEM; |
| 132 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 133 | typedef int NTSTATUS; |
Bartlomiej Zolnierkiewicz | ca97b83 | 2009-09-22 20:44:07 +0200 | [diff] [blame] | 134 | |
| 135 | #define STATUS_SUCCESS 0x00 |
| 136 | #define STATUS_UNSUCCESSFUL 0x01 |
| 137 | |
Bartlomiej Zolnierkiewicz | 52b81c8 | 2009-12-11 12:23:14 -0800 | [diff] [blame] | 138 | #endif // __RTMP_TYPE_H__ // |