drm/vc4: crtc: Rename HVS channel to output
authorMaxime Ripard <maxime@cerno.tech>
Thu, 3 Sep 2020 08:00:42 +0000 (10:00 +0200)
committerMaxime Ripard <maxime@cerno.tech>
Mon, 7 Sep 2020 16:02:29 +0000 (18:02 +0200)
In vc5, the HVS has 6 outputs and 3 FIFOs (or channels), with
pixelvalves each being assigned to a given output, but each output can
then be muxed to feed from multiple FIFOs.

Since vc4 had that entirely static, both were probably equivalent, but
since that changes, let's rename hvs_channel to hvs_output in the
vc4_crtc_data, since a pixelvalve is really connected to an output, and
not to a FIFO.

Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Tested-by: Chanwoo Choi <cw00.choi@samsung.com>
Tested-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Tested-by: Stefan Wahren <stefan.wahren@i2se.com>
Reviewed-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Link: https://patchwork.freedesktop.org/patch/msgid/b7618bb17b1c435c5d6ce50bcde2fe9243281d02.1599120059.git-series.maxime@cerno.tech
drivers/gpu/drm/vc4/vc4_crtc.c
drivers/gpu/drm/vc4/vc4_drv.h
drivers/gpu/drm/vc4/vc4_hvs.c
drivers/gpu/drm/vc4/vc4_txp.c

index fdecaba7783630663f456ddb19ecb0eefbef83ca..d3126fe04d9a34823ff785d0c75063a21a3b7e51 100644 (file)
@@ -775,7 +775,7 @@ static const struct drm_crtc_helper_funcs vc4_crtc_helper_funcs = {
 
 static const struct vc4_pv_data bcm2835_pv0_data = {
        .base = {
-               .hvs_channel = 0,
+               .hvs_output = 0,
        },
        .debugfs_name = "crtc0_regs",
        .pixels_per_clock = 1,
@@ -787,7 +787,7 @@ static const struct vc4_pv_data bcm2835_pv0_data = {
 
 static const struct vc4_pv_data bcm2835_pv1_data = {
        .base = {
-               .hvs_channel = 2,
+               .hvs_output = 2,
        },
        .debugfs_name = "crtc1_regs",
        .pixels_per_clock = 1,
@@ -799,7 +799,7 @@ static const struct vc4_pv_data bcm2835_pv1_data = {
 
 static const struct vc4_pv_data bcm2835_pv2_data = {
        .base = {
-               .hvs_channel = 1,
+               .hvs_output = 1,
        },
        .debugfs_name = "crtc2_regs",
        .pixels_per_clock = 1,
@@ -862,7 +862,7 @@ int vc4_crtc_init(struct drm_device *drm, struct vc4_crtc *vc4_crtc,
        drm_crtc_init_with_planes(drm, crtc, primary_plane, NULL,
                                  crtc_funcs, NULL);
        drm_crtc_helper_add(crtc, crtc_helper_funcs);
-       vc4_crtc->channel = vc4_crtc->data->hvs_channel;
+       vc4_crtc->channel = vc4_crtc->data->hvs_output;
        drm_mode_crtc_set_gamma_size(crtc, ARRAY_SIZE(vc4_crtc->lut_r));
        drm_crtc_enable_color_mgmt(crtc, 0, false, crtc->gamma_size);
 
index d80fc3bbb45036f78e0655f9f96ac24b56ef4a4a..d1cf4c038180c4eece61120e2bdd0ba53d625884 100644 (file)
@@ -447,8 +447,8 @@ to_vc4_encoder(struct drm_encoder *encoder)
 }
 
 struct vc4_crtc_data {
-       /* Which channel of the HVS this pixelvalve sources from. */
-       int hvs_channel;
+       /* Which output of the HVS this pixelvalve sources from. */
+       int hvs_output;
 };
 
 struct vc4_pv_data {
index abdb43c4cc10dffc601cf8910d77f14acb523ce7..365425d67f3f4938836b440d09f4ca4f046d394c 100644 (file)
@@ -419,7 +419,7 @@ void vc4_hvs_mode_set_nofb(struct drm_crtc *crtc)
        struct drm_display_mode *mode = &crtc->state->adjusted_mode;
        bool interlace = mode->flags & DRM_MODE_FLAG_INTERLACE;
 
-       if (vc4_crtc->data->hvs_channel == 2) {
+       if (vc4_crtc->data->hvs_output == 2) {
                u32 dispctrl;
                u32 dsp3_mux;
 
index a7c3af0005a0aa0908ff0c46a0d312b95eeb6a96..f39d9900d027bb086595cf8e8f4b6ad47127633d 100644 (file)
@@ -452,7 +452,7 @@ static irqreturn_t vc4_txp_interrupt(int irq, void *data)
 }
 
 static const struct vc4_crtc_data vc4_txp_crtc_data = {
-       .hvs_channel = 2,
+       .hvs_output = 2,
 };
 
 static int vc4_txp_bind(struct device *dev, struct device *master, void *data)