arch/sparc/kernel/cpu.c
Source file repositories/reference/linux-study-clean/arch/sparc/kernel/cpu.c
File Facts
- System
- Linux kernel
- Corpus path
arch/sparc/kernel/cpu.c- Extension
.c- Size
- 12429 bytes
- Lines
- 557
- Domain
- Architecture Layer
- Bucket
- arch/sparc
- 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
linux/seq_file.hlinux/kernel.hlinux/export.hlinux/init.hlinux/smp.hlinux/threads.hlinux/pgtable.hasm/spitfire.hasm/oplib.hasm/setup.hasm/page.hasm/head.hasm/psr.hasm/mbus.hasm/cpudata.hkernel.hentry.h
Detected Declarations
struct cpu_infostruct fpu_infostruct manufacturer_infofunction set_cpu_and_fpufunction show_cpuinfofunction show_cpuinfofunction c_stopfunction cpu_type_probefunction sun4v_cpu_probefunction cpu_type_probe
Annotated Snippet
struct cpu_info {
int psr_vers;
const char *name;
const char *pmu_name;
};
struct fpu_info {
int fp_vers;
const char *name;
};
#define NOCPU 8
#define NOFPU 8
struct manufacturer_info {
int psr_impl;
struct cpu_info cpu_info[NOCPU];
struct fpu_info fpu_info[NOFPU];
};
#define CPU(ver, _name) \
{ .psr_vers = ver, .name = _name }
#define CPU_PMU(ver, _name, _pmu_name) \
{ .psr_vers = ver, .name = _name, .pmu_name = _pmu_name }
#define FPU(ver, _name) \
{ .fp_vers = ver, .name = _name }
static const struct manufacturer_info __initconst manufacturer_info[] = {
{
0,
/* Sun4/100, 4/200, SLC */
.cpu_info = {
CPU(0, "Fujitsu MB86900/1A or LSI L64831 SparcKIT-40"),
/* borned STP1012PGA */
CPU(4, "Fujitsu MB86904"),
CPU(5, "Fujitsu TurboSparc MB86907"),
CPU(-1, NULL)
},
.fpu_info = {
FPU(0, "Fujitsu MB86910 or Weitek WTL1164/5"),
FPU(1, "Fujitsu MB86911 or Weitek WTL1164/5 or LSI L64831"),
FPU(2, "LSI Logic L64802 or Texas Instruments ACT8847"),
/* SparcStation SLC, SparcStation1 */
FPU(3, "Weitek WTL3170/2"),
/* SPARCstation-5 */
FPU(4, "Lsi Logic/Meiko L64804 or compatible"),
FPU(-1, NULL)
}
},{
1,
.cpu_info = {
/* SparcStation2, SparcServer 490 & 690 */
CPU(0, "LSI Logic Corporation - L64811"),
/* SparcStation2 */
CPU(1, "Cypress/ROSS CY7C601"),
/* Embedded controller */
CPU(3, "Cypress/ROSS CY7C611"),
/* Ross Technologies HyperSparc */
CPU(0xf, "ROSS HyperSparc RT620"),
CPU(0xe, "ROSS HyperSparc RT625 or RT626"),
CPU(-1, NULL)
},
.fpu_info = {
FPU(0, "ROSS HyperSparc combined IU/FPU"),
FPU(1, "Lsi Logic L64814"),
FPU(2, "Texas Instruments TMS390-C602A"),
FPU(3, "Cypress CY7C602 FPU"),
FPU(-1, NULL)
}
},{
2,
.cpu_info = {
/* ECL Implementation, CRAY S-MP Supercomputer... AIEEE! */
/* Someone please write the code to support this beast! ;) */
CPU(0, "Bipolar Integrated Technology - B5010"),
CPU(-1, NULL)
},
.fpu_info = {
FPU(-1, NULL)
}
},{
3,
.cpu_info = {
CPU(0, "LSI Logic Corporation - unknown-type"),
CPU(-1, NULL)
},
.fpu_info = {
FPU(-1, NULL)
Annotation
- Immediate include surface: `linux/seq_file.h`, `linux/kernel.h`, `linux/export.h`, `linux/init.h`, `linux/smp.h`, `linux/threads.h`, `linux/pgtable.h`, `asm/spitfire.h`.
- Detected declarations: `struct cpu_info`, `struct fpu_info`, `struct manufacturer_info`, `function set_cpu_and_fpu`, `function show_cpuinfo`, `function show_cpuinfo`, `function c_stop`, `function cpu_type_probe`, `function sun4v_cpu_probe`, `function cpu_type_probe`.
- Atlas domain: Architecture Layer / arch/sparc.
- 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.