9 #ifndef VME_TSI148_DRIVER_H 10 #define VME_TSI148_DRIVER_H 75 #define VME_MODE_PREFETCH_ENABLE VME_AM_IS_MEMORY 76 #define _LD_VME_MODE_PREFETCHSZ 24 77 #define VME_MODE_PREFETCH_SIZE(x) (((x)&3)<<_LD_VME_MODE_PREFETCHSZ) 83 #define VME_MODE_MATCH_MASK (3<<30) 84 #define VME_MODE_EXACT_MATCH (2<<30) 85 #define VME_MODE_AS_MATCH (1<<30) 91 typedef volatile uint32_t BERegister;
105 vmeTsi148FindPciBase(
int instance, BERegister **pbase);
116 vmeTsi148InitInstance(
unsigned instance);
128 vmeTsi148ResetXX(BERegister *base);
132 vmeTsi148Reset(
void);
136 vmeTsi148ResetBusXX(BERegister *base);
140 vmeTsi148ResetBus(
void);
169 vmeTsi148OutboundPortCfgXX(
172 unsigned long address_space,
173 unsigned long vme_address,
174 unsigned long pci_address,
175 unsigned long length);
178 vmeTsi148OutboundPortCfg(
180 unsigned long address_space,
181 unsigned long vme_address,
182 unsigned long pci_address,
183 unsigned long length);
188 vmeTsi148InboundPortCfgXX(
191 unsigned long address_space,
192 unsigned long vme_address,
193 unsigned long pci_address,
194 unsigned long length);
197 vmeTsi148InboundPortCfg(
199 unsigned long address_space,
200 unsigned long vme_address,
201 unsigned long pci_address,
202 unsigned long length);
233 vmeTsi148XlateAddrXX(
259 #ifdef _VME_TSI148_DECLARE_SHOW_ROUTINES 266 vmeTsi148OutboundPortsShowXX(BERegister *base, FILE *f);
269 vmeTsi148OutboundPortsShow(FILE *f);
276 vmeTsi148InboundPortsShowXX(BERegister *base, FILE *f);
279 vmeTsi148InboundPortsShow(FILE *f);
286 vmeTsi148DisableAllInboundPortsXX(BERegister *base);
289 vmeTsi148DisableAllInboundPorts(
void);
292 vmeTsi148DisableAllOutboundPortsXX(BERegister *base);
295 vmeTsi148DisableAllOutboundPorts(
void);
297 # define TSI_VEAT_VES (1<<31) 298 # define TSI_VEAT_VEOF (1<<30) 299 # define TSI_VEAT_VESCL (1<<29) 300 # define TSI_VEAT_2eOT (1<<21) 301 # define TSI_VEAT_2eST (1<<20) 302 # define TSI_VEAT_BERR (1<<19) 303 # define TSI_VEAT_LWORD (1<<18) 304 # define TSI_VEAT_WRITE (1<<17) 305 # define TSI_VEAT_IACK (1<<16) 306 # define TSI_VEAT_DS1 (1<<15) 307 # define TSI_VEAT_DS0 (1<<14) 308 # define TSI_VEAT_AM(v) (((v)>>8)&63) 309 # define TSI_VEAT_XAM(v) ((v)&255) 328 vmeTsi148ClearVMEBusErrorsXX(BERegister *base, uint32_t *paddr);
331 vmeTsi148ClearVMEBusErrors(uint32_t *paddr);
352 vmeTsi148MapCRGXX(BERegister *base, uint32_t vme_base, uint32_t address_space);
355 vmeTsi148MapCRG(uint32_t vme_base, uint32_t address_space);
378 typedef void (*VmeTsi148ISR) (
void *usrArg,
unsigned long vector);
384 vmeTsi148InstallISR(
unsigned long vector, VmeTsi148ISR handler,
void *usrArg);
391 vmeTsi148RemoveISR(
unsigned long vector, VmeTsi148ISR handler,
void *usrArg);
397 vmeTsi148ISRGet(
unsigned long vector,
void **parg);
407 vmeTsi148IntEnable(
unsigned int level);
410 vmeTsi148IntDisable(
unsigned int level);
422 vmeTsi148IntIsEnabled(
unsigned int level);
433 vmeTsi148SetIackWidth(
int level,
int width);
471 vmeTsi148IntRoute(
unsigned int level,
unsigned int pin);
502 vmeTsi148IntRaiseXX(BERegister *base,
int level,
unsigned vector);
505 vmeTsi148IntRaise(
int level,
unsigned vector);
531 vmeTsi148IntLoopbackTst(
int level,
unsigned vector);
549 #define TSI_DMA_INT_VEC 257 550 #define TSI_LERR_INT_VEC 258 551 #define TSI_VERR_INT_VEC 259 553 #define TSI_VME_SW_IACK_INT_VEC 261 555 #define TSI_SYSFAIL_INT_VEC 263 556 #define TSI_ACFAIL_INT_VEC 264 557 #define TSI_MBOX0_INT_VEC 265 558 #define TSI_MBOX1_INT_VEC 266 559 #define TSI_MBOX2_INT_VEC 267 560 #define TSI_MBOX3_INT_VEC 268 561 #define TSI_LM0_INT_VEC 269 562 #define TSI_LM1_INT_VEC 270 563 #define TSI_LM2_INT_VEC 271 564 #define TSI_LM3_INT_VEC 272 567 #define TSI_VIES_INT_VEC 273 568 #define TSI_DMA1_INT_VEC 274 570 #define TSI_NUM_INT_VECS 275 572 #ifdef __INSIDE_RTEMS_BSP__ 650 #define VMETSI148_IRQ_MGR_FLAG_SHARED 1 652 vmeTsi148InstallIrqMgrAlt(
int shared,
int tsi_pin0,
int pic_pin0, ...);
655 vmeTsi148InstallIrqMgrVa(
int shared,
int tsi_pin0,
int pic_pin0, va_list ap);
vxworks compatible addressing modes