Skip to contentSkip to conversation

drm/nouveau/dp: nouveau_dp_link_train() returns bool

PATCH New Dan Carpenter 1 participant 1 message Jan 15, 2012

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/nouveau/dp: nouveau_dp_link_train() returns bool

The caller doesn't check the return value, but this function returns a bool so static checkers complain when we return a negative error code.

drivers/gpu/drm/nouveau/nouveau_dp.c +1 -1
index 9b93b70..dcffd13 100644
@@ -573,7 +573,7 @@ nouveau_dp_link_train(struct drm_encoder *encoder, u32 datarate)
 
 	dp.table = nouveau_dp_bios_data(dev, nv_encoder->dcb, &dp.entry);
 	if (!dp.table)
-		return -EINVAL;
+		return false;
 
 	dp.dcb = nv_encoder->dcb;
 	dp.crtc = nv_crtc->index;