drivers/crypto/hisilicon/sec2/sec_crypto.h
Source file repositories/reference/linux-study-clean/drivers/crypto/hisilicon/sec2/sec_crypto.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/crypto/hisilicon/sec2/sec_crypto.h- Extension
.h- Size
- 6423 bytes
- Lines
- 398
- 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
- No C-style include directives detected by the generator.
Detected Declarations
struct bd_statusstruct sec_sqe_type2struct sec_sqestruct bd3_auth_ivinstruct bd3_skip_datastruct bd3_stream_scenestruct bd3_no_scenestruct bd3_check_sumstruct bd3_tls_type_backstruct sec_sqe3enum sec_calgenum sec_hash_algenum sec_cmodeenum sec_ckey_typeenum sec_bd_typeenum sec_authenum sec_cipher_direnum sec_addr_type
Annotated Snippet
struct bd_status {
u64 tag;
u8 done;
u8 err_type;
u16 flag;
u16 icv;
};
enum {
AUTHPAD_PAD,
AUTHPAD_NOPAD,
};
enum {
AIGEN_GEN,
AIGEN_NOGEN,
};
struct sec_sqe_type2 {
/*
* mac_len: 0~4 bits
* a_key_len: 5~10 bits
* a_alg: 11~16 bits
*/
__le32 mac_key_alg;
/*
* c_icv_len: 0~5 bits
* c_width: 6~8 bits
* c_key_len: 9~11 bits
* c_mode: 12~15 bits
*/
__le16 icvw_kmode;
/* c_alg: 0~3 bits */
__u8 c_alg;
__u8 rsvd4;
/*
* a_len: 0~23 bits
* iv_offset_l: 24~31 bits
*/
__le32 alen_ivllen;
/*
* c_len: 0~23 bits
* iv_offset_h: 24~31 bits
*/
__le32 clen_ivhlen;
__le16 auth_src_offset;
__le16 cipher_src_offset;
__le16 cs_ip_header_offset;
__le16 cs_udp_header_offset;
__le16 pass_word_len;
__le16 dk_len;
__u8 salt3;
__u8 salt2;
__u8 salt1;
__u8 salt0;
__le16 tag;
__le16 rsvd5;
/*
* c_pad_type: 0~3 bits
* c_pad_len: 4~11 bits
* c_pad_data_type: 12~15 bits
*/
__le16 cph_pad;
/* c_pad_len_field: 0~1 bits */
__le16 c_pad_len_field;
__le64 long_a_data_len;
__le64 a_ivin_addr;
__le64 a_key_addr;
__le64 mac_addr;
__le64 c_ivin_addr;
__le64 c_key_addr;
__le64 data_src_addr;
__le64 data_dst_addr;
/*
* done: 0 bit
* icv: 1~3 bits
* csc: 4~6 bits
* flag: 7-10 bits
* dif_check: 11~13 bits
Annotation
- Detected declarations: `struct bd_status`, `struct sec_sqe_type2`, `struct sec_sqe`, `struct bd3_auth_ivin`, `struct bd3_skip_data`, `struct bd3_stream_scene`, `struct bd3_no_scene`, `struct bd3_check_sum`, `struct bd3_tls_type_back`, `struct sec_sqe3`.
- 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.