crypto/xts.c
Source file repositories/reference/linux-study-clean/crypto/xts.c
File Facts
- System
- Linux kernel
- Corpus path
crypto/xts.c- Extension
.c- Size
- 12192 bytes
- Lines
- 477
- Domain
- Kernel Services
- Bucket
- crypto
- Inferred role
- Kernel Services: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Shared kernel service surface used by multiple subsystems, including helpers, cryptography, virtualization support, and async I/O infrastructure.
- Shared kernel service surface used by multiple subsystems, including helpers, cryptography, virtualization support, and async I/O infrastructure.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- 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
crypto/internal/cipher.hcrypto/internal/skcipher.hcrypto/scatterwalk.hlinux/err.hlinux/init.hlinux/kernel.hlinux/module.hlinux/scatterlist.hlinux/slab.hcrypto/xts.hcrypto/b128ops.hcrypto/gf128mul.h
Detected Declarations
struct xts_tfm_ctxstruct xts_instance_ctxstruct xts_request_ctxfunction xts_setkeyfunction twicefunction xts_xor_tweak_prefunction xts_xor_tweak_postfunction xts_cts_donefunction xts_cts_finalfunction xts_encrypt_donefunction xts_decrypt_donefunction xts_init_cryptfunction xts_encryptfunction xts_decryptfunction xts_init_tfmfunction xts_exit_tfmfunction xts_free_instancefunction xts_createfunction xts_module_initfunction xts_module_exitmodule init xts_module_init
Annotated Snippet
module_init(xts_module_init);
module_exit(xts_module_exit);
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("XTS block cipher mode");
MODULE_ALIAS_CRYPTO("xts");
MODULE_IMPORT_NS("CRYPTO_INTERNAL");
MODULE_SOFTDEP("pre: ecb");
Annotation
- Immediate include surface: `crypto/internal/cipher.h`, `crypto/internal/skcipher.h`, `crypto/scatterwalk.h`, `linux/err.h`, `linux/init.h`, `linux/kernel.h`, `linux/module.h`, `linux/scatterlist.h`.
- Detected declarations: `struct xts_tfm_ctx`, `struct xts_instance_ctx`, `struct xts_request_ctx`, `function xts_setkey`, `function twice`, `function xts_xor_tweak_pre`, `function xts_xor_tweak_post`, `function xts_cts_done`, `function xts_cts_final`, `function xts_encrypt_done`.
- Atlas domain: Kernel Services / crypto.
- Implementation status: integration 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.