Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
bcma.h File Reference
#include <linux/pci.h>
#include <linux/mod_devicetable.h>
#include <linux/bcma/bcma_driver_chipcommon.h>
#include <linux/bcma/bcma_driver_pci.h>
#include <linux/bcma/bcma_driver_mips.h>
#include <linux/bcma/bcma_driver_gmac_cmn.h>
#include <linux/ssb/ssb.h>
#include <linux/bcma/bcma_regs.h>

Go to the source code of this file.

Data Structures

struct  bcma_chipinfo
 
struct  bcma_boardinfo
 
struct  bcma_host_ops
 
struct  bcma_device
 
struct  bcma_driver
 
struct  bcma_bus
 

Macros

#define BCMA_MANUF_ARM   0x43B
 
#define BCMA_MANUF_MIPS   0x4A7
 
#define BCMA_MANUF_BCM   0x4BF
 
#define BCMA_CL_SIM   0x0
 
#define BCMA_CL_EROM   0x1
 
#define BCMA_CL_CORESIGHT   0x9
 
#define BCMA_CL_VERIF   0xB
 
#define BCMA_CL_OPTIMO   0xD
 
#define BCMA_CL_GEN   0xE
 
#define BCMA_CL_PRIMECELL   0xF
 
#define BCMA_CORE_OOB_ROUTER   0x367 /* Out of band */
 
#define BCMA_CORE_4706_CHIPCOMMON   0x500
 
#define BCMA_CORE_4706_SOC_RAM   0x50E
 
#define BCMA_CORE_4706_MAC_GBIT   0x52D
 
#define BCMA_CORE_AMEMC   0x52E /* DDR1/2 memory controller core */
 
#define BCMA_CORE_ALTA   0x534 /* I2S core */
 
#define BCMA_CORE_4706_MAC_GBIT_COMMON   0x5DC
 
#define BCMA_CORE_DDR23_PHY   0x5DD
 
#define BCMA_CORE_INVALID   0x700
 
#define BCMA_CORE_CHIPCOMMON   0x800
 
#define BCMA_CORE_ILINE20   0x801
 
#define BCMA_CORE_SRAM   0x802
 
#define BCMA_CORE_SDRAM   0x803
 
#define BCMA_CORE_PCI   0x804
 
#define BCMA_CORE_MIPS   0x805
 
#define BCMA_CORE_ETHERNET   0x806
 
#define BCMA_CORE_V90   0x807
 
#define BCMA_CORE_USB11_HOSTDEV   0x808
 
#define BCMA_CORE_ADSL   0x809
 
#define BCMA_CORE_ILINE100   0x80A
 
#define BCMA_CORE_IPSEC   0x80B
 
#define BCMA_CORE_UTOPIA   0x80C
 
#define BCMA_CORE_PCMCIA   0x80D
 
#define BCMA_CORE_INTERNAL_MEM   0x80E
 
#define BCMA_CORE_MEMC_SDRAM   0x80F
 
#define BCMA_CORE_OFDM   0x810
 
#define BCMA_CORE_EXTIF   0x811
 
#define BCMA_CORE_80211   0x812
 
#define BCMA_CORE_PHY_A   0x813
 
#define BCMA_CORE_PHY_B   0x814
 
#define BCMA_CORE_PHY_G   0x815
 
#define BCMA_CORE_MIPS_3302   0x816
 
#define BCMA_CORE_USB11_HOST   0x817
 
#define BCMA_CORE_USB11_DEV   0x818
 
#define BCMA_CORE_USB20_HOST   0x819
 
#define BCMA_CORE_USB20_DEV   0x81A
 
#define BCMA_CORE_SDIO_HOST   0x81B
 
#define BCMA_CORE_ROBOSWITCH   0x81C
 
#define BCMA_CORE_PARA_ATA   0x81D
 
#define BCMA_CORE_SATA_XORDMA   0x81E
 
#define BCMA_CORE_ETHERNET_GBIT   0x81F
 
#define BCMA_CORE_PCIE   0x820
 
#define BCMA_CORE_PHY_N   0x821
 
#define BCMA_CORE_SRAM_CTL   0x822
 
#define BCMA_CORE_MINI_MACPHY   0x823
 
#define BCMA_CORE_ARM_1176   0x824
 
#define BCMA_CORE_ARM_7TDMI   0x825
 
#define BCMA_CORE_PHY_LP   0x826
 
#define BCMA_CORE_PMU   0x827
 
#define BCMA_CORE_PHY_SSN   0x828
 
#define BCMA_CORE_SDIO_DEV   0x829
 
#define BCMA_CORE_ARM_CM3   0x82A
 
#define BCMA_CORE_PHY_HT   0x82B
 
#define BCMA_CORE_MIPS_74K   0x82C
 
#define BCMA_CORE_MAC_GBIT   0x82D
 
#define BCMA_CORE_DDR12_MEM_CTL   0x82E
 
#define BCMA_CORE_PCIE_RC   0x82F /* PCIe Root Complex */
 
#define BCMA_CORE_OCP_OCP_BRIDGE   0x830
 
#define BCMA_CORE_SHARED_COMMON   0x831
 
#define BCMA_CORE_OCP_AHB_BRIDGE   0x832
 
#define BCMA_CORE_SPI_HOST   0x833
 
#define BCMA_CORE_I2S   0x834
 
#define BCMA_CORE_SDR_DDR1_MEM_CTL   0x835 /* SDR/DDR1 memory controller core */
 
#define BCMA_CORE_SHIM   0x837 /* SHIM component in ubus/6362 */
 
#define BCMA_CORE_DEFAULT   0xFFF
 
#define BCMA_MAX_NR_CORES   16
 
#define BCMA_CHIP_ID_BCM4313   0x4313
 
#define BCMA_CHIP_ID_BCM43224   43224
 
#define BCMA_PKG_ID_BCM43224_FAB_CSM   0x8
 
#define BCMA_PKG_ID_BCM43224_FAB_SMIC   0xa
 
#define BCMA_CHIP_ID_BCM43225   43225
 
#define BCMA_CHIP_ID_BCM43227   43227
 
#define BCMA_CHIP_ID_BCM43228   43228
 
#define BCMA_CHIP_ID_BCM43421   43421
 
#define BCMA_CHIP_ID_BCM43428   43428
 
#define BCMA_CHIP_ID_BCM43431   43431
 
#define BCMA_CHIP_ID_BCM43460   43460
 
#define BCMA_CHIP_ID_BCM4331   0x4331
 
#define BCMA_CHIP_ID_BCM6362   0x6362
 
#define BCMA_CHIP_ID_BCM4360   0x4360
 
#define BCMA_CHIP_ID_BCM4352   0x4352
 
#define BCMA_CHIP_ID_BCM4706   0x5300
 
#define BCMA_CHIP_ID_BCM4716   0x4716
 
#define BCMA_PKG_ID_BCM4716   8
 
#define BCMA_PKG_ID_BCM4717   9
 
#define BCMA_PKG_ID_BCM4718   10
 
#define BCMA_CHIP_ID_BCM47162   47162
 
#define BCMA_CHIP_ID_BCM4748   0x4748
 
#define BCMA_CHIP_ID_BCM4749   0x4749
 
#define BCMA_CHIP_ID_BCM5356   0x5356
 
#define BCMA_CHIP_ID_BCM5357   0x5357
 
#define BCMA_CHIP_ID_BCM53572   53572
 
#define bcma_driver_register(drv)   __bcma_driver_register(drv, THIS_MODULE)
 
#define BCMA_DMA_TRANSLATION_MASK   0xC0000000
 
#define BCMA_DMA_TRANSLATION_NONE   0x00000000
 
#define BCMA_DMA_TRANSLATION_DMA32_CMT   0x40000000 /* Client Mode Translation for 32-bit DMA */
 
#define BCMA_DMA_TRANSLATION_DMA64_CMT   0x80000000 /* Client Mode Translation for 64-bit DMA */
 

Enumerations

enum  bcma_hosttype { BCMA_HOSTTYPE_PCI, BCMA_HOSTTYPE_SDIO, BCMA_HOSTTYPE_SOC }
 
enum  bcma_clkmode { BCMA_CLKMODE_FAST, BCMA_CLKMODE_DYNAMIC }
 

Functions

int __bcma_driver_register (struct bcma_driver *drv, struct module *owner)
 
void bcma_driver_unregister (struct bcma_driver *drv)
 
int bcma_arch_register_fallback_sprom (int(*sprom_callback)(struct bcma_bus *bus, struct ssb_sprom *out))
 
struct bcma_devicebcma_find_core (struct bcma_bus *bus, u16 coreid)
 
bool bcma_core_is_enabled (struct bcma_device *core)
 
void bcma_core_disable (struct bcma_device *core, u32 flags)
 
int bcma_core_enable (struct bcma_device *core, u32 flags)
 
void bcma_core_set_clockmode (struct bcma_device *core, enum bcma_clkmode clkmode)
 
void bcma_core_pll_ctl (struct bcma_device *core, u32 req, u32 status, bool on)
 
u32 bcma_core_dma_translation (struct bcma_device *core)
 

Macro Definition Documentation

#define BCMA_CHIP_ID_BCM4313   0x4313

Definition at line 142 of file bcma.h.

#define BCMA_CHIP_ID_BCM43224   43224

Definition at line 143 of file bcma.h.

#define BCMA_CHIP_ID_BCM43225   43225

Definition at line 146 of file bcma.h.

#define BCMA_CHIP_ID_BCM43227   43227

Definition at line 147 of file bcma.h.

#define BCMA_CHIP_ID_BCM43228   43228

Definition at line 148 of file bcma.h.

#define BCMA_CHIP_ID_BCM4331   0x4331

Definition at line 153 of file bcma.h.

#define BCMA_CHIP_ID_BCM43421   43421

Definition at line 149 of file bcma.h.

#define BCMA_CHIP_ID_BCM43428   43428

Definition at line 150 of file bcma.h.

#define BCMA_CHIP_ID_BCM43431   43431

Definition at line 151 of file bcma.h.

#define BCMA_CHIP_ID_BCM43460   43460

Definition at line 152 of file bcma.h.

#define BCMA_CHIP_ID_BCM4352   0x4352

Definition at line 156 of file bcma.h.

#define BCMA_CHIP_ID_BCM4360   0x4360

Definition at line 155 of file bcma.h.

#define BCMA_CHIP_ID_BCM4706   0x5300

Definition at line 159 of file bcma.h.

#define BCMA_CHIP_ID_BCM4716   0x4716

Definition at line 160 of file bcma.h.

#define BCMA_CHIP_ID_BCM47162   47162

Definition at line 164 of file bcma.h.

#define BCMA_CHIP_ID_BCM4748   0x4748

Definition at line 165 of file bcma.h.

#define BCMA_CHIP_ID_BCM4749   0x4749

Definition at line 166 of file bcma.h.

#define BCMA_CHIP_ID_BCM5356   0x5356

Definition at line 167 of file bcma.h.

#define BCMA_CHIP_ID_BCM5357   0x5357

Definition at line 168 of file bcma.h.

#define BCMA_CHIP_ID_BCM53572   53572

Definition at line 169 of file bcma.h.

#define BCMA_CHIP_ID_BCM6362   0x6362

Definition at line 154 of file bcma.h.

#define BCMA_CL_CORESIGHT   0x9

Definition at line 66 of file bcma.h.

#define BCMA_CL_EROM   0x1

Definition at line 65 of file bcma.h.

#define BCMA_CL_GEN   0xE

Definition at line 69 of file bcma.h.

#define BCMA_CL_OPTIMO   0xD

Definition at line 68 of file bcma.h.

#define BCMA_CL_PRIMECELL   0xF

Definition at line 70 of file bcma.h.

#define BCMA_CL_SIM   0x0

Definition at line 64 of file bcma.h.

#define BCMA_CL_VERIF   0xB

Definition at line 67 of file bcma.h.

#define BCMA_CORE_4706_CHIPCOMMON   0x500

Definition at line 74 of file bcma.h.

#define BCMA_CORE_4706_MAC_GBIT   0x52D

Definition at line 76 of file bcma.h.

#define BCMA_CORE_4706_MAC_GBIT_COMMON   0x5DC

Definition at line 79 of file bcma.h.

#define BCMA_CORE_4706_SOC_RAM   0x50E

Definition at line 75 of file bcma.h.

#define BCMA_CORE_80211   0x812

Definition at line 100 of file bcma.h.

#define BCMA_CORE_ADSL   0x809

Definition at line 91 of file bcma.h.

#define BCMA_CORE_ALTA   0x534 /* I2S core */

Definition at line 78 of file bcma.h.

#define BCMA_CORE_AMEMC   0x52E /* DDR1/2 memory controller core */

Definition at line 77 of file bcma.h.

#define BCMA_CORE_ARM_1176   0x824

Definition at line 118 of file bcma.h.

#define BCMA_CORE_ARM_7TDMI   0x825

Definition at line 119 of file bcma.h.

#define BCMA_CORE_ARM_CM3   0x82A

Definition at line 124 of file bcma.h.

#define BCMA_CORE_CHIPCOMMON   0x800

Definition at line 82 of file bcma.h.

#define BCMA_CORE_DDR12_MEM_CTL   0x82E

Definition at line 128 of file bcma.h.

#define BCMA_CORE_DDR23_PHY   0x5DD

Definition at line 80 of file bcma.h.

#define BCMA_CORE_DEFAULT   0xFFF

Definition at line 137 of file bcma.h.

#define BCMA_CORE_ETHERNET   0x806

Definition at line 88 of file bcma.h.

#define BCMA_CORE_ETHERNET_GBIT   0x81F

Definition at line 113 of file bcma.h.

#define BCMA_CORE_EXTIF   0x811

Definition at line 99 of file bcma.h.

#define BCMA_CORE_I2S   0x834

Definition at line 134 of file bcma.h.

#define BCMA_CORE_ILINE100   0x80A

Definition at line 92 of file bcma.h.

#define BCMA_CORE_ILINE20   0x801

Definition at line 83 of file bcma.h.

#define BCMA_CORE_INTERNAL_MEM   0x80E

Definition at line 96 of file bcma.h.

#define BCMA_CORE_INVALID   0x700

Definition at line 81 of file bcma.h.

#define BCMA_CORE_IPSEC   0x80B

Definition at line 93 of file bcma.h.

#define BCMA_CORE_MAC_GBIT   0x82D

Definition at line 127 of file bcma.h.

#define BCMA_CORE_MEMC_SDRAM   0x80F

Definition at line 97 of file bcma.h.

#define BCMA_CORE_MINI_MACPHY   0x823

Definition at line 117 of file bcma.h.

#define BCMA_CORE_MIPS   0x805

Definition at line 87 of file bcma.h.

#define BCMA_CORE_MIPS_3302   0x816

Definition at line 104 of file bcma.h.

#define BCMA_CORE_MIPS_74K   0x82C

Definition at line 126 of file bcma.h.

#define BCMA_CORE_OCP_AHB_BRIDGE   0x832

Definition at line 132 of file bcma.h.

#define BCMA_CORE_OCP_OCP_BRIDGE   0x830

Definition at line 130 of file bcma.h.

#define BCMA_CORE_OFDM   0x810

Definition at line 98 of file bcma.h.

#define BCMA_CORE_OOB_ROUTER   0x367 /* Out of band */

Definition at line 73 of file bcma.h.

#define BCMA_CORE_PARA_ATA   0x81D

Definition at line 111 of file bcma.h.

#define BCMA_CORE_PCI   0x804

Definition at line 86 of file bcma.h.

#define BCMA_CORE_PCIE   0x820

Definition at line 114 of file bcma.h.

#define BCMA_CORE_PCIE_RC   0x82F /* PCIe Root Complex */

Definition at line 129 of file bcma.h.

#define BCMA_CORE_PCMCIA   0x80D

Definition at line 95 of file bcma.h.

#define BCMA_CORE_PHY_A   0x813

Definition at line 101 of file bcma.h.

#define BCMA_CORE_PHY_B   0x814

Definition at line 102 of file bcma.h.

#define BCMA_CORE_PHY_G   0x815

Definition at line 103 of file bcma.h.

#define BCMA_CORE_PHY_HT   0x82B

Definition at line 125 of file bcma.h.

#define BCMA_CORE_PHY_LP   0x826

Definition at line 120 of file bcma.h.

#define BCMA_CORE_PHY_N   0x821

Definition at line 115 of file bcma.h.

#define BCMA_CORE_PHY_SSN   0x828

Definition at line 122 of file bcma.h.

#define BCMA_CORE_PMU   0x827

Definition at line 121 of file bcma.h.

#define BCMA_CORE_ROBOSWITCH   0x81C

Definition at line 110 of file bcma.h.

#define BCMA_CORE_SATA_XORDMA   0x81E

Definition at line 112 of file bcma.h.

#define BCMA_CORE_SDIO_DEV   0x829

Definition at line 123 of file bcma.h.

#define BCMA_CORE_SDIO_HOST   0x81B

Definition at line 109 of file bcma.h.

#define BCMA_CORE_SDR_DDR1_MEM_CTL   0x835 /* SDR/DDR1 memory controller core */

Definition at line 135 of file bcma.h.

#define BCMA_CORE_SDRAM   0x803

Definition at line 85 of file bcma.h.

#define BCMA_CORE_SHARED_COMMON   0x831

Definition at line 131 of file bcma.h.

#define BCMA_CORE_SHIM   0x837 /* SHIM component in ubus/6362 */

Definition at line 136 of file bcma.h.

#define BCMA_CORE_SPI_HOST   0x833

Definition at line 133 of file bcma.h.

#define BCMA_CORE_SRAM   0x802

Definition at line 84 of file bcma.h.

#define BCMA_CORE_SRAM_CTL   0x822

Definition at line 116 of file bcma.h.

#define BCMA_CORE_USB11_DEV   0x818

Definition at line 106 of file bcma.h.

#define BCMA_CORE_USB11_HOST   0x817

Definition at line 105 of file bcma.h.

#define BCMA_CORE_USB11_HOSTDEV   0x808

Definition at line 90 of file bcma.h.

#define BCMA_CORE_USB20_DEV   0x81A

Definition at line 108 of file bcma.h.

#define BCMA_CORE_USB20_HOST   0x819

Definition at line 107 of file bcma.h.

#define BCMA_CORE_UTOPIA   0x80C

Definition at line 94 of file bcma.h.

#define BCMA_CORE_V90   0x807

Definition at line 89 of file bcma.h.

#define BCMA_DMA_TRANSLATION_DMA32_CMT   0x40000000 /* Client Mode Translation for 32-bit DMA */

Definition at line 350 of file bcma.h.

#define BCMA_DMA_TRANSLATION_DMA64_CMT   0x80000000 /* Client Mode Translation for 64-bit DMA */

Definition at line 351 of file bcma.h.

#define BCMA_DMA_TRANSLATION_MASK   0xC0000000

Definition at line 348 of file bcma.h.

#define BCMA_DMA_TRANSLATION_NONE   0x00000000

Definition at line 349 of file bcma.h.

#define bcma_driver_register (   drv)    __bcma_driver_register(drv, THIS_MODULE)

Definition at line 218 of file bcma.h.

#define BCMA_MANUF_ARM   0x43B

Definition at line 59 of file bcma.h.

#define BCMA_MANUF_BCM   0x4BF

Definition at line 61 of file bcma.h.

#define BCMA_MANUF_MIPS   0x4A7

Definition at line 60 of file bcma.h.

#define BCMA_MAX_NR_CORES   16

Definition at line 139 of file bcma.h.

#define BCMA_PKG_ID_BCM43224_FAB_CSM   0x8

Definition at line 144 of file bcma.h.

#define BCMA_PKG_ID_BCM43224_FAB_SMIC   0xa

Definition at line 145 of file bcma.h.

#define BCMA_PKG_ID_BCM4716   8

Definition at line 161 of file bcma.h.

#define BCMA_PKG_ID_BCM4717   9

Definition at line 162 of file bcma.h.

#define BCMA_PKG_ID_BCM4718   10

Definition at line 163 of file bcma.h.

Enumeration Type Documentation

Enumerator:
BCMA_CLKMODE_FAST 
BCMA_CLKMODE_DYNAMIC 

Definition at line 35 of file bcma.h.

Enumerator:
BCMA_HOSTTYPE_PCI 
BCMA_HOSTTYPE_SDIO 
BCMA_HOSTTYPE_SOC 

Definition at line 18 of file bcma.h.

Function Documentation

int __bcma_driver_register ( struct bcma_driver drv,
struct module owner 
)

Definition at line 336 of file main.c.

int bcma_arch_register_fallback_sprom ( int(*)(struct bcma_bus *bus, struct ssb_sprom *out sprom_callback)

bcma_arch_register_fallback_sprom - Registers a method providing a fallback SPROM if no SPROM is found.

: The callback function.

With this function the architecture implementation may register a callback handler which fills the SPROM data structure. The fallback is used for PCI based BCMA devices, where no valid SPROM can be found in the shadow registers and to provide the SPROM for SoCs where BCMA is to controll the system bus.

This function is useful for weird architectures that have a half-assed BCMA device hardwired to their PCI bus.

This function is available for architecture code, only. So it is not exported.

Definition at line 39 of file sprom.c.

void bcma_core_disable ( struct bcma_device core,
u32  flags 
)

Definition at line 23 of file core.c.

u32 bcma_core_dma_translation ( struct bcma_device core)

Definition at line 112 of file core.c.

int bcma_core_enable ( struct bcma_device core,
u32  flags 
)

Definition at line 38 of file core.c.

bool bcma_core_is_enabled ( struct bcma_device core)

Definition at line 12 of file core.c.

void bcma_core_pll_ctl ( struct bcma_device core,
u32  req,
u32  status,
bool  on 
)

Definition at line 87 of file core.c.

void bcma_core_set_clockmode ( struct bcma_device core,
enum bcma_clkmode  clkmode 
)

Definition at line 56 of file core.c.

void bcma_driver_unregister ( struct bcma_driver drv)

Definition at line 346 of file main.c.

struct bcma_device* bcma_find_core ( struct bcma_bus bus,
u16  coreid 
)
read

Definition at line 72 of file main.c.