arch/m68k/mac/misc.c
Source file repositories/reference/linux-study-clean/arch/m68k/mac/misc.c
File Facts
- System
- Linux kernel
- Corpus path
arch/m68k/mac/misc.c- Extension
.c- Size
- 16179 bytes
- Lines
- 667
- Domain
- Architecture Layer
- Bucket
- arch/m68k
- 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/types.hlinux/errno.hlinux/kernel.hlinux/delay.hlinux/sched.hlinux/time.hlinux/rtc.hlinux/mm.hlinux/adb.hlinux/cuda.hlinux/pmu.hlinux/uaccess.hasm/io.hasm/setup.hasm/macintosh.hasm/mac_via.hasm/mac_oss.hasm/machdep.hmac.h
Detected Declarations
function cuda_pram_read_bytefunction cuda_pram_write_bytefunction pmu_pram_read_bytefunction pmu_pram_write_bytefunction via_rtc_recvfunction via_rtc_sendfunction via_rtc_commandfunction via_pram_read_bytefunction via_pram_write_bytefunction via_read_timefunction via_set_rtc_timefunction via_shutdownfunction oss_shutdownfunction cuda_restartfunction cuda_shutdownfunction mac_pram_read_bytefunction mac_pram_write_bytefunction mac_pram_get_sizefunction mac_powerofffunction mac_resetfunction rtc_time64_to_tmfunction mac_hwclk
Annotated Snippet
switch (macintosh_config->adb_type) {
case MAC_ADB_IOP:
case MAC_ADB_II:
case MAC_ADB_PB1:
now = via_read_time();
break;
#ifdef CONFIG_ADB_CUDA
case MAC_ADB_EGRET:
case MAC_ADB_CUDA:
now = cuda_get_time();
break;
#endif
#ifdef CONFIG_ADB_PMU
case MAC_ADB_PB2:
now = pmu_get_time();
break;
#endif
default:
now = 0;
}
t->tm_wday = 0;
unmktime(now, 0,
&t->tm_year, &t->tm_mon, &t->tm_mday,
&t->tm_hour, &t->tm_min, &t->tm_sec);
pr_debug("%s: read %ptR\n", __func__, t);
} else { /* write */
pr_debug("%s: tried to write %ptR\n", __func__, t);
switch (macintosh_config->adb_type) {
case MAC_ADB_IOP:
case MAC_ADB_II:
case MAC_ADB_PB1:
via_set_rtc_time(t);
break;
#ifdef CONFIG_ADB_CUDA
case MAC_ADB_EGRET:
case MAC_ADB_CUDA:
cuda_set_rtc_time(t);
break;
#endif
#ifdef CONFIG_ADB_PMU
case MAC_ADB_PB2:
pmu_set_rtc_time(t);
break;
#endif
default:
return -ENODEV;
}
}
return 0;
}
Annotation
- Immediate include surface: `linux/types.h`, `linux/errno.h`, `linux/kernel.h`, `linux/delay.h`, `linux/sched.h`, `linux/time.h`, `linux/rtc.h`, `linux/mm.h`.
- Detected declarations: `function cuda_pram_read_byte`, `function cuda_pram_write_byte`, `function pmu_pram_read_byte`, `function pmu_pram_write_byte`, `function via_rtc_recv`, `function via_rtc_send`, `function via_rtc_command`, `function via_pram_read_byte`, `function via_pram_write_byte`, `function via_read_time`.
- Atlas domain: Architecture Layer / arch/m68k.
- 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.