drivers/crypto/ccp/sp-dev.h
Source file repositories/reference/linux-study-clean/drivers/crypto/ccp/sp-dev.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/crypto/ccp/sp-dev.h- Extension
.h- Size
- 4938 bytes
- Lines
- 191
- Domain
- Driver Families
- Bucket
- drivers/crypto
- 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.
- 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.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/device.hlinux/spinlock.hlinux/mutex.hlinux/list.hlinux/wait.hlinux/dmapool.hlinux/hw_random.hlinux/bitops.hlinux/interrupt.hlinux/irqreturn.h
Detected Declarations
struct ccp_devicestruct ccp_vdatastruct sev_vdatastruct tee_vdatastruct platform_access_vdatastruct psp_vdatastruct sp_dev_vdatastruct sp_devicefunction ccp_dev_initfunction ccp_dev_destroyfunction psp_dev_initfunction psp_pci_init
Annotated Snippet
struct ccp_vdata {
const unsigned int version;
const unsigned int dma_chan_attr;
void (*setup)(struct ccp_device *);
const struct ccp_actions *perform;
const unsigned int offset;
const unsigned int rsamax;
};
struct sev_vdata {
const unsigned int cmdresp_reg;
const unsigned int cmdbuff_addr_lo_reg;
const unsigned int cmdbuff_addr_hi_reg;
};
struct tee_vdata {
const unsigned int cmdresp_reg;
const unsigned int cmdbuff_addr_lo_reg;
const unsigned int cmdbuff_addr_hi_reg;
const unsigned int ring_wptr_reg;
const unsigned int ring_rptr_reg;
const unsigned int info_reg;
};
struct platform_access_vdata {
const unsigned int cmdresp_reg;
const unsigned int cmdbuff_addr_lo_reg;
const unsigned int cmdbuff_addr_hi_reg;
const unsigned int doorbell_button_reg;
const unsigned int doorbell_cmd_reg;
};
struct psp_vdata {
const struct sev_vdata *sev;
const struct tee_vdata *tee;
const struct platform_access_vdata *platform_access;
const unsigned int cmdresp_reg;
const unsigned int cmdbuff_addr_lo_reg;
const unsigned int cmdbuff_addr_hi_reg;
const unsigned int feature_reg;
const unsigned int inten_reg;
const unsigned int intsts_reg;
const unsigned int bootloader_info_reg;
const unsigned int platform_features;
};
/* Structure to hold SP device data */
struct sp_dev_vdata {
const unsigned int bar;
const struct ccp_vdata *ccp_vdata;
const struct psp_vdata *psp_vdata;
};
struct sp_device {
struct list_head entry;
struct device *dev;
const struct sp_dev_vdata *dev_vdata;
unsigned int ord;
char name[SP_MAX_NAME_LEN];
/* Bus specific device information */
void *dev_specific;
/* I/O area used for device communication. */
void __iomem *io_map;
/* DMA caching attribute support */
unsigned int axcache;
/* get and set master device */
struct sp_device*(*get_psp_master_device)(void);
void (*set_psp_master_device)(struct sp_device *);
void (*clear_psp_master_device)(struct sp_device *);
bool irq_registered;
bool use_tasklet;
unsigned int ccp_irq;
irq_handler_t ccp_irq_handler;
void *ccp_irq_data;
unsigned int psp_irq;
irq_handler_t psp_irq_handler;
void *psp_irq_data;
void *ccp_data;
Annotation
- Immediate include surface: `linux/device.h`, `linux/spinlock.h`, `linux/mutex.h`, `linux/list.h`, `linux/wait.h`, `linux/dmapool.h`, `linux/hw_random.h`, `linux/bitops.h`.
- Detected declarations: `struct ccp_device`, `struct ccp_vdata`, `struct sev_vdata`, `struct tee_vdata`, `struct platform_access_vdata`, `struct psp_vdata`, `struct sp_dev_vdata`, `struct sp_device`, `function ccp_dev_init`, `function ccp_dev_destroy`.
- Atlas domain: Driver Families / drivers/crypto.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.