arch/mips/pci/pci-ip27.c
Source file repositories/reference/linux-study-clean/arch/mips/pci/pci-ip27.c
File Facts
- System
- Linux kernel
- Corpus path
arch/mips/pci/pci-ip27.c- Extension
.c- Size
- 1202 bytes
- Lines
- 46
- Domain
- Architecture Layer
- Bucket
- arch/mips
- Inferred role
- Architecture Layer: exported/initcall integration point
- Status
- integration 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.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/io.hasm/sn/addrs.hasm/sn/types.hasm/sn/klconfig.hasm/sn/agent.hasm/sn/ioc3.hasm/pci/bridge.h
Detected Declarations
function Copyrightfunction ip29_fixup_phyexport pcibus_to_node
Annotated Snippet
#include <linux/io.h>
#include <asm/sn/addrs.h>
#include <asm/sn/types.h>
#include <asm/sn/klconfig.h>
#include <asm/sn/agent.h>
#include <asm/sn/ioc3.h>
#include <asm/pci/bridge.h>
#ifdef CONFIG_NUMA
int pcibus_to_node(struct pci_bus *bus)
{
struct bridge_controller *bc = BRIDGE_CONTROLLER(bus);
return bc->nasid;
}
EXPORT_SYMBOL(pcibus_to_node);
#endif /* CONFIG_NUMA */
static void ip29_fixup_phy(struct pci_dev *dev)
{
int nasid = pcibus_to_node(dev->bus);
u32 sid;
if (nasid != 1)
return; /* only needed on second module */
/* enable ethernet PHY on IP29 systemboard */
pci_read_config_dword(dev, PCI_SUBSYSTEM_VENDOR_ID, &sid);
if (sid == (PCI_VENDOR_ID_SGI | (IOC3_SUBSYS_IP29_SYSBOARD) << 16))
REMOTE_HUB_S(nasid, MD_LED0, 0x09);
}
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_SGI, PCI_DEVICE_ID_SGI_IOC3,
ip29_fixup_phy);
Annotation
- Immediate include surface: `linux/io.h`, `asm/sn/addrs.h`, `asm/sn/types.h`, `asm/sn/klconfig.h`, `asm/sn/agent.h`, `asm/sn/ioc3.h`, `asm/pci/bridge.h`.
- Detected declarations: `function Copyright`, `function ip29_fixup_phy`, `export pcibus_to_node`.
- Atlas domain: Architecture Layer / arch/mips.
- 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.