요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
Identifiers and configuration registers
sysfs-bus-rapidio:32-120공통 속성은 device·vendor·assembly 식별자와 revision, enumeration destID, 이전 switch, modalias 및 maintenance transaction 기반 config 접근을 제공합니다.
Routes, ports, and IDT_GEN2 error log
sysfs-bus-rapidio:121-182Switch 속성은 유효 route, hop count, port별 이웃, 장치별 callback으로 만든 속성과 IDT_GEN2 error log를 노출합니다.
Trigger enumeration from userspace
sysfs-bus-rapidio:183-201scan에는 destination ID가 아닌 mport_ID를 쓰며 -1 또는 RIO_MPORT_ANY는 모든 mport를 대상으로 합니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>
Description:
For each RapidIO device, the RapidIO subsystem creates files in
an individual subdirectory with the following name format of
device_name "nn:d:iiii", where:
==== ========================================================
nn two-digit hexadecimal ID of RapidIO network where the
device resides
d device type: 'e' - for endpoint or 's' - for switch
iiii four-digit device destID for endpoints, or switchID for
switches
==== ========================================================
For example, below is a list of device directories that
represents a typical RapidIO network with one switch, one host,
and two agent endpoints, as it is seen by the enumerating host
(with destID = 1)::
/sys/bus/rapidio/devices/00:e:0000
/sys/bus/rapidio/devices/00:e:0002
/sys/bus/rapidio/devices/00:s:0001
NOTE:
An enumerating or discovering endpoint does not create a
sysfs entry for itself, this is why an endpoint with destID=1
is not shown in the list.
Attributes Common for All RapidIO Devices
-----------------------------------------
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/did
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns the device identifier
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/vid
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns the device vendor identifier
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/device_rev
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns the device revision level
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_did
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns identifier for the assembly containing the device
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_rev
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns revision level of the assembly containing the
device
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_vid
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns vendor identifier of the assembly containing the
device
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/destid
Date: Mar, 2011
KernelVersion: v2.6.3
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns device destination ID assigned by the enumeration
routine
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/lprev
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns name of previous device (switch) on the path to the
device that that owns this attribute
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/modalias
Date: Jul, 2013
KernelVersion: v3.11
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns the device modalias
What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/config
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RW) Binary attribute to read from and write to the device
configuration registers using the RapidIO maintenance
transactions. This attribute is similar in behaviour to the
"config" attribute of PCI devices and provides an access to the
RapidIO device registers using standard file read and write
operations.
RapidIO Switch Device Attributes
--------------------------------
RapidIO switches have additional attributes in sysfs. RapidIO subsystem supports
common and device-specific sysfs attributes for switches. Because switches are
integrated into the RapidIO subsystem, it offers a method to create
device-specific sysfs attributes by specifying a callback function that may be
set by the switch initialization routine during enumeration or discovery
process.
What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/routes
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) reports switch routing information in "destID port" format.
This attribute reports only valid routing table entries, one
line for each entry.
What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/destid
Date: Mar, 2011
KernelVersion: v2.6.3
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) device destination ID of the associated device that defines
a route to the switch
What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/hopcount
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) number of hops on the path to the switch
What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/lnext
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) returns names of devices linked to the switch except one of
a device linked to the ingress port (reported as "lprev"). This
is an array names with number of lines equal to number of ports
in switch. If a switch port has no attached device, returns
"null" instead of a device name.
Device-specific Switch Attributes
---------------------------------
IDT_GEN2-
What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/errlog
Date: Oct, 2010
KernelVersion: v2.6.37
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(RO) reads contents of device error log until it is empty.
RapidIO Bus Attributes
----------------------
What: /sys/bus/rapidio/scan
Date: May, 2013
KernelVersion: v3.11
Contact: Matt Porter <[email protected]>,
Alexandre Bounine <[email protected]>
Description:
(WO) Allows to trigger enumeration discovery process from user
space. To initiate an enumeration or discovery process on
specific mport device, a user needs to write mport_ID (not
RapidIO destination ID) into this file. The mport_ID is a
sequential number (0 ... RIO_MAX_MPORTS) assigned to the mport
device. For example, for a machine with a single RapidIO
controller, mport_ID for that controller always will be 0. To
initiate RapidIO enumeration/discovery on all available mports a
user must write '-1' (or RIO_MPORT_ANY) into this attribute
file.
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
RapidIO 장치 디렉터리 이름
1-31| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii> |
| Description | RapidIO subsystem은 각 RapidIO 장치에 대해 device_name이 "nn:d:iiii" 형식인 개별 하위 디렉터리와 그 안의 file을 생성합니다. |
장치 디렉터리 이름의 network ID, 장치 유형, endpoint destination ID 또는 switch ID 필드를 나타냅니다.
다음은 destID가 1인 enumerating host에서 보이는, switch 하나·host 하나·agent endpoint 둘로 구성된 일반적인 RapidIO network의 장치 디렉터리 예입니다.
/sys/bus/rapidio/devices/00:e:0000
/sys/bus/rapidio/devices/00:e:0002
/sys/bus/rapidio/devices/00:s:0001
Enumeration 또는 discovery를 수행하는 endpoint는 자기 자신의 sysfs 항목을 만들지 않습니다. 따라서 destID=1인 endpoint는 위 목록에 나타나지 않습니다.
RapidIO device identifier
32-39| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/did |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Device identifier를 반환합니다. |
RapidIO device vendor identifier
40-47| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/vid |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Device vendor identifier를 반환합니다. |
RapidIO device revision
48-55| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/device_rev |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Device revision level을 반환합니다. |
RapidIO assembly identifier
56-63| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_did |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). 장치를 포함하는 assembly의 identifier를 반환합니다. |
RapidIO assembly revision
64-72| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_rev |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). 장치를 포함하는 assembly의 revision level을 반환합니다. |
RapidIO assembly vendor identifier
73-81| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_vid |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). 장치를 포함하는 assembly의 vendor identifier를 반환합니다. |
Enumeration이 할당한 destination ID
82-90| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/destid |
| Date | 2011년 3월 |
| KernelVersion | v2.6.3 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Enumeration routine이 장치에 할당한 destination ID를 반환합니다. |
장치 경로의 이전 switch
91-99| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/lprev |
| Date | 2011년 3월 |
| KernelVersion | v2.6.39 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). 이 속성을 소유한 장치로 가는 경로에서 바로 앞에 있는 장치, 즉 switch의 이름을 반환합니다. |
RapidIO device modalias
100-107| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/modalias |
| Date | 2013년 7월 |
| KernelVersion | v3.11 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Device modalias를 반환합니다. |
RapidIO configuration register 접근
108-120| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/config |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기·쓰기(RW) binary 속성입니다. RapidIO maintenance transaction을 사용해 device configuration register를 읽고 씁니다. 동작은 PCI 장치의 "config" 속성과 비슷하며, 표준 file read·write operation으로 RapidIO device register에 접근할 수 있게 합니다. |
RapidIO switch routing table
121-140RapidIO switch는 sysfs에 추가 속성을 가집니다. RapidIO subsystem은 switch의 공통 속성과 장치별 속성을 모두 지원합니다. Switch가 subsystem에 통합되어 있으므로 enumeration 또는 discovery 중 switch 초기화 routine이 설정할 수 있는 callback function을 지정해 장치별 sysfs 속성을 만들 수 있습니다.
| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/routes |
| Date | 2005년 11월 |
| KernelVersion | v2.6.15 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Switch routing 정보를 "destID port" 형식으로 보고합니다. 유효한 routing table 항목만 각 항목당 한 줄로 표시합니다. |
Switch route를 정의하는 destination ID
141-149| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/destid |
| Date | 2011년 3월 |
| KernelVersion | v2.6.3 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Switch로 향하는 route를 정의하는 연관 장치의 destination ID입니다. |
Switch까지의 hop 수
150-157| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/hopcount |
| Date | 2011년 3월 |
| KernelVersion | v2.6.39 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Switch로 가는 경로의 hop 수를 반환합니다. |
Switch port별 연결 장치
158-169| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/lnext |
| Date | 2011년 3월 |
| KernelVersion | v2.6.39 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Ingress port에 연결되어 lprev로 보고되는 장치 하나를 제외하고 switch에 연결된 장치 이름을 반환합니다. Switch port 수와 같은 줄 수를 가진 이름 배열이며, 연결된 장치가 없는 port는 장치 이름 대신 "null"을 반환합니다. |
IDT_GEN2 switch error log
170-182다음은 IDT_GEN2 switch의 장치별 속성입니다.
| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/errlog |
| Date | 2010년 10월 |
| KernelVersion | v2.6.37 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 읽기 전용(RO). Device error log가 빌 때까지 그 내용을 읽습니다. |
Userspace에서 RapidIO enumeration 시작
183-201| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/rapidio/scan |
| Date | 2013년 5월 |
| KernelVersion | v3.11 |
| Contact | Matt Porter <[email protected]>, Alexandre Bounine <[email protected]> |
| Description | 쓰기 전용(WO). Userspace에서 enumeration 또는 discovery 절차를 시작합니다. 특정 mport 장치에서 시작하려면 RapidIO destination ID가 아니라 mport_ID를 이 file에 써야 합니다. mport_ID는 mport 장치에 순차적으로 할당되는 0 ... RIO_MAX_MPORTS 번호입니다. RapidIO controller가 하나인 system에서 그 controller의 mport_ID는 항상 0입니다. 사용 가능한 모든 mport에서 RapidIO enumeration 또는 discovery를 시작하려면 -1 또는 RIO_MPORT_ANY를 씁니다. |
Network, device type, and destination ID
sysfs-bus-rapidio:1-31nn:d:iiii 이름은 network ID, endpoint 또는 switch 유형, destination ID 또는 switch ID를 결합하며 scanning endpoint 자신은 목록에 만들지 않습니다.