Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 1 | /* |
Jim Lieb | 612822f | 2009-08-12 14:54:03 -0700 | [diff] [blame] | 2 | * Copyright (c) 1996, 2003 VIA Networking Technologies, Inc. |
| 3 | * All rights reserved. |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 2 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License along |
| 16 | * with this program; if not, write to the Free Software Foundation, Inc., |
| 17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 18 | * |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 19 | * File: device_cfg.h |
| 20 | * |
| 21 | * Purpose: Driver configuration header |
| 22 | * Author: Lyndon Chen |
| 23 | * |
| 24 | * Date: Dec 17, 2002 |
| 25 | * |
| 26 | */ |
| 27 | #ifndef __DEVICE_CONFIG_H |
| 28 | #define __DEVICE_CONFIG_H |
| 29 | |
| 30 | //#include <linux/config.h> |
| 31 | #include <linux/types.h> |
| 32 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 33 | #include "ttype.h" |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 34 | |
| 35 | typedef |
| 36 | struct _version { |
Joe Perches | 74533af | 2013-03-18 10:44:46 -0700 | [diff] [blame] | 37 | unsigned char major; |
| 38 | unsigned char minor; |
| 39 | unsigned char build; |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 40 | } version_t, *pversion_t; |
| 41 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 42 | #define VID_TABLE_SIZE 64 |
| 43 | #define MCAST_TABLE_SIZE 64 |
| 44 | #define MCAM_SIZE 32 |
| 45 | #define VCAM_SIZE 32 |
| 46 | #define TX_QUEUE_NO 8 |
| 47 | |
Forest Bond | e2ce527 | 2009-05-04 21:48:27 -0400 | [diff] [blame] | 48 | #define DEVICE_NAME "vt6655" |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 49 | #define DEVICE_FULL_DRV_NAM "VIA Networking Solomon-A/B/G Wireless LAN Adapter Driver" |
| 50 | |
| 51 | #ifndef MAJOR_VERSION |
| 52 | #define MAJOR_VERSION 1 |
| 53 | #endif |
| 54 | |
| 55 | #ifndef MINOR_VERSION |
| 56 | #define MINOR_VERSION 17 |
| 57 | #endif |
| 58 | |
| 59 | #ifndef DEVICE_VERSION |
| 60 | #define DEVICE_VERSION "1.19.12" |
| 61 | #endif |
Jim Lieb | 612822f | 2009-08-12 14:54:03 -0700 | [diff] [blame] | 62 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 63 | //config file |
| 64 | #include <linux/fs.h> |
| 65 | #include <linux/fcntl.h> |
| 66 | #ifndef CONFIG_PATH |
| 67 | #define CONFIG_PATH "/etc/vntconfiguration.dat" |
| 68 | #endif |
| 69 | |
| 70 | //Max: 2378=2312Payload + 30HD +4CRC + 2Padding + 4Len + 8TSF + 4RSR |
| 71 | #define PKT_BUF_SZ 2390 |
| 72 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 73 | #define MAX_UINTS 8 |
| 74 | #define OPTION_DEFAULT { [0 ... MAX_UINTS-1] = -1} |
| 75 | |
Joe Perches | 74533af | 2013-03-18 10:44:46 -0700 | [diff] [blame] | 76 | typedef enum _chip_type { |
| 77 | VT3253 = 1 |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 78 | } CHIP_TYPE, *PCHIP_TYPE; |
| 79 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 80 | #ifdef VIAWET_DEBUG |
Joe Perches | bda2a44 | 2013-03-18 20:55:40 -0700 | [diff] [blame] | 81 | #define ASSERT(x) \ |
| 82 | do { \ |
| 83 | if (!(x)) { \ |
| 84 | printk(KERN_ERR "assertion %s failed: file %s line %d\n", \ |
| 85 | #x, __func__, __LINE__); \ |
| 86 | *(int *)0 = 0; \ |
| 87 | } \ |
| 88 | } while (0) |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 89 | #define DBG_PORT80(value) outb(value, 0x80) |
| 90 | #else |
| 91 | #define ASSERT(x) |
| 92 | #define DBG_PORT80(value) |
| 93 | #endif |
| 94 | |
Forest Bond | 1cb648b | 2009-04-25 10:31:32 -0400 | [diff] [blame] | 95 | #endif |