drivers/scsi/esas2r/esas2r.h
Source file repositories/reference/linux-study-clean/drivers/scsi/esas2r/esas2r.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/scsi/esas2r/esas2r.h- Extension
.h- Size
- 44192 bytes
- Lines
- 1423
- Domain
- Driver Families
- Bucket
- drivers/scsi
- 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.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/kernel.hlinux/delay.hlinux/pci.hlinux/proc_fs.hlinux/workqueue.hlinux/interrupt.hlinux/module.hlinux/vmalloc.hscsi/scsi.hscsi/scsi_host.hscsi/scsi_cmnd.hscsi/scsi_device.hscsi/scsi_eh.hscsi/scsi_tcq.hesas2r_log.hatioctl.hatvda.h
Detected Declarations
struct esas2r_inbound_list_source_entrystruct esas2r_adapterstruct esas2r_sg_contextstruct esas2r_requeststruct esas2r_component_headerstruct esas2r_flash_img_v0struct esas2r_flash_imgstruct esas2r_ioctlfs_commandstruct esas2r_ioctl_fsstruct esas2r_sas_nvramstruct esas2r_sg_contextstruct esas2r_targetstruct esas2r_requeststruct esas2r_flash_contextstruct esas2r_disc_contextstruct esas2r_mem_descstruct esas2r_vda_aestruct esas2r_fw_event_workstruct esas2r_firmwarestruct esas2r_adapterenum fw_event_typeenum statefunction esas2r_sgc_initfunction esas2r_rq_init_requestfunction esas2r_rq_free_sg_listsfunction esas2r_rq_destroy_requestfunction esas2r_is_tasklet_pendingfunction esas2r_sgc_initfunction esas2r_disable_chip_interruptsfunction esas2r_enable_chip_interruptsfunction esas2r_schedule_taskletfunction esas2r_enable_heartbeatfunction esas2r_disable_heartbeatfunction esas2r_local_reset_adapterfunction esas2r_adapter_interrupt_pendingfunction esas2r_targ_get_idfunction esas2r_start_ae_requestfunction esas2r_comp_list_drainfunction list_for_each_safe
Annotated Snippet
struct esas2r_inbound_list_source_entry {
u64 address;
u32 length;
#define HWILSE_INTERFACE_F0 0x00000000
u32 reserved;
};
/* PCI data structure in expansion ROM images */
struct __packed esas2r_boot_header {
char signature[4];
u16 vendor_id;
u16 device_id;
u16 VPD;
u16 struct_length;
u8 struct_revision;
u8 class_code[3];
u16 image_length;
u16 code_revision;
u8 code_type;
#define CODE_TYPE_PC 0
#define CODE_TYPE_OPEN 1
#define CODE_TYPE_EFI 3
u8 indicator;
#define INDICATOR_LAST 0x80
u8 reserved[2];
};
struct __packed esas2r_boot_image {
u16 signature;
u8 reserved[22];
u16 header_offset;
u16 pnp_offset;
};
struct __packed esas2r_pc_image {
u16 signature;
u8 length;
u8 entry_point[3];
u8 checksum;
u16 image_end;
u16 min_size;
u8 rom_flags;
u8 reserved[12];
u16 header_offset;
u16 pnp_offset;
struct esas2r_boot_header boot_image;
};
struct __packed esas2r_efi_image {
u16 signature;
u16 length;
u32 efi_signature;
#define EFI_ROM_SIG 0x00000EF1
u16 image_type;
#define EFI_IMAGE_APP 10
#define EFI_IMAGE_BSD 11
#define EFI_IMAGE_RTD 12
u16 machine_type;
#define EFI_MACHINE_IA32 0x014c
#define EFI_MACHINE_IA64 0x0200
#define EFI_MACHINE_X64 0x8664
#define EFI_MACHINE_EBC 0x0EBC
u16 compression;
#define EFI_UNCOMPRESSED 0x0000
#define EFI_COMPRESSED 0x0001
u8 reserved[8];
u16 efi_offset;
u16 header_offset;
u16 reserved2;
struct esas2r_boot_header boot_image;
};
struct esas2r_adapter;
struct esas2r_sg_context;
struct esas2r_request;
typedef void (*RQCALLBK) (struct esas2r_adapter *a,
struct esas2r_request *rq);
typedef bool (*RQBUILDSGL) (struct esas2r_adapter *a,
struct esas2r_sg_context *sgc);
struct esas2r_component_header {
u8 img_type;
#define CH_IT_FW 0x00
#define CH_IT_NVR 0x01
#define CH_IT_BIOS 0x02
#define CH_IT_MAC 0x03
#define CH_IT_CFG 0x04
#define CH_IT_EFI 0x05
u8 status;
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/delay.h`, `linux/pci.h`, `linux/proc_fs.h`, `linux/workqueue.h`, `linux/interrupt.h`, `linux/module.h`, `linux/vmalloc.h`.
- Detected declarations: `struct esas2r_inbound_list_source_entry`, `struct esas2r_adapter`, `struct esas2r_sg_context`, `struct esas2r_request`, `struct esas2r_component_header`, `struct esas2r_flash_img_v0`, `struct esas2r_flash_img`, `struct esas2r_ioctlfs_command`, `struct esas2r_ioctl_fs`, `struct esas2r_sas_nvram`.
- Atlas domain: Driver Families / drivers/scsi.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
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.