← Documents Documentation/ABI/testing/configfs-stp-policy GitHub 원문 ↗

Linux 6.18.37 · ABI / testing

STM master and channel allocation policy configfs ABI

STM으로 trace data를 보내는 software source에 master와 channel을 할당하는 configfs policy root, node identifier 및 allocation range를 설명합니다.

Source pathDocumentation/ABI/testing/configfs-stp-policy
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

STM policy group과 device binding

configfs-stp-policy:1-24

Policy root 이름은 STM device와 임의 policy 문자열을 결합하며 device 부재와 중복 할당을 mkdir error로 보고합니다.

Client node와 master/channel range

configfs-stp-policy:26-47

Software client가 allocation 요청에 사용할 node identifier를 만들고, 그 node가 사용할 master와 channel의 시작·끝 번호를 지정합니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 What: /config/stp-policy
2 Date: June 2015
3 KernelVersion: 4.3
4 Description:
5 This group contains policies mandating Master/Channel allocation
6 for software sources wishing to send trace data over an STM
7 device.
8
9 What: /config/stp-policy/<device>.<policy>
10 Date: June 2015
11 KernelVersion: 4.3
12 Description:
13 This group is the root of a policy; its name is a concatenation
14 of an stm device name to which this policy applies and an
15 arbitrary string. If <device> part doesn't match an existing
16 stm device, mkdir will fail with ENODEV; if that device already
17 has a policy assigned to it, mkdir will fail with EBUSY.
18
19 What: /config/stp-policy/<device>.<policy>/device
20 Date: June 2015
21 KernelVersion: 4.3
22 Description:
23 STM device to which this policy applies, read only. Same as the
24 <device> component of its parent directory.
25
26 What: /config/stp-policy/<device>.<policy>/<node>
27 Date: June 2015
28 KernelVersion: 4.3
29 Description:
30 Policy node is a string identifier that software clients will
31 use to request a master/channel to be allocated and assigned to
32 them.
33
34 What: /config/stp-policy/<device>.<policy>/<node>/masters
35 Date: June 2015
36 KernelVersion: 4.3
37 Description:
38 Range of masters from which to allocate for users of this node.
39 Write two numbers: the first master and the last master number.
40
41 What: /config/stp-policy/<device>.<policy>/<node>/channels
42 Date: June 2015
43 KernelVersion: 4.3
44 Description:
45 Range of channels from which to allocate for users of this node.
46 Write two numbers: the first channel and the last channel
47 number.
48
49

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

STM trace source의 master/channel 할당 policy

1-7
항목내용
What/config/stp-policy
Date2015년 6월
KernelVersion4.3
DescriptionSTM device를 통해 trace data를 보내려는 software source에 Master/Channel을 할당하도록 강제하는 policy를 담는 group이다.

Device에 연결되는 policy root

9-17
항목내용
What/config/stp-policy/<device>.<policy>
Date2015년 6월
KernelVersion4.3
DescriptionPolicy의 root group이다. 이름은 이 policy가 적용되는 STM device 이름과 임의 문자열을 결합한 것이다.
mkdir 조건결과
<device>가 기존 STM device와 일치하지 않음ENODEV로 실패
해당 device에 이미 policy가 할당됨EBUSY로 실패

Policy가 적용되는 STM device

19-24
항목내용
What/config/stp-policy/<device>.<policy>/device
Date2015년 6월
KernelVersion4.3
Description이 policy가 적용되는 STM device를 나타내는 read-only attribute이다. Parent directory 이름의 <device> 부분과 같다.

Software client가 요청에 사용하는 policy node

26-32
항목내용
What/config/stp-policy/<device>.<policy>/<node>
Date2015년 6월
KernelVersion4.3
DescriptionPolicy node는 software client가 master/channel을 할당받아 자신에게 지정해 달라고 요청할 때 사용하는 문자열 identifier이다.

Node 사용자의 master와 channel allocation range

34-47
경로 suffix내용쓰기 형식
masters이 node의 사용자에게 할당할 master의 범위이다.첫 master 번호와 마지막 master 번호, 두 숫자
channels이 node의 사용자에게 할당할 channel의 범위이다.첫 channel 번호와 마지막 channel 번호, 두 숫자

두 attribute의 공통 경로 prefix는 `/config/stp-policy/<device>.<policy>/<node>/`이며, 도입 시점은 2015년 6월, kernel version은 4.3이다.

STM policy node를 통한 master/channel 할당
/config/stp-policy<device>.<policy> 생성기존 STM device 확인Policy root
Policy root<node> 생성masters = 첫 번호, 마지막 번호허용 master 범위
Policy root<node> 생성channels = 첫 번호, 마지막 번호허용 channel 범위
Software client<node> identifier로 요청범위 안에서 master/channel 할당STM trace 전송

Policy는 한 STM device에 연결되고, client가 선택하는 node마다 사용할 수 있는 master와 channel 범위를 제한한다.