arch/mips/include/asm/octeon/cvmx-coremask.h
Source file repositories/reference/linux-study-clean/arch/mips/include/asm/octeon/cvmx-coremask.h
File Facts
- System
- Linux kernel
- Corpus path
arch/mips/include/asm/octeon/cvmx-coremask.h- Extension
.h- Size
- 2176 bytes
- Lines
- 90
- Domain
- Architecture Layer
- Bucket
- arch/mips
- Inferred role
- Architecture Layer: implementation source
- Status
- source implementation candidate
Why This File Exists
CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- 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 cvmx_coremaskfunction cvmx_coremask_is_core_setfunction cvmx_coremask_copyfunction cvmx_coremask_set64function cvmx_coremask_clear_core
Annotated Snippet
struct cvmx_coremask {
u64 coremask_bitmap[CVMX_COREMASK_BMPSZ];
};
/*
* Is ``core'' set in the coremask?
*/
static inline bool cvmx_coremask_is_core_set(const struct cvmx_coremask *pcm,
int core)
{
int n, i;
n = core % CVMX_COREMASK_ELTSZ;
i = core / CVMX_COREMASK_ELTSZ;
return (pcm->coremask_bitmap[i] & ((u64)1 << n)) != 0;
}
/*
* Make a copy of a coremask
*/
static inline void cvmx_coremask_copy(struct cvmx_coremask *dest,
const struct cvmx_coremask *src)
{
memcpy(dest, src, sizeof(*dest));
}
/*
* Set the lower 64-bit of the coremask.
*/
static inline void cvmx_coremask_set64(struct cvmx_coremask *pcm,
uint64_t coremask_64)
{
pcm->coremask_bitmap[0] = coremask_64;
}
/*
* Clear ``core'' from the coremask.
*/
static inline void cvmx_coremask_clear_core(struct cvmx_coremask *pcm, int core)
{
int n, i;
n = core % CVMX_COREMASK_ELTSZ;
i = core / CVMX_COREMASK_ELTSZ;
pcm->coremask_bitmap[i] &= ~(1ull << n);
}
#endif /* __CVMX_COREMASK_H__ */
Annotation
- Detected declarations: `struct cvmx_coremask`, `function cvmx_coremask_is_core_set`, `function cvmx_coremask_copy`, `function cvmx_coremask_set64`, `function cvmx_coremask_clear_core`.
- Atlas domain: Architecture Layer / arch/mips.
- 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.