Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp754589ybt; Wed, 8 Jul 2020 10:49:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyCR6Bt/vUHDNKrIga8n3WBEzAxBfuODaw4kGpFl0scsAbZszuSo877rP7klDRLr2FX+AKR X-Received: by 2002:a17:907:7283:: with SMTP id dt3mr54833508ejc.195.1594230561893; Wed, 08 Jul 2020 10:49:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594230561; cv=none; d=google.com; s=arc-20160816; b=sKX1OnD3KmtlYvsnFwZrTolzmyrdHdhfk3agYG4Cn8ljPNtZ78ebX/IlN70AEV3aZq 3RdmLGeHtmV8BBghwFFDrRm1YeWo2lNPh/YufgnRjsRG1cq3RCkg0rEw0Fh1WuGijr/b W7DPwDskduufq/UbvAkBdahQmZhCQXvgWD+VOM3XMsvGlqZbeT8G+7JrP9pWnWPvAafF hj2myodtXymHRD3VADE/dY8w+/OLsJ0BCvyPR01ILMqqIu+1hr1X13eA0hvF7c3Ac6Hb uGbQo+23S3knxifopOQzernPSJal/BvY8xsq7LSIfbfOBqqfkI3v3dZmk1UOonFYcF+D 98bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-signature; bh=PXyOrhteRhuIW3gAa3UTeL+v8wa9wTNvkAai0iITr1g=; b=K/KrM2mB8HzAeMvIjFCKd08y8bO1Cn8IGb0VYxOAgABrEmWAIVE9Rz2X7wBAjIyNVY 9V+MS8uXHtgQSGv0Tk+9iPuui0Rv7BvWH7DwJXEI3ZYk50ZWjNr4nbDQ5qGoppN0Nnn6 PVDncLza6dWWczwSt3ChcpY31BTIEy0rjaASBJXGRDuy0i/KQwGalK2y0GGtttKA1zH1 FmpasAEaTdsk1iX0AazKCPyxus0u9RUiJvz3DPkyXiXt7gnufjqH3Yyx76QegMDk7CZ5 eIn5Q5QiEPXwtC7lx45B6VD6UQnNhdEx7b6YfV+X3997HtA+zBv+KnoCsMKeetvkhtqk lIQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=QnD9HeXp; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=BR6M2hXu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ci18si345990ejb.0.2020.07.08.10.48.58; Wed, 08 Jul 2020 10:49:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=QnD9HeXp; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=BR6M2hXu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=cerno.tech Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727116AbgGHRrb (ORCPT + 99 others); Wed, 8 Jul 2020 13:47:31 -0400 Received: from wnew4-smtp.messagingengine.com ([64.147.123.18]:54481 "EHLO wnew4-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726774AbgGHRnD (ORCPT ); Wed, 8 Jul 2020 13:43:03 -0400 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.west.internal (Postfix) with ESMTP id EED85FD0; Wed, 8 Jul 2020 13:43:01 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Wed, 08 Jul 2020 13:43:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; s=fm3; bh=PXyOrhteRhuIW 3gAa3UTeL+v8wa9wTNvkAai0iITr1g=; b=QnD9HeXpBI4112vzPdB+Fcw+vkmZ2 ToR7uIAdTpegqZ0Ufy8QvbRi0ILu08S5BcbP3hBtWBqoB12zDrwUTasAOHbCWU2f s2IkjV58BeWvNoB1NrCnuo7w5QNaEX/dDDs35KApVJ1rrdLT3ry0n2A2d+IMQ0UT AZLD3pbc5osrVQvl0YLvObB4xQXs/cmBXv1Fs2cUBhhHCvoul7nn7gNuFxdmDZU8 3sxvLZAYZSV83qrWGXJrG1mhzOruBiDNDmsWBDdhe9NXbaOMYTahy+nRXcvj+p19 WGFJyXG53e4BbLfmm1AaYpHWcc/bfQmyFHXob9h2dCVTKILKUL/vbze6A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=PXyOrhteRhuIW3gAa3UTeL+v8wa9wTNvkAai0iITr1g=; b=BR6M2hXu BEw0yS+B9mXUo2bHdvMcpMacVV2VZjqF6VqXMFTOc+JZc/MubTKUNTFjXPSb2LQA xbBVAH/WF9QaY4bpic8/E1en4qtJShcV+SXKcDqp+yloZ9nMxOvhA8jEWICfytn0 7rjp/tiwKTi+e6/ApMX5QQOyAEPCFo4qWwBOa8Bndx3fKHGCsMkhPr8GqSmqWJtl lviu2hx0XV0/UyzuTt/G/y9HW43j7+OBhSA5Nwk6bo2cGCyaa8bOsgi8OynqUEZt kIlrEEW5EgjXc7VIoai3ajGVRm+eSuKjjEgrsli3gwsJsXNMAib8cDODe+FnS5IA AkrSWff5lGSrFA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduiedrudejgdduudejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpeforgigihhm vgcutfhiphgrrhguuceomhgrgihimhgvsegtvghrnhhordhtvggthheqnecuggftrfgrth htvghrnhepvdekleevfeffkeejhfffueelteelfeduieefheduudfggffhhfffheevveeh hedvnecukfhppeeltddrkeelrdeikedrjeeinecuvehluhhsthgvrhfuihiivgepudelne curfgrrhgrmhepmhgrihhlfhhrohhmpehmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Received: from localhost (lfbn-tou-1-1502-76.w90-89.abo.wanadoo.fr [90.89.68.76]) by mail.messagingengine.com (Postfix) with ESMTPA id 4859D30600B7; Wed, 8 Jul 2020 13:43:01 -0400 (EDT) From: Maxime Ripard To: Nicolas Saenz Julienne , Eric Anholt Cc: dri-devel@lists.freedesktop.org, linux-rpi-kernel@lists.infradead.org, bcm-kernel-feedback-list@broadcom.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Dave Stevenson , Tim Gover , Phil Elwell , Maxime Ripard Subject: [PATCH v4 21/78] drm/vc4: crtc: Move PV dump to config_pv Date: Wed, 8 Jul 2020 19:41:29 +0200 Message-Id: X-Mailer: git-send-email 2.26.2 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Now that we only configure the PixelValve in vc4_crtc_config_pv, it doesn't really make much sense to dump its register content in its caller. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_crtc.c | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_crtc.c b/drivers/gpu/drm/vc4/vc4_crtc.c index c2ab907611e3..181d3fd57bc7 100644 --- a/drivers/gpu/drm/vc4/vc4_crtc.c +++ b/drivers/gpu/drm/vc4/vc4_crtc.c @@ -290,6 +290,14 @@ static void vc4_crtc_config_pv(struct drm_crtc *crtc) vc4_encoder->type == VC4_ENCODER_TYPE_DSI1); u32 format = is_dsi ? PV_CONTROL_FORMAT_DSIV_24 : PV_CONTROL_FORMAT_24; u8 ppc = pv_data->pixels_per_clock; + bool debug_dump_regs = false; + + if (debug_dump_regs) { + struct drm_printer p = drm_info_printer(&vc4_crtc->pdev->dev); + dev_info(&vc4_crtc->pdev->dev, "CRTC %d regs before:\n", + drm_crtc_index(crtc)); + drm_print_regset32(&p, &vc4_crtc->regset); + } vc4_crtc_pixelvalve_reset(crtc); @@ -359,30 +367,20 @@ static void vc4_crtc_config_pv(struct drm_crtc *crtc) PV_CONTROL_WAIT_HSTART | VC4_SET_FIELD(vc4_encoder->clock_select, PV_CONTROL_CLK_SELECT)); -} - -static void vc4_crtc_mode_set_nofb(struct drm_crtc *crtc) -{ - struct vc4_crtc *vc4_crtc = to_vc4_crtc(crtc); - bool debug_dump_regs = false; if (debug_dump_regs) { struct drm_printer p = drm_info_printer(&vc4_crtc->pdev->dev); - dev_info(&vc4_crtc->pdev->dev, "CRTC %d regs before:\n", + dev_info(&vc4_crtc->pdev->dev, "CRTC %d regs after:\n", drm_crtc_index(crtc)); drm_print_regset32(&p, &vc4_crtc->regset); } +} +static void vc4_crtc_mode_set_nofb(struct drm_crtc *crtc) +{ vc4_crtc_config_pv(crtc); vc4_hvs_mode_set_nofb(crtc); - - if (debug_dump_regs) { - struct drm_printer p = drm_info_printer(&vc4_crtc->pdev->dev); - dev_info(&vc4_crtc->pdev->dev, "CRTC %d regs after:\n", - drm_crtc_index(crtc)); - drm_print_regset32(&p, &vc4_crtc->regset); - } } static void require_hvs_enabled(struct drm_device *dev) -- git-series 0.9.1