Source
x
* The structure should be dynamically allocated by the driver and one instance
/* SPDX-License-Identifier: GPL-2.0 */
/*
* Resource structures
*/
struct vme_master_resource {
struct list_head list;
struct vme_bridge *parent;
/*
* We are likely to need to access the VME bus in interrupt context, so
* protect master routines with a spinlock rather than a mutex.
*/
spinlock_t lock;
int locked;
int number;
u32 address_attr;
u32 cycle_attr;
u32 width_attr;
struct resource bus_resource;
void __iomem *kern_base;
};
struct vme_slave_resource {
struct list_head list;
struct vme_bridge *parent;
struct mutex mtx;
int locked;
int number;
u32 address_attr;
u32 cycle_attr;
};
struct vme_dma_pattern {
u32 pattern;
u32 type;
};
struct vme_dma_pci {
dma_addr_t address;
};
struct vme_dma_vme {
unsigned long long address;
u32 aspace;
u32 cycle;
u32 dwidth;
};
struct vme_dma_list {
struct list_head list;
struct vme_dma_resource *parent;
struct list_head entries;
struct mutex mtx;
};
struct vme_dma_resource {
struct list_head list;
struct vme_bridge *parent;
struct mutex mtx;
int locked;
int number;
struct list_head pending;
struct list_head running;
u32 route_attr;
};
struct vme_lm_resource {
struct list_head list;
struct vme_bridge *parent;
struct mutex mtx;
int locked;
int number;
int monitors;
};
struct vme_error_handler {
struct list_head list;
unsigned long long start; /* Beginning of error window */
unsigned long long end; /* End of error window */
unsigned long long first_error; /* Address of the first error */
u32 aspace; /* Address space of error window*/
unsigned num_errors; /* Number of errors */
};
struct vme_callback {
void (*func)(int, int, void*);
void *priv_data;