CodingBox Dokumentasi

Antara muka bebas media: sisi elektrik port

Pasukan kami sedang menyiapkan terjemahan. Artikel ini buat sementara waktu belum tersedia dalam bahasa Melayu dan dipaparkan dalam bahasa Inggeris.

Between the Ethernet MAC inside a switch ASIC or NIC controller and the medium — copper pair, fibre, backplane — sits a standardised electrical interface. IEEE calls the family media-independent interfaces (MII): the MAC does not care whether the far side is a copper PHY, an SFP cage or a 400G module, as long as it speaks the agreed interface. Every generation of Ethernet added one: MII and RMII for 10/100, GMII/RGMII/SGMII for gigabit, XGMII/XAUI/XFI/SFI for 10G, and the AUI family (CAUI-4, 400GAUI-8, 800GAUI-8) for everything since. This section explains them from the transceiver's point of view — what arrives at the cage, what a copper SFP has to emulate, and why a port "in the wrong mode" refuses a perfectly good module.

Layer stack MAC → xMII → PCS → PMA/AUI → PMD for a copper PHY port, a pluggable optical module and a copper SFP

Why the split exists

LayerLives inInterface to the next layer
MAC (framing, addresses)switch ASIC, NIC controller, SoCreconciliation sublayer → xMII
PCS (coding: 8b/10b, 64b/66b, FEC)ASIC/controller for pluggables; PHY chip for copperPMA
PMA / SerDesASIC SerDes or PHYAUI lanes to the module or medium
PMD (laser, copper driver)transceiver module or PHY chipfibre / cable

For pluggable optics the PCS and SerDes stay in the host; the module receives serial lanes (SFI, CAUI-4, 400GAUI-8) and converts to light. For copper, a PHY chip does PCS+PMA+PMD and talks to the MAC over a parallel (RGMII) or serial (SGMII) interface. A copper SFP puts that PHY inside the module, so the cage must carry SGMII or 1000BASE-X to it (SGMII & serial gigabit).

The ladder

InterfaceRateFormSignalsReachDefined byTypical place
MII10/1004-bit parallel @ 2.5/25 MHz16–18cmIEEE 802.3 Cl. 22legacy MAC ↔ PHY
RMII10/1002-bit @ 50 MHz7–9cmRMII Consortiumembedded SoC ↔ PHY
SMII / SS-SMII10/1001-bit @ 125 MHz2–3 per portcmCiscomulti-port PHYs
GMII1G (+10/100)8-bit @ 125 MHz24+cmCl. 35MAC ↔ PHY, mostly on-chip today
RGMII1G (+10/100)4-bit DDR @ 125 MHz12≤ 10–15 cmHP/Marvell RGMII v1.3/2.0SoC ↔ copper PHY on small switches/routers
TBI / RTBI1G10-bit @ 125 MHz20+cmCl. 36MAC ↔ external SerDes (legacy)
1000BASE-X (SerDes)1G1 lane 1.25 GBd, 8b/10b2 diff pairs50 cm+Cl. 36/37what an SFP cage carries at 1G
SGMII10/100/10001 lane 1.25 GBd, 8b/10b2 pairs (+ clocks)50 cm+Cisco SGMII v1.8MAC ↔ copper PHY; MAC ↔ copper SFP
2500BASE-X2.5G1.25 × SGMII/1000BASE-X rate: 3.125 GBd2 pairs50 cmde facto2.5G SFP, PON sticks
QSGMII4 × 1G1 lane 5 GBd2 pairs50 cmCiscoASIC ↔ quad copper PHY
USXGMII10M–10G1 lane 10.3125 GBd, 64b/66b2 pairs30 cmCisco/MarvellASIC ↔ mGig PHY; 10GBASE-T SFP+
XGMII10G32-bit DDR @ 156.25 MHz74< 7 cmCl. 46on-chip
XAUI10G4 × 3.125 GBd, 8b/10b8 pairs50 cmCl. 47XENPAK/X2 modules, legacy PHYs
XFI / SFI10G1 × 10.3125 GBd, 64b/66b2 pairs20–30 cmXFP MSA / SFF-8431XFP / SFP+ cage
10GBASE-KR10G1 × 10.3125 GBd2 pairs1 m backplaneCl. 72backplanes, 10GBASE-T PHYs
25GAUI25G1 × 25.78 GBd NRZ2 pairsC2MAnnex 109A/BSFP28 cage
XLAUI / CAUI-1040G / 100G4 / 10 × 10.3125 GBd8 / 20 pairsC2C/C2MAnnex 83A/BQSFP+ / CFP, CXP
CAUI-4100G4 × 25.78 GBd NRZ8 pairsC2MAnnex 83D/EQSFP28 cage
50GAUI-2 / -150G2 × 26.5625 NRZ / 1 × 26.5625 GBd PAM44 / 2 pairsC2MAnnex 135B–ESFP56
100GAUI-4 / -2 / -1100G4 × NRZ / 2 × 53 GBd PAM4 / 1 × 106 GBd PAM4C2MAnnex 135D–G, 120GQSFP28 (PAM4 variants), QSFP112
200GAUI-8 / -4 / -2200G8 × 26.5 PAM4 / 4 × 53 / 2 × 106C2MAnnex 120C–GQSFP56, QSFP112
400GAUI-16 / -8 / -4400G16 × 25 NRZ / 8 × 53 PAM4 / 4 × 106 PAM4C2MAnnex 120B–GCFP8 / QSFP-DD, OSFP / QSFP112, OSFP
800GAUI-8 / -4800G8 × 106 PAM4 / 4 × 212 PAM4C2M802.3df / djOSFP, QSFP-DD800 / OSFP224, OSFP-XD

Details: MII, RMII, GMII, RGMII, SGMII, 1000BASE-X, QSGMII, USXGMII, XGMII, XAUI, SFI and the AUI family.

Where each one sits

DeviceMAC → …… → medium
48-port 1G copper switchASIC → QSGMII → quad PHYsPHYs → RJ45
Small router / SoC boardSoC → RGMII or SGMII → PHYPHY → RJ45; or SoC → 1000BASE-X/SGMII → SFP cage
10G/25G switch or NIC SFP+/SFP28 portASIC SerDes → SFI / 25GAUI → cagemodule → fibre or DAC
100G QSFP28 portASIC → CAUI-4 (4 × 25G) → cagemodule → 4 λ or 4 fibres
400G QSFP-DD / OSFP portASIC → 400GAUI-8 (8 × 50G PAM4) → cagemodule gearbox → 4 × 100G optical
800G OSFP portASIC → 800GAUI-8 (8 × 100G PAM4) → cagemodule → 8 × 100G (DR8) or 4 × 200G
Copper 1000BASE-T SFPhost 1000BASE-X or SGMII → module's PHYPHY → RJ45
10GBASE-T SFP+host SFI (10GBASE-R) → module's PHY (USXGMII-class)PHY → RJ45
Multigig RJ45 switch portASIC → USXGMII → mGig PHY2.5/5/10GBASE-T

Management of PHYs vs modules

Copper PHY chipPluggable module
BusMDIO/MDC (Clause 22: 5-bit address, 32 × 16-bit registers; Clause 45: device/register pairs for 10G+)I²C two-wire (A0h/A2h, CMIS pages) (Two-wire interface)
Link statusPHY status register (reg 1), in-band on RGMII/SGMIILOS/LOL pins and flags, DDM
Linux toolsmii-tool, phytool, ethtool (PHY driver)ethtool -m, i2c-dev (NIC tools)
Copper SFP odditythe PHY inside the module is reachable over I²C at a second address (e.g. 0xAC on Marvell 88E1111-based modules) or via vendor pages — MDIO tunnelled

Why it matters for transceiver work

  • Mode of the cage. A 1G SFP port can be in 1000BASE-X or SGMII mode; a copper SFP behaves differently in each, and 10/100 clients only work in SGMII (or with a module that hides the difference) (SGMII & serial gigabit).
  • Rate and coding. The module must accept the host's lane rate and coding: SFI at 10.3125 GBd, CAUI-4 at 25.78, 400GAUI-8 PAM4 — this is what compliance codes and CMIS applications advertise (Compliance codes).
  • Who retimes. SFP+ modules are often linear/limiting with host equalisation; 25G+ modules carry CDRs; PAM4 modules carry DSPs; LPO modules are linear again and depend on the host SerDes (CDR, DSP & LPO).
  • Electrical ≠ optical lanes. 400G-FR4 takes 8 electrical lanes and emits 4 wavelengths; the gearbox is in the module (XGMII, XAUI and the AUI family).
  • Linux picks the interface from the EEPROM. The kernel's SFP layer reads bytes 3–10, 12 and 36 to decide between 1000BASE-X, SGMII, 2500BASE-X, 10GBASE-R — a wrong compliance byte makes a good module link in the wrong mode (Memory map).

Further reading

  • MII, RMII, GMII, RGMII — the parallel interfaces: pins, clocks, RGMII delay modes, in-band status, PHY management over MDIO, typical faults.
  • SGMII, 1000BASE-X, QSGMII, USXGMII — serial interfaces to PHYs and SFP cages: auto-negotiation differences, copper SFPs, 100BASE-FX, 2.5G, multigig, how Linux chooses the mode.
  • XGMII, XAUI, XFI/SFI and the AUI family — from 10G to 800G: lane counts, C2C vs C2M, compliance points, OIF CEI mapping, electrical-to-optical lane mapping, retimed vs linear modules.

In CodingBox

The bytes CodingBox shows are the module's statement of which host interfaces it supports: compliance codes (1000BASE-T → SGMII/1000BASE-X capable copper), nominal bit rate, encoding byte (8b/10b vs 64b/66b vs PAM4), CDR bits and CMIS host-interface IDs. Editing them changes which interface the host will try (Check transceiver, Compliance codes).


Jika anda menemui ketidaktepatan atau kesilapan dalam artikel ini, pilih bahagian teks yang berkenaan dan tekan Ctrl+Enter untuk .