요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
Explicit bind, unbind, and driver override
sysfs-bus-vdpa:23-57기본 binding을 바꾸는 bind·unbind와 특정 driver 하나만 허용하거나 binding을 거부하는 driver_override를 다룹니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
1
What: /sys/bus/vdpa/drivers_autoprobe
2
Date: March 2020
3
Contact: [email protected]
4
Description:
5
This file determines whether new devices are immediately bound
6
to a driver after the creation. It initially contains 1, which
7
means the kernel automatically binds devices to a compatible
8
driver immediately after they are created.
10
Writing "0" to this file disable this feature, any other string
11
enable it.
13
What: /sys/bus/vdpa/driver_probe
14
Date: March 2020
15
Contact: [email protected]
16
Description:
17
Writing a device name to this file will cause the kernel binds
18
devices to a compatible driver.
20
This can be useful when /sys/bus/vdpa/drivers_autoprobe is
21
disabled.
23
What: /sys/bus/vdpa/drivers/.../bind
24
Date: March 2020
25
Contact: [email protected]
26
Description:
27
Writing a device name to this file will cause the driver to
28
attempt to bind to the device. This is useful for overriding
29
default bindings.
31
What: /sys/bus/vdpa/drivers/.../unbind
32
Date: March 2020
33
Contact: [email protected]
34
Description:
35
Writing a device name to this file will cause the driver to
36
attempt to unbind from the device. This may be useful when
37
overriding default bindings.
39
What: /sys/bus/vdpa/devices/.../driver_override
40
Date: November 2021
41
Contact: [email protected]
42
Description:
43
This file allows the driver for a device to be specified.
44
When specified, only a driver with a name matching the value
45
written to driver_override will have an opportunity to bind to
46
the device. The override is specified by writing a string to the
47
driver_override file (echo vhost-vdpa > driver_override) and may
48
be cleared with an empty string (echo > driver_override).
49
This returns the device to standard matching rules binding.
50
Writing to driver_override does not automatically unbind the
51
device from its current driver or make any attempt to
52
automatically load the specified driver. If no driver with a
53
matching name is currently loaded in the kernel, the device will
54
not bind to any driver. This also allows devices to opt-out of
55
driver binding using a driver_override name such as "none".
56
Only a single driver may be specified in the override, there is
57
no support for parsing delimiters.
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
vDPA driver automatic probing
1-11| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/vdpa/drivers_autoprobe |
| Date | 2020년 3월 |
| Contact | [email protected] |
| Description | 새 장치를 만든 직후 driver에 bind할지 결정합니다. 초기값은 1이며 kernel이 장치를 생성 직후 compatible driver에 자동으로 bind한다는 뜻입니다. "0"을 쓰면 이 기능을 비활성화하고 그 밖의 문자열을 쓰면 활성화합니다. |
vDPA device 수동 probe
13-21| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/vdpa/driver_probe |
| Date | 2020년 3월 |
| Contact | [email protected] |
| Description | 이 file에 device name을 쓰면 kernel이 장치를 compatible driver에 bind합니다. /sys/bus/vdpa/drivers_autoprobe가 비활성화되어 있을 때 유용합니다. |
vDPA driver 강제 bind
23-29| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/vdpa/drivers/.../bind |
| Date | 2020년 3월 |
| Contact | [email protected] |
| Description | 이 file에 device name을 쓰면 driver가 장치에 bind하려고 시도합니다. 기본 binding을 override할 때 유용합니다. |
vDPA driver 강제 unbind
31-37| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/vdpa/drivers/.../unbind |
| Date | 2020년 3월 |
| Contact | [email protected] |
| Description | 이 file에 device name을 쓰면 driver가 장치에서 unbind하려고 시도합니다. 기본 binding을 override할 때 유용할 수 있습니다. |
vDPA device driver override
39-57| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/bus/vdpa/devices/.../driver_override |
| Date | 2021년 11월 |
| Contact | [email protected] |
| Description | 장치에 사용할 driver를 지정합니다. 값을 지정하면 driver_override에 쓴 값과 이름이 일치하는 driver만 장치에 bind할 기회를 얻습니다. 문자열을 써서 override를 지정하고(echo vhost-vdpa > driver_override), 빈 문자열로 clear합니다(echo > driver_override). Clear하면 장치는 표준 matching rule에 따른 binding으로 돌아갑니다. driver_override에 쓰는 동작은 장치를 현재 driver에서 자동으로 unbind하지 않으며 지정한 driver를 자동 load하려고도 하지 않습니다. 일치하는 이름의 driver가 현재 kernel에 load되어 있지 않으면 장치는 어떤 driver에도 bind되지 않습니다. "none" 같은 driver_override 이름을 사용해 장치를 driver binding에서 제외할 수도 있습니다. Override에는 driver 하나만 지정할 수 있으며 delimiter parsing은 지원하지 않습니다. |
echo vhost-vdpa > driver_override
echo > driver_override
Automatic and manual driver probing
sysfs-bus-vdpa:1-21새 vDPA 장치의 자동 binding 정책과 autoprobe 비활성화 시 사용할 수동 driver_probe를 정의합니다.