Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp734927imm; Wed, 25 Jul 2018 05:25:41 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdwz2t/N0L6KZvEyCxG1nN4mfuY1gcU9TGNn+JuHs50SwYoCUXUknokEKzOFpvo+//7u6d7 X-Received: by 2002:a62:6104:: with SMTP id v4-v6mr21940509pfb.122.1532521541403; Wed, 25 Jul 2018 05:25:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532521541; cv=none; d=google.com; s=arc-20160816; b=vtkpTAYwBSdHRCKLS9HAX0qHyNAB7s3//8q/XbwzuV230f/pgLaPv/5D3RsWfiVZAS X8wWnB1TWOpf8TOlnyhXogiKANzuM0VbW0uzFvrDt+rIMuooyPv53BFUPpjKi+L9pRJ/ H/saHdBxCxDlf5jDPpxbR3swpXgxM2CMYWVdgRvYsIXPupQ0cRQiIk6B8eKxQU9ByM76 BpR5ywmhvXabltFwqGpqz44T/hI0siNG56lrEhb1EQcFN696mLKwO3VPtLX5i+p+oF7M AXvkLZHd77sYF36Sr2b4ZRw8d8lghtGOeYjD5615vPWXehnP6xCFqAM91GD0N8K+oVjA 1iIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=smVtgnLzK+VQCspYZsyGuyVAXjQA1QD+Ys7us8Xb0Ls=; b=PtaexuHfGwX2WsKeQ/20ekzX3rXPuYqMlH+ogbGw5iT1q31FCGF5+uvPVabtZiv2tM mFQ9gvyghT2d8Dkxn5Skn7dXcSGLbf6/v/SXYHThvplstu3fhyBGNAtNEY04sPqzXOUF heNPbX9ATatgNUcQr1pJ+BH9WJ2rgSsYPaCp5HoiX/JGY52qbSYkN4iNWZjXHKDrAgzN IdQVUngJF9X8mYuqkpTkzKSEVNuqxv/PU4Y9c+SGhoVes1tndv1yUi/ve3y8YyOG8bWz YoHw8nS+5OmpI8Tszjko2Yqo7tZKQieJQBsuWCAjtyZExSGzVGmdhyok/q1Bg6AeWAi6 NBHA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d38-v6si13455619pla.422.2018.07.25.05.25.26; Wed, 25 Jul 2018 05:25:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729047AbeGYNfl (ORCPT + 99 others); Wed, 25 Jul 2018 09:35:41 -0400 Received: from mga03.intel.com ([134.134.136.65]:13767 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728757AbeGYNfl (ORCPT ); Wed, 25 Jul 2018 09:35:41 -0400 X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 Jul 2018 05:24:14 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,401,1526367600"; d="scan'208";a="59351807" Received: from paasikivi.fi.intel.com ([10.237.72.42]) by orsmga007.jf.intel.com with ESMTP; 25 Jul 2018 05:24:12 -0700 Received: by paasikivi.fi.intel.com (Postfix, from userid 1000) id 56908204DA; Wed, 25 Jul 2018 15:24:11 +0300 (EEST) Date: Wed, 25 Jul 2018 15:24:11 +0300 From: Sakari Ailus To: Todor Tomov Cc: mchehab@kernel.org, hans.verkuil@cisco.com, laurent.pinchart+renesas@ideasonboard.com, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 18/35] media: camss: Add basic runtime PM support Message-ID: <20180725122411.bgemjrp577lfmje4@paasikivi.fi.intel.com> References: <1532343772-27382-1-git-send-email-todor.tomov@linaro.org> <1532343772-27382-19-git-send-email-todor.tomov@linaro.org> <20180724124916.iyanzu3nux35cudg@paasikivi.fi.intel.com> <096a3fb4-01b8-3096-116f-8562cfb8b6b8@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <096a3fb4-01b8-3096-116f-8562cfb8b6b8@linaro.org> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Todor, On Wed, Jul 25, 2018 at 01:01:31PM +0300, Todor Tomov wrote: > Hi Sakari, > > Thank you for review. > > On 24.07.2018 15:49, Sakari Ailus wrote: > > Hi Todor, > > > > On Mon, Jul 23, 2018 at 02:02:35PM +0300, Todor Tomov wrote: > >> There is a PM domain for each of the VFE hardware modules. Add > >> support for basic runtime PM support to be able to control the > >> PM domains. When a PM domain needs to be powered on - a device > >> link is created. When a PM domain needs to be powered off - > >> its device link is removed. This allows separate and > >> independent control of the PM domains. > >> > >> Suspend/Resume is still not supported. > >> > >> Signed-off-by: Todor Tomov > >> --- > >> drivers/media/platform/qcom/camss/camss-csid.c | 4 ++ > >> drivers/media/platform/qcom/camss/camss-csiphy.c | 5 ++ > >> drivers/media/platform/qcom/camss/camss-ispif.c | 19 ++++++- > >> drivers/media/platform/qcom/camss/camss-vfe.c | 13 +++++ > >> drivers/media/platform/qcom/camss/camss.c | 63 ++++++++++++++++++++++++ > >> drivers/media/platform/qcom/camss/camss.h | 11 +++++ > >> 6 files changed, 113 insertions(+), 2 deletions(-) > >> > >> diff --git a/drivers/media/platform/qcom/camss/camss-csid.c b/drivers/media/platform/qcom/camss/camss-csid.c > >> index 627ef44..ea2b0ba 100644 > >> --- a/drivers/media/platform/qcom/camss/camss-csid.c > >> +++ b/drivers/media/platform/qcom/camss/camss-csid.c > >> @@ -13,6 +13,7 @@ > >> #include > >> #include > >> #include > >> +#include > >> #include > >> #include > >> #include > >> @@ -316,6 +317,8 @@ static int csid_set_power(struct v4l2_subdev *sd, int on) > >> if (on) { > >> u32 hw_version; > >> > >> + pm_runtime_get_sync(dev); > >> + > >> ret = regulator_enable(csid->vdda); > > > > Shouldn't the regulator be enabled in the runtime_resume callback instead? > > Ideally - yes, but it becomes more complex (different pipelines are possible > and we have only one callback) so (at least for now) I have left it as it is > and stated in the commit message that suspend/resume is still not supported. Ack. -- Sakari Ailus sakari.ailus@linux.intel.com