aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/bcm4329/include/bcmdefs.h
diff options
context:
space:
mode:
authorJonathan Herman <hermanjl@cs.unc.edu>2013-01-22 10:38:37 -0500
committerJonathan Herman <hermanjl@cs.unc.edu>2013-01-22 10:38:37 -0500
commitfcc9d2e5a6c89d22b8b773a64fb4ad21ac318446 (patch)
treea57612d1888735a2ec7972891b68c1ac5ec8faea /drivers/net/wireless/bcm4329/include/bcmdefs.h
parent8dea78da5cee153b8af9c07a2745f6c55057fe12 (diff)
Added missing tegra files.HEADmaster
Diffstat (limited to 'drivers/net/wireless/bcm4329/include/bcmdefs.h')
-rw-r--r--drivers/net/wireless/bcm4329/include/bcmdefs.h114
1 files changed, 114 insertions, 0 deletions
diff --git a/drivers/net/wireless/bcm4329/include/bcmdefs.h b/drivers/net/wireless/bcm4329/include/bcmdefs.h
new file mode 100644
index 00000000000..f4e99461971
--- /dev/null
+++ b/drivers/net/wireless/bcm4329/include/bcmdefs.h
@@ -0,0 +1,114 @@
1/*
2 * Misc system wide definitions
3 *
4 * Copyright (C) 1999-2010, Broadcom Corporation
5 *
6 * Unless you and Broadcom execute a separate written software license
7 * agreement governing use of this software, this software is licensed to you
8 * under the terms of the GNU General Public License version 2 (the "GPL"),
9 * available at http://www.broadcom.com/licenses/GPLv2.php, with the
10 * following added to such license:
11 *
12 * As a special exception, the copyright holders of this software give you
13 * permission to link this software with independent modules, and to copy and
14 * distribute the resulting executable under terms of your choice, provided that
15 * you also meet, for each linked independent module, the terms and conditions of
16 * the license of that module. An independent module is a module which is not
17 * derived from this software. The special exception does not apply to any
18 * modifications of the software.
19 *
20 * Notwithstanding the above, under no circumstances may you combine this
21 * software in any way with any other Broadcom software provided under a license
22 * other than the GPL, without Broadcom's express prior written consent.
23 * $Id: bcmdefs.h,v 13.38.4.10.2.7.6.11 2010/02/01 05:51:55 Exp $
24 */
25
26
27#ifndef _bcmdefs_h_
28#define _bcmdefs_h_
29
30#define STATIC static
31
32#define SI_BUS 0
33#define PCI_BUS 1
34#define PCMCIA_BUS 2
35#define SDIO_BUS 3
36#define JTAG_BUS 4
37#define USB_BUS 5
38#define SPI_BUS 6
39
40
41#ifdef BCMBUSTYPE
42#define BUSTYPE(bus) (BCMBUSTYPE)
43#else
44#define BUSTYPE(bus) (bus)
45#endif
46
47
48#ifdef BCMCHIPTYPE
49#define CHIPTYPE(bus) (BCMCHIPTYPE)
50#else
51#define CHIPTYPE(bus) (bus)
52#endif
53
54
55
56#if defined(BCMSPROMBUS)
57#define SPROMBUS (BCMSPROMBUS)
58#elif defined(SI_PCMCIA_SROM)
59#define SPROMBUS (PCMCIA_BUS)
60#else
61#define SPROMBUS (PCI_BUS)
62#endif
63
64
65#ifdef BCMCHIPID
66#define CHIPID(chip) (BCMCHIPID)
67#else
68#define CHIPID(chip) (chip)
69#endif
70
71
72#define DMADDR_MASK_32 0x0
73#define DMADDR_MASK_30 0xc0000000
74#define DMADDR_MASK_0 0xffffffff
75
76#define DMADDRWIDTH_30 30
77#define DMADDRWIDTH_32 32
78#define DMADDRWIDTH_63 63
79#define DMADDRWIDTH_64 64
80
81
82#define BCMEXTRAHDROOM 164
83
84
85#define BCMDONGLEHDRSZ 12
86#define BCMDONGLEPADSZ 16
87
88#define BCMDONGLEOVERHEAD (BCMDONGLEHDRSZ + BCMDONGLEPADSZ)
89
90
91
92#define BITFIELD_MASK(width) \
93 (((unsigned)1 << (width)) - 1)
94#define GFIELD(val, field) \
95 (((val) >> field ## _S) & field ## _M)
96#define SFIELD(val, field, bits) \
97 (((val) & (~(field ## _M << field ## _S))) | \
98 ((unsigned)(bits) << field ## _S))
99
100
101#ifdef BCMSMALL
102#undef BCMSPACE
103#define bcmspace FALSE
104#else
105#define BCMSPACE
106#define bcmspace TRUE
107#endif
108
109
110#define MAXSZ_NVRAM_VARS 4096
111
112#define LOCATOR_EXTERN static
113
114#endif