요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
Kernel driver occ-hwmon
=======================
Supported chips:
* POWER8
* POWER9
Author: Eddie James <[email protected]>
Description
-----------
This driver supports hardware monitoring for the On-Chip Controller (OCC)
embedded on POWER processors. The OCC is a device that collects and aggregates
sensor data from the processor and the system. The OCC can provide the raw
sensor data as well as perform thermal and power management on the system.
The P8 version of this driver is a client driver of I2C. It may be probed
manually if an "ibm,p8-occ-hwmon" compatible device is found under the
appropriate I2C bus node in the device-tree.
The P9 version of this driver is a client driver of the FSI-based OCC driver.
It will be probed automatically by the FSI-based OCC driver.
Sysfs entries
-------------
The following attributes are supported. All attributes are read-only unless
specified.
The OCC sensor ID is an integer that represents the unique identifier of the
sensor with respect to the OCC. For example, a temperature sensor for the third
DIMM slot in the system may have a sensor ID of 7. This mapping is unavailable
to the device driver, which must therefore export the sensor ID as-is.
Some entries are only present with certain OCC sensor versions or only on
certain OCCs in the system. The version number is not exported to the user
but can be inferred.
temp[1-n]_label
OCC sensor ID.
[with temperature sensor version 1]
temp[1-n]_input
Measured temperature of the component in millidegrees
Celsius.
[with temperature sensor version >= 2]
temp[1-n]_type
The FRU (Field Replaceable Unit) type
(represented by an integer) for the component
that this sensor measures.
temp[1-n]_fault
Temperature sensor fault boolean; 1 to indicate
that a fault is present or 0 to indicate that
no fault is present.
[with type == 3 (FRU type is VRM)]
temp[1-n]_alarm
VRM temperature alarm boolean; 1 to indicate
alarm, 0 to indicate no alarm
[else]
temp[1-n]_input
Measured temperature of the component in
millidegrees Celsius.
freq[1-n]_label
OCC sensor ID.
freq[1-n]_input
Measured frequency of the component in MHz.
power[1-n]_input
Latest measured power reading of the component in
microwatts.
power[1-n]_average
Average power of the component in microwatts.
power[1-n]_average_interval
The amount of time over which the power average
was taken in microseconds.
[with power sensor version < 2]
power[1-n]_label
OCC sensor ID.
[with power sensor version >= 2]
power[1-n]_label
OCC sensor ID + function ID + channel in the form
of a string, delimited by underscores, i.e. "0_15_1".
Both the function ID and channel are integers that
further identify the power sensor.
[with power sensor version 0xa0]
power[1-n]_label
OCC sensor ID + sensor type in the form of a string,
delimited by an underscore, i.e. "0_system". Sensor
type will be one of "system", "proc", "vdd" or "vdn".
For this sensor version, OCC sensor ID will be the same
for all power sensors.
[present only on "master" OCC; represents the whole system power; only one of
this type of power sensor will be present]
power[1-n]_label
"system"
power[1-n]_input
Latest system output power in microwatts.
power[1-n]_cap
Current system power cap in microwatts.
power[1-n]_cap_not_redundant
System power cap in microwatts when
there is not redundant power.
power[1-n]_cap_max
Maximum power cap that the OCC can enforce in
microwatts.
power[1-n]_cap_min Minimum power cap that the OCC can enforce in
microwatts.
power[1-n]_cap_user The power cap set by the user, in microwatts.
This attribute will return 0 if no user power
cap has been set. This attribute is read-write,
but writing any precision below watts will be
ignored, i.e. requesting a power cap of
500900000 microwatts will result in a power cap
request of 500 watts.
[with caps sensor version > 1]
power[1-n]_cap_user_source
Indicates how the user power cap was
set. This is an integer that maps to
system or firmware components that can
set the user power cap.
The following "extn" sensors are exported as a way for the OCC to provide data
that doesn't fit anywhere else. The meaning of these sensors is entirely
dependent on their data, and cannot be statically defined.
extn[1-n]_label
ASCII ID or OCC sensor ID.
extn[1-n]_flags
This is one byte hexadecimal value. Bit 7 indicates the
type of the label attribute; 1 for sensor ID, 0 for
ASCII ID. Other bits are reserved.
extn[1-n]_input
6 bytes of hexadecimal data, with a meaning defined by
the sensor ID.
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
POWER8/POWER9 On-Chip Controller
1-25`occ-hwmon` 드라이버는 POWER8과 POWER9 프로세서에 내장된 OCC(On-Chip Controller)의 하드웨어 모니터링을 지원합니다. 작성자는 Eddie James입니다.
OCC는 프로세서와 시스템의 센서 데이터를 수집하고 집계하는 장치입니다. 원시 센서 데이터를 제공하는 것뿐 아니라 시스템의 열 및 전력 관리도 수행할 수 있습니다.
POWER8 버전은 I2C 클라이언트 드라이버입니다. 적절한 I2C 버스의 장치 트리 아래에 `ibm,p8-occ-hwmon` 호환 장치가 있으면 수동으로 프로브할 수 있습니다.
POWER9 버전은 FSI 기반 OCC 드라이버의 클라이언트이며, FSI 기반 상위 드라이버가 자동으로 프로브합니다.
POWER 세대에 따라 프로브 경로가 다릅니다.
프로세서 세대에 맞는 전송 계층을 통해 센서를 공개합니다.
Kernel driver occ-hwmon
=======================
Supported chips:
* POWER8
* POWER9
Author: Eddie James <[email protected]>
Description
-----------
This driver supports hardware monitoring for the On-Chip Controller (OCC)
embedded on POWER processors. The OCC is a device that collects and aggregates
sensor data from the processor and the system. The OCC can provide the raw
sensor data as well as perform thermal and power management on the system.
The P8 version of this driver is a client driver of I2C. It may be probed
manually if an "ibm,p8-occ-hwmon" compatible device is found under the
appropriate I2C bus node in the device-tree.
The P9 version of this driver is a client driver of the FSI-based OCC driver.
It will be probed automatically by the FSI-based OCC driver.
OCC 센서 ID와 온도 센서 버전
26-72아래 속성은 별도 표시가 없으면 모두 읽기 전용입니다. OCC 센서 ID는 OCC 내부에서 센서를 고유하게 구분하는 정수입니다. 예를 들어 세 번째 DIMM 슬롯의 온도 센서가 ID 7일 수 있습니다.
센서 ID와 실제 시스템 부품의 대응 관계를 장치 드라이버는 알 수 없으므로 ID를 받은 그대로 사용자 공간에 공개해야 합니다. 일부 속성은 특정 OCC 또는 센서 버전에서만 나타나며, 버전 번호 자체는 공개되지 않지만 속성 구성을 통해 추론할 수 있습니다.
`temp[1-n]_label`은 OCC 센서 ID입니다. 온도 센서 버전 1에서는 `temp[1-n]_input`이 부품의 측정 온도를 밀리도 섭씨로 제공합니다.
온도 센서 버전 2 이상에서는 `temp[1-n]_type`이 정수형 FRU(Field Replaceable Unit) 종류를, `temp[1-n]_fault`가 센서 고장 여부를 제공합니다. 고장이 있으면 1, 없으면 0입니다.
FRU type이 3인 VRM 센서는 일반 온도 입력 대신 `temp[1-n]_alarm`을 제공하며, 경보가 있으면 1입니다. 그 밖의 FRU는 `temp[1-n]_input`으로 밀리도 섭씨 온도를 제공합니다.
센서 버전과 FRU 종류에 따라 나타나는 속성을 구분합니다.
노출된 속성 조합으로 센서 버전과 종류를 판단합니다.
Sysfs entries
-------------
The following attributes are supported. All attributes are read-only unless
specified.
The OCC sensor ID is an integer that represents the unique identifier of the
sensor with respect to the OCC. For example, a temperature sensor for the third
DIMM slot in the system may have a sensor ID of 7. This mapping is unavailable
to the device driver, which must therefore export the sensor ID as-is.
Some entries are only present with certain OCC sensor versions or only on
certain OCCs in the system. The version number is not exported to the user
but can be inferred.
temp[1-n]_label
OCC sensor ID.
[with temperature sensor version 1]
temp[1-n]_input
Measured temperature of the component in millidegrees
Celsius.
[with temperature sensor version >= 2]
temp[1-n]_type
The FRU (Field Replaceable Unit) type
(represented by an integer) for the component
that this sensor measures.
temp[1-n]_fault
Temperature sensor fault boolean; 1 to indicate
that a fault is present or 0 to indicate that
no fault is present.
[with type == 3 (FRU type is VRM)]
temp[1-n]_alarm
VRM temperature alarm boolean; 1 to indicate
alarm, 0 to indicate no alarm
[else]
temp[1-n]_input
Measured temperature of the component in
millidegrees Celsius.
주파수·전력과 전력 센서 버전
73-107`freq[1-n]_label`은 OCC 센서 ID이고 `freq[1-n]_input`은 측정 주파수를 MHz로 제공합니다. 전력 센서의 `power[1-n]_input`은 최신 측정값, `power[1-n]_average`는 평균값을 마이크로와트로 제공합니다.
`power[1-n]_average_interval`은 평균을 계산한 시간 구간을 마이크로초로 표시합니다.
전력 센서 버전 2 미만의 `power[1-n]_label`은 OCC 센서 ID입니다. 버전 2 이상에서는 센서 ID, function ID, channel을 밑줄로 연결한 문자열이며 예시는 `0_15_1`입니다. function ID와 channel은 전력 센서를 더 세밀하게 식별하는 정수입니다.
전력 센서 버전 `0xa0`에서는 라벨이 OCC 센서 ID와 센서 종류를 밑줄로 연결한 문자열입니다. 예를 들어 `0_system`이며, 종류는 `system`, `proc`, `vdd`, `vdn` 중 하나입니다. 이 버전에서는 모든 전력 센서의 OCC 센서 ID가 같습니다.
단위와 버전별 라벨 형식을 정리합니다.
라벨 모양과 부가 속성으로 센서 버전을 추론합니다.
freq[1-n]_label
OCC sensor ID.
freq[1-n]_input
Measured frequency of the component in MHz.
power[1-n]_input
Latest measured power reading of the component in
microwatts.
power[1-n]_average
Average power of the component in microwatts.
power[1-n]_average_interval
The amount of time over which the power average
was taken in microseconds.
[with power sensor version < 2]
power[1-n]_label
OCC sensor ID.
[with power sensor version >= 2]
power[1-n]_label
OCC sensor ID + function ID + channel in the form
of a string, delimited by underscores, i.e. "0_15_1".
Both the function ID and channel are integers that
further identify the power sensor.
[with power sensor version 0xa0]
power[1-n]_label
OCC sensor ID + sensor type in the form of a string,
delimited by an underscore, i.e. "0_system". Sensor
type will be one of "system", "proc", "vdd" or "vdn".
For this sensor version, OCC sensor ID will be the same
for all power sensors.
시스템 전력 상한과 확장 센서
108-153시스템 전체 전력을 나타내는 센서는 master OCC에만 하나 존재합니다. 라벨은 `system`이고, `power[1-n]_input`은 최신 시스템 출력 전력을 마이크로와트로 제공합니다.
`power[1-n]_cap`은 현재 시스템 전력 상한, `cap_not_redundant`는 전원 중복성이 없을 때의 상한, `cap_max`와 `cap_min`은 OCC가 강제할 수 있는 최대·최소 상한을 마이크로와트로 제공합니다.
`power[1-n]_cap_user`는 사용자가 설정한 전력 상한이며 설정되지 않았으면 0을 반환합니다. 이 속성만 읽기·쓰기가 가능하지만 와트 미만의 정밀도는 무시됩니다. 따라서 500900000마이크로와트를 요청해도 실제 요청은 500와트가 됩니다.
caps 센서 버전이 1보다 크면 `power[1-n]_cap_user_source`가 사용자 전력 상한을 설정한 주체를 정수로 나타냅니다. 이 정수는 전력 상한을 설정할 수 있는 시스템 또는 펌웨어 구성 요소에 대응합니다.
`extn` 센서는 기존 분류에 맞지 않는 OCC 데이터를 내보내는 통로입니다. 의미는 데이터에 전적으로 의존하므로 정적으로 정의할 수 없습니다. `extn[1-n]_label`은 ASCII ID 또는 OCC 센서 ID입니다.
`extn[1-n]_flags`는 1바이트 16진수입니다. 비트 7이 1이면 label이 센서 ID, 0이면 ASCII ID이고 나머지 비트는 예약되어 있습니다. `extn[1-n]_input`은 센서 ID가 의미를 정의하는 6바이트 16진 데이터입니다.
master OCC 전력 제어와 확장 데이터 형식을 정리합니다.
지원 범위와 정밀도를 확인해 사용자 상한을 요청합니다.
[present only on "master" OCC; represents the whole system power; only one of
this type of power sensor will be present]
power[1-n]_label
"system"
power[1-n]_input
Latest system output power in microwatts.
power[1-n]_cap
Current system power cap in microwatts.
power[1-n]_cap_not_redundant
System power cap in microwatts when
there is not redundant power.
power[1-n]_cap_max
Maximum power cap that the OCC can enforce in
microwatts.
power[1-n]_cap_min Minimum power cap that the OCC can enforce in
microwatts.
power[1-n]_cap_user The power cap set by the user, in microwatts.
This attribute will return 0 if no user power
cap has been set. This attribute is read-write,
but writing any precision below watts will be
ignored, i.e. requesting a power cap of
500900000 microwatts will result in a power cap
request of 500 watts.
[with caps sensor version > 1]
power[1-n]_cap_user_source
Indicates how the user power cap was
set. This is an integer that maps to
system or firmware components that can
set the user power cap.
The following "extn" sensors are exported as a way for the OCC to provide data
that doesn't fit anywhere else. The meaning of these sensors is entirely
dependent on their data, and cannot be statically defined.
extn[1-n]_label
ASCII ID or OCC sensor ID.
extn[1-n]_flags
This is one byte hexadecimal value. Bit 7 indicates the
type of the label attribute; 1 for sensor ID, 0 for
ASCII ID. Other bits are reserved.
extn[1-n]_input
6 bytes of hexadecimal data, with a meaning defined by
the sensor ID.
요약·해설
occ.rst:1-153I2C 또는 FSI로 OCC 센서를 읽고 버전별 온도·전력 라벨, master OCC의 시스템 상한, 6바이트 확장 데이터를 공개합니다.
원문 분량과 핵심 장치 구성을 정리합니다.
장치 인식부터 측정·제어까지의 핵심 순서입니다.