요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
1
.. SPDX-License-Identifier: GPL-2.0
3
========================
4
prestera devlink support
5
========================
7
This document describes the devlink features implemented by the ``prestera``
8
device driver.
10
Driver-specific Traps
11
=====================
13
.. list-table:: List of Driver-specific Traps Registered by ``prestera``
14
:widths: 5 5 90
16
* - Name
17
- Type
18
- Description
19
.. list-table:: List of Driver-specific Traps Registered by ``prestera``
20
:widths: 5 5 90
22
* - Name
23
- Type
24
- Description
25
* - ``arp_bc``
26
- ``trap``
27
- Traps ARP broadcast packets (both requests/responses)
28
* - ``is_is``
29
- ``trap``
30
- Traps IS-IS packets
31
* - ``ospf``
32
- ``trap``
33
- Traps OSPF packets
34
* - ``ip_bc_mac``
35
- ``trap``
36
- Traps IPv4 packets with broadcast DA Mac address
37
* - ``stp``
38
- ``trap``
39
- Traps STP BPDU
40
* - ``lacp``
41
- ``trap``
42
- Traps LACP packets
43
* - ``lldp``
44
- ``trap``
45
- Traps LLDP packets
46
* - ``router_mc``
47
- ``trap``
48
- Traps multicast packets
49
* - ``vrrp``
50
- ``trap``
51
- Traps VRRP packets
52
* - ``dhcp``
53
- ``trap``
54
- Traps DHCP packets
55
* - ``mtu_error``
56
- ``trap``
57
- Traps (exception) packets that exceeded port's MTU
58
* - ``mac_to_me``
59
- ``trap``
60
- Traps packets with switch-port's DA Mac address
61
* - ``ttl_error``
62
- ``trap``
63
- Traps (exception) IPv4 packets whose TTL exceeded
64
* - ``ipv4_options``
65
- ``trap``
66
- Traps (exception) packets due to the malformed IPV4 header options
67
* - ``ip_default_route``
68
- ``trap``
69
- Traps packets that have no specific IP interface (IP to me) and no forwarding prefix
70
* - ``local_route``
71
- ``trap``
72
- Traps packets that have been send to one of switch IP interfaces addresses
73
* - ``ipv4_icmp_redirect``
74
- ``trap``
75
- Traps (exception) IPV4 ICMP redirect packets
76
* - ``arp_response``
77
- ``trap``
78
- Traps ARP replies packets that have switch-port's DA Mac address
79
* - ``acl_code_0``
80
- ``trap``
81
- Traps packets that have ACL priority set to 0 (tc pref 0)
82
* - ``acl_code_1``
83
- ``trap``
84
- Traps packets that have ACL priority set to 1 (tc pref 1)
85
* - ``acl_code_2``
86
- ``trap``
87
- Traps packets that have ACL priority set to 2 (tc pref 2)
88
* - ``acl_code_3``
89
- ``trap``
90
- Traps packets that have ACL priority set to 3 (tc pref 3)
91
* - ``acl_code_4``
92
- ``trap``
93
- Traps packets that have ACL priority set to 4 (tc pref 4)
94
* - ``acl_code_5``
95
- ``trap``
96
- Traps packets that have ACL priority set to 5 (tc pref 5)
97
* - ``acl_code_6``
98
- ``trap``
99
- Traps packets that have ACL priority set to 6 (tc pref 6)
100
* - ``acl_code_7``
101
- ``trap``
102
- Traps packets that have ACL priority set to 7 (tc pref 7)
103
* - ``ipv4_bgp``
104
- ``trap``
105
- Traps IPv4 BGP packets
106
* - ``ssh``
107
- ``trap``
108
- Traps SSH packets
109
* - ``telnet``
110
- ``trap``
111
- Traps Telnet packets
112
* - ``icmp``
113
- ``trap``
114
- Traps ICMP packets
115
* - ``rxdma_drop``
116
- ``drop``
117
- Drops packets (RxDMA) due to the lack of ingress buffers etc.
118
* - ``port_no_vlan``
119
- ``drop``
120
- Drops packets due to faulty-configured network or due to internal bug (config issue).
121
* - ``local_port``
122
- ``drop``
123
- Drops packets whose decision (FDB entry) is to bridge packet back to the incoming port/trunk.
124
* - ``invalid_sa``
125
- ``drop``
126
- Drops packets with multicast source MAC address.
127
* - ``illegal_ip_addr``
128
- ``drop``
129
- Drops packets with illegal SIP/DIP multicast/unicast addresses.
130
* - ``illegal_ipv4_hdr``
131
- ``drop``
132
- Drops packets with illegal IPV4 header.
133
* - ``ip_uc_dip_da_mismatch``
134
- ``drop``
135
- Drops packets with destination MAC being unicast, but destination IP address being multicast.
136
* - ``ip_sip_is_zero``
137
- ``drop``
138
- Drops packets with zero (0) IPV4 source address.
139
* - ``met_red``
140
- ``drop``
141
- Drops non-conforming packets (dropped by Ingress policer, metering drop), e.g. packet rate exceeded configured bandwidth.
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
prestera devlink 지원
1-9이 문서는 `GPL-2.0` 라이선스를 따릅니다.
`prestera` 장치 드라이버가 구현한 devlink 기능을 설명합니다.
.. SPDX-License-Identifier: GPL-2.0
========================
prestera devlink support
========================
This document describes the devlink features implemented by the ``prestera``
device driver.
제어·라우팅 프로토콜 트랩
10-78드라이버 전용 트랩
원문의 중복된 목록 표 선언을 보존하면서, 등록된 `prestera` 트랩을 기능별로 정리합니다.
이름유형설명
`arp_bc``trap`요청과 응답을 모두 포함한 ARP 브로드캐스트 패킷을 트랩합니다.
`is_is``trap`IS-IS 패킷을 트랩합니다.
`ospf``trap`OSPF 패킷을 트랩합니다.
`ip_bc_mac``trap`목적지 MAC 주소가 브로드캐스트인 IPv4 패킷을 트랩합니다.
`stp``trap`STP BPDU를 트랩합니다.
`lacp``trap`LACP 패킷을 트랩합니다.
`lldp``trap`LLDP 패킷을 트랩합니다.
`router_mc``trap`멀티캐스트 패킷을 트랩합니다.
`vrrp``trap`VRRP 패킷을 트랩합니다.
`dhcp``trap`DHCP 패킷을 트랩합니다.
`mtu_error``trap`포트 MTU를 초과한 예외 패킷을 트랩합니다.
`mac_to_me``trap`목적지 MAC 주소가 스위치 포트 주소인 패킷을 트랩합니다.
`ttl_error``trap`TTL이 초과된 IPv4 예외 패킷을 트랩합니다.
`ipv4_options``trap`잘못 구성된 IPv4 헤더 옵션 때문에 발생한 예외 패킷을 트랩합니다.
`ip_default_route``trap`일치하는 특정 IP 인터페이스(IP to me)도 전달 접두사도 없는 패킷을 트랩합니다.
`local_route``trap`스위치의 IP 인터페이스 주소 중 하나로 전송된 패킷을 트랩합니다.
`ipv4_icmp_redirect``trap`IPv4 ICMP redirect 예외 패킷을 트랩합니다.
`arp_response``trap`목적지 MAC 주소가 스위치 포트 주소인 ARP 응답 패킷을 트랩합니다.
스위치 CPU가 직접 처리해야 하는 L2·L3 제어 패킷과 라우팅 예외를 포착합니다.
Driver-specific Traps
=====================
.. list-table:: List of Driver-specific Traps Registered by ``prestera``
:widths: 5 5 90
* - Name
- Type
- Description
.. list-table:: List of Driver-specific Traps Registered by ``prestera``
:widths: 5 5 90
* - Name
- Type
- Description
* - ``arp_bc``
- ``trap``
- Traps ARP broadcast packets (both requests/responses)
* - ``is_is``
- ``trap``
- Traps IS-IS packets
* - ``ospf``
- ``trap``
- Traps OSPF packets
* - ``ip_bc_mac``
- ``trap``
- Traps IPv4 packets with broadcast DA Mac address
* - ``stp``
- ``trap``
- Traps STP BPDU
* - ``lacp``
- ``trap``
- Traps LACP packets
* - ``lldp``
- ``trap``
- Traps LLDP packets
* - ``router_mc``
- ``trap``
- Traps multicast packets
* - ``vrrp``
- ``trap``
- Traps VRRP packets
* - ``dhcp``
- ``trap``
- Traps DHCP packets
* - ``mtu_error``
- ``trap``
- Traps (exception) packets that exceeded port's MTU
* - ``mac_to_me``
- ``trap``
- Traps packets with switch-port's DA Mac address
* - ``ttl_error``
- ``trap``
- Traps (exception) IPv4 packets whose TTL exceeded
* - ``ipv4_options``
- ``trap``
- Traps (exception) packets due to the malformed IPV4 header options
* - ``ip_default_route``
- ``trap``
- Traps packets that have no specific IP interface (IP to me) and no forwarding prefix
* - ``local_route``
- ``trap``
- Traps packets that have been send to one of switch IP interfaces addresses
* - ``ipv4_icmp_redirect``
- ``trap``
- Traps (exception) IPV4 ICMP redirect packets
* - ``arp_response``
- ``trap``
- Traps ARP replies packets that have switch-port's DA Mac address
ACL 우선순위와 관리 프로토콜 트랩
79-114이름유형설명
`acl_code_0``trap`ACL 우선순위가 0(`tc pref 0`)인 패킷을 트랩합니다.
`acl_code_1``trap`ACL 우선순위가 1(`tc pref 1`)인 패킷을 트랩합니다.
`acl_code_2``trap`ACL 우선순위가 2(`tc pref 2`)인 패킷을 트랩합니다.
`acl_code_3``trap`ACL 우선순위가 3(`tc pref 3`)인 패킷을 트랩합니다.
`acl_code_4``trap`ACL 우선순위가 4(`tc pref 4`)인 패킷을 트랩합니다.
`acl_code_5``trap`ACL 우선순위가 5(`tc pref 5`)인 패킷을 트랩합니다.
`acl_code_6``trap`ACL 우선순위가 6(`tc pref 6`)인 패킷을 트랩합니다.
`acl_code_7``trap`ACL 우선순위가 7(`tc pref 7`)인 패킷을 트랩합니다.
`ipv4_bgp``trap`IPv4 BGP 패킷을 트랩합니다.
`ssh``trap`SSH 패킷을 트랩합니다.
`telnet``trap`Telnet 패킷을 트랩합니다.
`icmp``trap`ICMP 패킷을 트랩합니다.
TC ACL 우선순위 코드와 BGP·원격 관리·ICMP 트래픽을 CPU로 보냅니다.
* - ``acl_code_0``
- ``trap``
- Traps packets that have ACL priority set to 0 (tc pref 0)
* - ``acl_code_1``
- ``trap``
- Traps packets that have ACL priority set to 1 (tc pref 1)
* - ``acl_code_2``
- ``trap``
- Traps packets that have ACL priority set to 2 (tc pref 2)
* - ``acl_code_3``
- ``trap``
- Traps packets that have ACL priority set to 3 (tc pref 3)
* - ``acl_code_4``
- ``trap``
- Traps packets that have ACL priority set to 4 (tc pref 4)
* - ``acl_code_5``
- ``trap``
- Traps packets that have ACL priority set to 5 (tc pref 5)
* - ``acl_code_6``
- ``trap``
- Traps packets that have ACL priority set to 6 (tc pref 6)
* - ``acl_code_7``
- ``trap``
- Traps packets that have ACL priority set to 7 (tc pref 7)
* - ``ipv4_bgp``
- ``trap``
- Traps IPv4 BGP packets
* - ``ssh``
- ``trap``
- Traps SSH packets
* - ``telnet``
- ``trap``
- Traps Telnet packets
* - ``icmp``
- ``trap``
- Traps ICMP packets
수신·주소·폴리서 폐기 트랩
115-141이름유형설명
`rxdma_drop``drop`수신 버퍼 부족 등의 이유로 RxDMA에서 패킷을 폐기합니다.
`port_no_vlan``drop`잘못 구성된 네트워크 또는 내부 구성 문제 때문에 패킷을 폐기합니다.
`local_port``drop`FDB 결정이 패킷을 수신 포트나 트렁크로 다시 브리지하도록 지시한 경우 패킷을 폐기합니다.
`invalid_sa``drop`출발지 MAC 주소가 멀티캐스트인 패킷을 폐기합니다.
`illegal_ip_addr``drop`잘못된 멀티캐스트·유니캐스트 SIP 또는 DIP 주소를 가진 패킷을 폐기합니다.
`illegal_ipv4_hdr``drop`잘못된 IPv4 헤더를 가진 패킷을 폐기합니다.
`ip_uc_dip_da_mismatch``drop`목적지 MAC은 유니캐스트지만 목적지 IP 주소는 멀티캐스트인 패킷을 폐기합니다.
`ip_sip_is_zero``drop`IPv4 출발지 주소가 0인 패킷을 폐기합니다.
`met_red``drop`수신 폴리서가 부적합하다고 판정한 패킷을 폐기합니다. 예를 들어 패킷 속도가 설정 대역폭을 초과한 metering drop입니다.
버퍼 부족, 잘못된 구성·주소·헤더, 폴리서 위반 때문에 폐기한 패킷을 분류합니다.
* - ``rxdma_drop``
- ``drop``
- Drops packets (RxDMA) due to the lack of ingress buffers etc.
* - ``port_no_vlan``
- ``drop``
- Drops packets due to faulty-configured network or due to internal bug (config issue).
* - ``local_port``
- ``drop``
- Drops packets whose decision (FDB entry) is to bridge packet back to the incoming port/trunk.
* - ``invalid_sa``
- ``drop``
- Drops packets with multicast source MAC address.
* - ``illegal_ip_addr``
- ``drop``
- Drops packets with illegal SIP/DIP multicast/unicast addresses.
* - ``illegal_ipv4_hdr``
- ``drop``
- Drops packets with illegal IPV4 header.
* - ``ip_uc_dip_da_mismatch``
- ``drop``
- Drops packets with destination MAC being unicast, but destination IP address being multicast.
* - ``ip_sip_is_zero``
- ``drop``
- Drops packets with zero (0) IPV4 source address.
* - ``met_red``
- ``drop``
- Drops non-conforming packets (dropped by Ingress policer, metering drop), e.g. packet rate exceeded configured bandwidth.
요약·해설
prestera.rst:1-141`prestera`는 ARP·라우팅·STP·LACP·LLDP 같은 제어 패킷, ACL 우선순위와 관리 프로토콜, 버퍼·주소·헤더·폴리서 오류에 따른 폐기를 별도 devlink 트랩으로 분류합니다. 이를 통해 CPU 전달 트래픽과 하드웨어 폐기 원인을 같은 진단 인터페이스에서 추적할 수 있습니다.