Commit 7a80c2c9 authored by Alex Deucher's avatar Alex Deucher

drm/radeon: fix typo in atom voltage table handling (6xx-ni)

Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 4bd9f516
...@@ -3150,7 +3150,7 @@ radeon_atom_is_voltage_gpio(struct radeon_device *rdev, ...@@ -3150,7 +3150,7 @@ radeon_atom_is_voltage_gpio(struct radeon_device *rdev,
break; break;
case 2: case 2:
num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) / num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) /
sizeof(ATOM_VOLTAGE_OBJECT_INFO_V2); sizeof(ATOM_VOLTAGE_OBJECT_V2);
for (i = 0; i < num_indices; i++) { for (i = 0; i < num_indices; i++) {
if ((voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) && if ((voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) &&
...@@ -3231,7 +3231,7 @@ int radeon_atom_get_max_voltage(struct radeon_device *rdev, ...@@ -3231,7 +3231,7 @@ int radeon_atom_get_max_voltage(struct radeon_device *rdev,
break; break;
case 2: case 2:
num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) / num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) /
sizeof(ATOM_VOLTAGE_OBJECT_INFO_V2); sizeof(ATOM_VOLTAGE_OBJECT_V2);
for (i = 0; i < num_indices; i++) { for (i = 0; i < num_indices; i++) {
if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) { if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) {
...@@ -3287,7 +3287,7 @@ int radeon_atom_get_min_voltage(struct radeon_device *rdev, ...@@ -3287,7 +3287,7 @@ int radeon_atom_get_min_voltage(struct radeon_device *rdev,
break; break;
case 2: case 2:
num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) / num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) /
sizeof(ATOM_VOLTAGE_OBJECT_INFO_V2); sizeof(ATOM_VOLTAGE_OBJECT_V2);
for (i = 0; i < num_indices; i++) { for (i = 0; i < num_indices; i++) {
if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) { if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) {
...@@ -3406,7 +3406,7 @@ int radeon_atom_get_voltage_table(struct radeon_device *rdev, ...@@ -3406,7 +3406,7 @@ int radeon_atom_get_voltage_table(struct radeon_device *rdev,
return -EINVAL; return -EINVAL;
case 2: case 2:
num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) / num_indices = (size - sizeof(ATOM_COMMON_TABLE_HEADER)) /
sizeof(ATOM_VOLTAGE_OBJECT_INFO_V2); sizeof(ATOM_VOLTAGE_OBJECT_V2);
for (i = 0; i < num_indices; i++) { for (i = 0; i < num_indices; i++) {
if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) { if (voltage_info->v2.asVoltageObj[i].ucVoltageType == voltage_type) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment