X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fatm%2Ffore200e.h;h=492f7f549ebb2d3626775f776d503d6a84d0653e;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=0b2168274025bfb5a58de9d8f5676d24f470c7e5;hpb=5273a3df6485dc2ad6aa7ddd441b9a21970f003b;p=linux-2.6.git diff --git a/drivers/atm/fore200e.h b/drivers/atm/fore200e.h index 0b2168274..492f7f549 100644 --- a/drivers/atm/fore200e.h +++ b/drivers/atm/fore200e.h @@ -520,7 +520,7 @@ typedef struct cp_cmdq_entry { /* host resident transmit queue entry */ typedef struct host_txq_entry { - struct cp_txq_entry* cp_entry; /* addr of cp resident tx queue entry */ + struct cp_txq_entry __iomem *cp_entry; /* addr of cp resident tx queue entry */ enum status* status; /* addr of host resident status */ struct tpd* tpd; /* addr of transmit PDU descriptor */ u32 tpd_dma; /* DMA address of tpd */ @@ -535,7 +535,7 @@ typedef struct host_txq_entry { /* host resident receive queue entry */ typedef struct host_rxq_entry { - struct cp_rxq_entry* cp_entry; /* addr of cp resident rx queue entry */ + struct cp_rxq_entry __iomem *cp_entry; /* addr of cp resident rx queue entry */ enum status* status; /* addr of host resident status */ struct rpd* rpd; /* addr of receive PDU descriptor */ u32 rpd_dma; /* DMA address of rpd */ @@ -545,7 +545,7 @@ typedef struct host_rxq_entry { /* host resident buffer supply queue entry */ typedef struct host_bsq_entry { - struct cp_bsq_entry* cp_entry; /* addr of cp resident buffer supply queue entry */ + struct cp_bsq_entry __iomem *cp_entry; /* addr of cp resident buffer supply queue entry */ enum status* status; /* addr of host resident status */ struct rbd_block* rbd_block; /* addr of receive buffer descriptor block */ u32 rbd_block_dma; /* DMA address od rdb */ @@ -555,8 +555,8 @@ typedef struct host_bsq_entry { /* host resident command queue entry */ typedef struct host_cmdq_entry { - struct cp_cmdq_entry* cp_entry; /* addr of cp resident cmd queue entry */ - enum status* status; /* addr of host resident status */ + struct cp_cmdq_entry __iomem *cp_entry; /* addr of cp resident cmd queue entry */ + enum status *status; /* addr of host resident status */ } host_cmdq_entry_t; @@ -565,7 +565,7 @@ typedef struct host_cmdq_entry { typedef struct chunk { void* alloc_addr; /* base address of allocated chunk */ void* align_addr; /* base address of aligned chunk */ - u32 dma_addr; /* DMA address of aligned chunk */ + dma_addr_t dma_addr; /* DMA address of aligned chunk */ int direction; /* direction of DMA mapping */ u32 alloc_size; /* length of allocated chunk */ u32 align_size; /* length of aligned chunk */ @@ -645,7 +645,7 @@ typedef struct host_bsq { typedef struct fw_header { u32 magic; /* magic number */ - u32 version; /* firware version id */ + u32 version; /* firmware version id */ u32 load_offset; /* fw load offset in board memory */ u32 start_offset; /* fw execution start address in board memory */ } fw_header_t; @@ -668,7 +668,7 @@ typedef struct bs_spec { typedef struct init_block { enum opcode opcode; /* initialize command */ - enum status status; /* related status word */ + enum status status; /* related status word */ u32 receive_threshold; /* not used */ u32 num_connect; /* ATM connections */ u32 cmd_queue_len; /* length of command queue */ @@ -772,18 +772,18 @@ typedef enum fore200e_state { /* PCA-200E registers */ typedef struct fore200e_pca_regs { - volatile u32* hcr; /* address of host control register */ - volatile u32* imr; /* address of host interrupt mask register */ - volatile u32* psr; /* address of PCI specific register */ + volatile u32 __iomem * hcr; /* address of host control register */ + volatile u32 __iomem * imr; /* address of host interrupt mask register */ + volatile u32 __iomem * psr; /* address of PCI specific register */ } fore200e_pca_regs_t; /* SBA-200E registers */ typedef struct fore200e_sba_regs { - volatile u32* hcr; /* address of host control register */ - volatile u32* bsr; /* address of burst transfer size register */ - volatile u32* isr; /* address of interrupt level selection register */ + volatile u32 __iomem *hcr; /* address of host control register */ + volatile u32 __iomem *bsr; /* address of burst transfer size register */ + volatile u32 __iomem *isr; /* address of interrupt level selection register */ } fore200e_sba_regs_t; @@ -807,8 +807,8 @@ typedef struct fore200e_bus { int status_alignment; /* status words DMA alignment requirement */ const unsigned char* fw_data; /* address of firmware data start */ const unsigned int* fw_size; /* address of firmware data size */ - u32 (*read)(volatile u32*); - void (*write)(u32, volatile u32*); + u32 (*read)(volatile u32 __iomem *); + void (*write)(u32, volatile u32 __iomem *); u32 (*dma_map)(struct fore200e*, void*, int, int); void (*dma_unmap)(struct fore200e*, u32, int, int); void (*dma_sync_for_cpu)(struct fore200e*, u32, int, int); @@ -827,36 +827,6 @@ typedef struct fore200e_bus { int (*proc_read)(struct fore200e*, char*); } fore200e_bus_t; - -#if defined(CONFIG_ATM_FORE200E_SBA) -# if defined(CONFIG_ATM_FORE200E_PCA) -# if (PCI_DMA_BIDIRECTIONAL == SBUS_DMA_BIDIRECTIONAL) && \ - (PCI_DMA_TODEVICE == SBUS_DMA_TODEVICE) && \ - (PCI_DMA_FROMDEVICE == SBUS_DMA_FROMDEVICE) -# define FORE200E_DMA_BIDIRECTIONAL PCI_DMA_BIDIRECTIONAL -# define FORE200E_DMA_TODEVICE PCI_DMA_TODEVICE -# define FORE200E_DMA_FROMDEVICE PCI_DMA_FROMDEVICE -# else - /* in that case, we'll need to add an extra indirection, e.g. - fore200e->bus->dma_direction[ fore200e_dma_direction ] */ -# error PCI and SBUS DMA direction flags have different values! -# endif -# else -# define FORE200E_DMA_BIDIRECTIONAL SBUS_DMA_BIDIRECTIONAL -# define FORE200E_DMA_TODEVICE SBUS_DMA_TODEVICE -# define FORE200E_DMA_FROMDEVICE SBUS_DMA_FROMDEVICE -# endif -#else -# ifndef CONFIG_ATM_FORE200E_PCA -# warning compiling the fore200e driver without any hardware support enabled! -# include -# endif -# define FORE200E_DMA_BIDIRECTIONAL PCI_DMA_BIDIRECTIONAL -# define FORE200E_DMA_TODEVICE PCI_DMA_TODEVICE -# define FORE200E_DMA_FROMDEVICE PCI_DMA_FROMDEVICE -#endif - - /* vc mapping */ typedef struct fore200e_vc_map { @@ -882,12 +852,12 @@ typedef struct fore200e { void* bus_dev; /* bus-specific kernel data */ int irq; /* irq number */ unsigned long phys_base; /* physical base address */ - void* virt_base; /* virtual base address */ + void __iomem * virt_base; /* virtual base address */ unsigned char esi[ ESI_LEN ]; /* end system identifier */ - struct cp_monitor* cp_monitor; /* i960 monitor address */ - struct cp_queues* cp_queues; /* cp resident queues */ + struct cp_monitor __iomem * cp_monitor; /* i960 monitor address */ + struct cp_queues __iomem * cp_queues; /* cp resident queues */ struct host_cmdq host_cmdq; /* host resident cmd queue */ struct host_txq host_txq; /* host resident tx queue */ struct host_rxq host_rxq; /* host resident rx queue */