⬢ DragonFlyBSD Kernel Audit
DF-4911 / fix.diff
← back to finding ↓ download raw
--- a/sys/dev/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
+++ b/sys/dev/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
@@ -106,14 +106,13 @@
 		type = AUX_TRANSACTION_TYPE_DP;
 		action = I2CAUX_TRANSACTION_ACTION_DP_WRITE;
 
-		dc_link_aux_transfer(TO_DM_AUX(aux)->ddc_service,
-				     msg->address,
-				     &msg->reply,
-				     msg->buffer,
-				     msg->size,
-				     type,
-				     action);
-		result = msg->size;
+		result = dc_link_aux_transfer(TO_DM_AUX(aux)->ddc_service,
+					      msg->address,
+					      &msg->reply,
+					      msg->buffer,
+					      msg->size,
+					      type,
+					      action);
 		break;
 	case DP_AUX_I2C_READ:
 		type = AUX_TRANSACTION_TYPE_I2C;
@@ -137,14 +136,13 @@
 		else
 			action = I2CAUX_TRANSACTION_ACTION_I2C_WRITE;
 
-		dc_link_aux_transfer(TO_DM_AUX(aux)->ddc_service,
-				     msg->address,
-				     &msg->reply,
-				     msg->buffer,
-				     msg->size,
-				     type,
-				     action);
-		result = msg->size;
+		result = dc_link_aux_transfer(TO_DM_AUX(aux)->ddc_service,
+					      msg->address,
+					      &msg->reply,
+					      msg->buffer,
+					      msg->size,
+					      type,
+					      action);
 		break;
 	default:
 		return -EINVAL;