Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c80d673b authored by Lucas Stach's avatar Lucas Stach Committed by Philipp Zabel
Browse files

drm/imx: imx-ldb: check if channel is enabled before printing warning



If the second LVDS channel has been disabled in the DT when using dual-channel
mode we should not print a warning.

Signed-off-by: default avatarLucas Stach <l.stach@pengutronix.de>
Signed-off-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
parent b5826239
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -655,14 +655,14 @@ static int imx_ldb_bind(struct device *dev, struct device *master, void *data)
		if (ret || i < 0 || i > 1)
		if (ret || i < 0 || i > 1)
			return -EINVAL;
			return -EINVAL;


		if (!of_device_is_available(child))
			continue;

		if (dual && i > 0) {
		if (dual && i > 0) {
			dev_warn(dev, "dual-channel mode, ignoring second output\n");
			dev_warn(dev, "dual-channel mode, ignoring second output\n");
			continue;
			continue;
		}
		}


		if (!of_device_is_available(child))
			continue;

		channel = &imx_ldb->channel[i];
		channel = &imx_ldb->channel[i];
		channel->ldb = imx_ldb;
		channel->ldb = imx_ldb;
		channel->chno = i;
		channel->chno = i;