drivers/net/ethernet/ibm/emac/zmii.h
Source file repositories/reference/linux-study-clean/drivers/net/ethernet/ibm/emac/zmii.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/ethernet/ibm/emac/zmii.h- Extension
.h- Size
- 2103 bytes
- Lines
- 75
- Domain
- Driver Families
- Bucket
- drivers/net
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- 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 zmii_regsstruct zmii_instance
Annotated Snippet
struct zmii_regs {
u32 fer; /* Function enable reg */
u32 ssr; /* Speed select reg */
u32 smiirs; /* SMII status reg */
};
/* ZMII device */
struct zmii_instance {
struct zmii_regs __iomem *base;
/* Only one EMAC whacks us at a time */
struct mutex lock;
/* subset of PHY_MODE_XXXX */
int mode;
/* number of EMACs using this ZMII bridge */
int users;
/* FER value left by firmware */
u32 fer_save;
/* OF device instance */
struct platform_device *ofdev;
};
#ifdef CONFIG_IBM_EMAC_ZMII
int zmii_init(void);
void zmii_exit(void);
int zmii_attach(struct platform_device *ofdev, int input,
phy_interface_t *mode);
void zmii_detach(struct platform_device *ofdev, int input);
void zmii_get_mdio(struct platform_device *ofdev, int input);
void zmii_put_mdio(struct platform_device *ofdev, int input);
void zmii_set_speed(struct platform_device *ofdev, int input, int speed);
int zmii_get_regs_len(struct platform_device *ocpdev);
void *zmii_dump_regs(struct platform_device *ofdev, void *buf);
#else
# define zmii_init() 0
# define zmii_exit() do { } while(0)
# define zmii_attach(x,y,z) (-ENXIO)
# define zmii_detach(x,y) do { } while(0)
# define zmii_get_mdio(x,y) do { } while(0)
# define zmii_put_mdio(x,y) do { } while(0)
# define zmii_set_speed(x,y,z) do { } while(0)
# define zmii_get_regs_len(x) 0
# define zmii_dump_regs(x,buf) (buf)
#endif /* !CONFIG_IBM_EMAC_ZMII */
#endif /* __IBM_NEWEMAC_ZMII_H */
Annotation
- Detected declarations: `struct zmii_regs`, `struct zmii_instance`.
- Atlas domain: Driver Families / drivers/net.
- 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.