- adi,disable-timing-generator: Only for ADV7533 and ADV7535. Disables the
internal timing generator. The chip will rely on the sync signals in the DSI
data lanes, rather than generate its own timings for HDMI output.
+- adi,dsi-channel: Only for ADV7533 and ADV7535. DSI channel number to be used
+ when communicating with the DSI peripheral. It should be one of 0, 1, 2 or 3.
Required nodes:
struct mipi_dsi_device *dsi;
int ret = 0;
const struct mipi_dsi_device_info info = { .type = "adv7533",
- .channel = 0,
+ .channel = adv->channel_id,
.node = NULL,
};
int adv7533_parse_dt(struct device_node *np, struct adv7511 *adv)
{
- u32 num_lanes;
+ struct device *dev = &adv->i2c_main->dev;
+ u32 num_lanes = 0, channel_id = 0;
struct device_node *endpoint;
+ of_property_read_u32(np, "adi,dsi-channel", &channel_id);
of_property_read_u32(np, "adi,dsi-lanes", &num_lanes);
- if (num_lanes < 1 || num_lanes > 4)
+ if (num_lanes < 1 || num_lanes > 4) {
+ dev_err(dev, "Invalid dsi-lanes: %d\n", num_lanes);
return -EINVAL;
+ }
+
+ if (channel_id > 3) {
+ dev_err(dev, "Invalid dsi-channel: %d\n", channel_id);
+ return -EINVAL;
+ }
adv->num_dsi_lanes = num_lanes;
+ adv->channel_id = channel_id;
endpoint = of_graph_get_next_endpoint(np, NULL);
if (!endpoint)