drivers/staging/vme_user/vme_bridge.h

Source file repositories/reference/linux-study-clean/drivers/staging/vme_user/vme_bridge.h

File Facts

System
Linux kernel
Corpus path
drivers/staging/vme_user/vme_bridge.h
Extension
.h
Size
5696 bytes
Lines
191
Domain
Driver Families
Bucket
drivers/staging
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

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 int num_errors;	/* Number of errors */
};

struct vme_callback {
	void (*func)(int level, int statid, void *priv_data);
	void *priv_data;
};

struct vme_irq {
	int count;
	struct vme_callback callback[VME_NUM_STATUSID];
};

/* Allow 16 characters for name (including null character) */

Annotation

Implementation Notes