Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1569993

Re: [PATCH v3 08/24] drm/rockchip: dw-mipi-dsi: respect message flags

Path csiph.com!1.us.feeder.erje.net!2.eu.feeder.erje.net!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!news.unit0.net!news.panservice.it!bofh.it!news.nic.it!robomod
From Sean Paul <seanpaul@chromium.org>
Newsgroups linux.kernel
Subject Re: [PATCH v3 08/24] drm/rockchip: dw-mipi-dsi: respect message flags
Date Mon, 30 Jan 2017 19:30:03 +0100
Message-ID <t5oSf-7ij-37@gated-at.bofh.it> (permalink)
References <t4Yl3-811-7@gated-at.bofh.it> <t4Yl4-811-29@gated-at.bofh.it>
Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=1iK5399m35A93RDwymSgzvlB3f2Ov6C7K8gb15inJ/Q=; b=L4w6QlHtiyu1X4RZ//c51PTVTffTtyBe5jaY6v/z9k2xoxEqAeQMgmxf5i8I+nGEtB 0bIx0J6f9IQIaA2HnNl0FFSi7N7a21+m67b/0O9WgIrOemwqGTtjP6gmdUAMa+uS04Fs dXpOIeXL+ylBAenxZSVRL0bvcXN9ocdVRVYfM=
X-Google-Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=1iK5399m35A93RDwymSgzvlB3f2Ov6C7K8gb15inJ/Q=; b=jrtrYRUvwE8kJHoqmaBxvYlM+yFnJD+tfonXJxWwnjpLbStyVoqH67OaL+9/xNFse7 FtLjdYLd+ttlLQSdaNfFXSCspUCqfWAKqBT1SK77SrIoT3O8PpXEIPah1iL1Yqr0uO8w ozsg0EhYwOcUWHfV+98GD/8Di4IwDR/XuHORe/Nqq1QAtToAGQGA9DAIBwLth+Qj7Sgz ZtTWjjKib/0VmWtmwWmhnjYWGqql0Au0chvF9ymYMpQr7iHfAaOs7N2LJD+I7AauUEhX 8+ryMAxQKE+h8s/FTKXhy7FRUl/n9m2CUbxqhqFyTHMd8QEiB1lO8tfBdODmn57ZV4+t zx0w==
X-Gm-Message-State AIkVDXJfpC0N3PorSsef6X3n9XZxyhtwetXiYtwSWy2OhclcxIEbZXZ/lgesCKXHwlezLbdc
X-Received by 10.200.48.65 with SMTP id g1mr21109301qte.94.1485800364570; Mon, 30 Jan 2017 10:19:24 -0800 (PST)
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.5.21 (2010-09-15)
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 69
Organization linux.* mail to news gateway
X-Original-Cc Mark Yao <mark.yao@rock-chips.com>, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-rockchip@lists.infradead.org, Chris Zhong <zyw@rock-chips.com>, linux-arm-kernel@lists.infradead.org
X-Original-Date Mon, 30 Jan 2017 13:19:22 -0500
X-Original-Message-ID <20170130181922.GI20076@art_vandelay>
X-Original-References <20170129132444.25251-1-john@metanate.com> <20170129132444.25251-9-john@metanate.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1569993

Show key headers only | View raw


On Sun, Jan 29, 2017 at 01:24:28PM +0000, John Keeping wrote:
> Instead of always sending commands in LP mode, respect the
> MIPI_DSI_MSG_USE_LPM flag to decide how to send each message.  Also
> request acks if MIPI_DSI_MSG_REQ_ACK is set.
> 

Reviewed-by: Sean Paul <seanpaul@chromium.org>

> Signed-off-by: John Keeping <john@metanate.com>
> Reviewed-by: Chris Zhong <zyw@rock-chips.com>
> ---
> v3:
> - Add Chris' Reviewed-by
> Unchanged in v2
> 
>  drivers/gpu/drm/rockchip/dw-mipi-dsi.c | 16 +++++++++++++++-
>  1 file changed, 15 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
> index 92dbc3e56603..15d33c3c8cb7 100644
> --- a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c
> @@ -542,6 +542,19 @@ static int dw_mipi_dsi_host_detach(struct mipi_dsi_host *host,
>  	return 0;
>  }
>  
> +static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> +				   const struct mipi_dsi_msg *msg)
> +{
> +	u32 val = 0;
> +
> +	if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> +		val |= EN_ACK_RQST;
> +	if (msg->flags & MIPI_DSI_MSG_USE_LPM)
> +		val |= CMD_MODE_ALL_LP;
> +
> +	dsi_write(dsi, DSI_CMD_MODE_CFG, val);
> +}
> +
>  static int dw_mipi_dsi_gen_pkt_hdr_write(struct dw_mipi_dsi *dsi, u32 hdr_val)
>  {
>  	int ret;
> @@ -634,6 +647,8 @@ static ssize_t dw_mipi_dsi_host_transfer(struct mipi_dsi_host *host,
>  	struct dw_mipi_dsi *dsi = host_to_dsi(host);
>  	int ret;
>  
> +	dw_mipi_message_config(dsi, msg);
> +
>  	switch (msg->type) {
>  	case MIPI_DSI_DCS_SHORT_WRITE:
>  	case MIPI_DSI_DCS_SHORT_WRITE_PARAM:
> @@ -745,7 +760,6 @@ static void dw_mipi_dsi_command_mode_config(struct dw_mipi_dsi *dsi)
>  {
>  	dsi_write(dsi, DSI_TO_CNT_CFG, HSTX_TO_CNT(1000) | LPRX_TO_CNT(1000));
>  	dsi_write(dsi, DSI_BTA_TO_CNT, 0xd00);
> -	dsi_write(dsi, DSI_CMD_MODE_CFG, CMD_MODE_ALL_LP);
>  	dsi_write(dsi, DSI_MODE_CFG, ENABLE_CMD_MODE);
>  }
>  
> -- 
> 2.11.0.197.gb556de5.dirty
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Sean Paul, Software Engineer, Google / Chromium OS

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 00/24] drm/rockchip: MIPI fixes & improvements John Keeping <john@metanate.com> - 2017-01-29 15:10 +0100
  [PATCH v3 08/24] drm/rockchip: dw-mipi-dsi: respect message flags John Keeping <john@metanate.com> - 2017-01-29 15:10 +0100
    Re: [PATCH v3 08/24] drm/rockchip: dw-mipi-dsi: respect message flags Sean Paul <seanpaul@chromium.org> - 2017-01-30 19:30 +0100
  [PATCH v3 01/24] drm/rockchip: dw-mipi-dsi: don't configure hardware in mode_set for MIPI John Keeping <john@metanate.com> - 2017-01-29 15:10 +0100
    Re: [PATCH v3 01/24] drm/rockchip: dw-mipi-dsi: don't configure  hardware in mode_set for MIPI Sean Paul <seanpaul@chromium.org> - 2017-01-30 16:40 +0100
  [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read commands John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read commands Sean Paul <seanpaul@chromium.org> - 2017-01-30 16:40 +0100
      Re: [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read  commands John Keeping <john@metanate.com> - 2017-01-30 19:40 +0100
        Re: [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read commands Sean Paul <seanpaul@chromium.org> - 2017-01-30 21:20 +0100
          Re: [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read  commands John Keeping <john@metanate.com> - 2017-01-31 13:50 +0100
            Re: [PATCH v3 24/24] drm/rockchip: dw-mipi-dsi: support read commands Sean Paul <seanpaul@chromium.org> - 2017-01-31 15:50 +0100
  [PATCH v3 11/24] drm/rockchip: dw-mipi-dsi: prepare panel after phy init John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 11/24] drm/rockchip: dw-mipi-dsi: prepare panel after  phy init Sean Paul <seanpaul@chromium.org> - 2017-01-30 21:20 +0100
  [PATCH v3 05/24] drm/rockchip: dw-mipi-dsi: fix generic packet status check John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 05/24] drm/rockchip: dw-mipi-dsi: fix generic packet  status check Sean Paul <seanpaul@chromium.org> - 2017-01-30 19:30 +0100
  [PATCH v3 07/24] drm/rockchip: dw-mipi-dsi: include bad value in error message John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 07/24] drm/rockchip: dw-mipi-dsi: include bad value in  error message Sean Paul <seanpaul@chromium.org> - 2017-01-30 19:10 +0100
  [PATCH v3 20/24] drm/rockchip: vop: test for P{H,V}SYNC John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 20/24] drm/rockchip: vop: test for P{H,V}SYNC Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:20 +0100
  [PATCH v3 12/24] drm/rockchip: dw-mipi-dsi: allow commands in panel_disable John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 12/24] drm/rockchip: dw-mipi-dsi: allow commands in  panel_disable Sean Paul <seanpaul@chromium.org> - 2017-01-30 21:30 +0100
      Re: [PATCH v3 12/24] drm/rockchip: dw-mipi-dsi: allow commands in  panel_disable John Keeping <john@metanate.com> - 2017-01-31 13:30 +0100
  [PATCH v3 13/24] drm/rockchip: dw-mipi-dsi: fix escape clock rate John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 13/24] drm/rockchip: dw-mipi-dsi: fix escape clock rate Sean Paul <seanpaul@chromium.org> - 2017-01-30 21:30 +0100
      Re: [PATCH v3 13/24] drm/rockchip: dw-mipi-dsi: fix escape clock  rate John Keeping <john@metanate.com> - 2017-02-01 18:30 +0100
  [PATCH v3 18/24] drm/rockchip: dw-mipi-dsi: use specific poll helper John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 18/24] drm/rockchip: dw-mipi-dsi: use specific poll  helper Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:00 +0100
  [PATCH v3 04/24] drm/rockchip: dw-mipi-dsi: fix command header writes John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 04/24] drm/rockchip: dw-mipi-dsi: fix command header  writes Sean Paul <seanpaul@chromium.org> - 2017-01-30 17:00 +0100
  [PATCH v3 15/24] drm/rockchip: dw-mipi-dsi: configure PHY before enabling John Keeping <john@metanate.com> - 2017-01-29 15:50 +0100
    Re: [PATCH v3 15/24] drm/rockchip: dw-mipi-dsi: configure PHY before  enabling Sean Paul <seanpaul@chromium.org> - 2017-01-30 21:30 +0100
      Re: [PATCH v3 15/24] drm/rockchip: dw-mipi-dsi: configure PHY  before enabling John Keeping <john@metanate.com> - 2017-01-31 13:40 +0100
  [PATCH v3 19/24] drm/rockchip: dw-mipi-dsi: use positive check for N{H,V}SYNC John Keeping <john@metanate.com> - 2017-01-29 16:20 +0100
    Re: [PATCH v3 19/24] drm/rockchip: dw-mipi-dsi: use positive check  for N{H, V}SYNC Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:20 +0100
  [PATCH v3 17/24] drm/rockchip: dw-mipi-dsi: improve PLL configuration John Keeping <john@metanate.com> - 2017-01-29 16:20 +0100
    Re: [PATCH v3 17/24] drm/rockchip: dw-mipi-dsi: improve PLL  configuration Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:20 +0100
  [PATCH v3 23/24] drm/rockchip: dw-mipi-dsi: add reset control John Keeping <john@metanate.com> - 2017-01-29 16:30 +0100
    Re: [PATCH v3 23/24] drm/rockchip: dw-mipi-dsi: add reset control Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:30 +0100
  [PATCH v3 03/24] drm/rockchip: dw-mipi-dsi: remove mode_set hook John Keeping <john@metanate.com> - 2017-01-29 16:30 +0100
    Re: [PATCH v3 03/24] drm/rockchip: dw-mipi-dsi: remove mode_set hook Sean Paul <seanpaul@chromium.org> - 2017-01-30 16:50 +0100
  [PATCH v3 22/24] drm/rockchip: dw-mipi-dsi: support non-burst modes John Keeping <john@metanate.com> - 2017-01-29 16:30 +0100
    Re: [PATCH v3 22/24] drm/rockchip: dw-mipi-dsi: support non-burst  modes Sean Paul <seanpaul@chromium.org> - 2017-01-31 20:30 +0100

csiph-web