drm/vc4: hvs: Make the HVS bind first
authorMaxime Ripard <maxime@cerno.tech>
Thu, 25 Feb 2021 13:42:03 +0000 (14:42 +0100)
committerPhil Elwell <8911409+pelwell@users.noreply.github.com>
Wed, 21 Apr 2021 13:13:56 +0000 (14:13 +0100)
We'll need to have the HVS binding before the HDMI controllers so that
we can check whether the firmware allows to run in 4kp60. Reorder a bit
the component list, and document the current constraints we're aware of.

Acked-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
drivers/gpu/drm/vc4/vc4_drv.c

index 8baa90837e9e6201a16809e63363529a1225bf09..c404ef49f42057dc9ea95dfa7107dfadea044d21 100644 (file)
@@ -390,12 +390,21 @@ static const struct component_master_ops vc4_drm_ops = {
        .unbind = vc4_drm_unbind,
 };
 
+/*
+ * This list determines the binding order of our components, and we have
+ * a few constraints:
+ *   - The TXP driver needs to be bound before the PixelValves (CRTC)
+ *     but after the HVS to set the possible_crtc field properly
+ *   - The HDMI driver needs to be bound after the HVS so that we can
+ *     lookup the HVS maximum core clock rate and figure out if we
+ *     support 4kp60 or not.
+ */
 static struct platform_driver *const component_drivers[] = {
+       &vc4_hvs_driver,
        &vc4_hdmi_driver,
        &vc4_vec_driver,
        &vc4_dpi_driver,
        &vc4_dsi_driver,
-       &vc4_hvs_driver,
        &vc4_txp_driver,
        &vc4_crtc_driver,
        &vc4_firmware_kms_driver,