Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp951166ybt; Wed, 1 Jul 2020 14:22:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzTC0KilWlgwR9THoZgD76Y9pVPfk5KFrIdvJaoBJfYuIMIkJ2feRqJ7aRVbftGdOkpA1fV X-Received: by 2002:a17:907:72cf:: with SMTP id du15mr23965380ejc.151.1593638559046; Wed, 01 Jul 2020 14:22:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593638559; cv=none; d=google.com; s=arc-20160816; b=otknt+rQ19038ti+TQbiQvNspuEsszo0YypGjpkS0/IdNU6a7qnaKdAnu/7Ylz1X60 ucP8MeX8kJ3yyxGhmcojJd2l0oza4H0DnfvoOb2PJzrMzDopI6YmbioTSXUrHaxbfj1w mC9hZNQb94yrwZUn66OjK5qZ4babu0xAjXOXWWn7TYwnTdbeH196h23Vp9gWOiiaUa+d OgN7MfzgTLdETtu7kfppInUuS9YMfAaeELfkdcNDEptTe3KTATsQELE5xcMpYxlpD+40 2o1ZCZ8YJ+4xkk6rMu3uk8mVLYd+yC4/IlU6kxCP5AAVNTb35cYBCc4aFx3YFvJDOoHZ WYdw== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=rLRInyM1HUBSe42k9HXIZL+IrIZT1shCKCGOH7tBuOA=; b=akVOgs3xl08UNY6bACWFosaWUFpZnHXP6fsl8LYO4EjjSzOA5kq2BlalcYFUDdUauL Fcwmu/20Gzr2DeFtRjAmeYU5FfNSp9Kqr87GPWoNr3M3j/jMX/GkCEBNSXxmaPfcEen5 mqzPACG6przBBkl44VOCPq/+K1iRRSnqBt8gyry/Mgu09C4ctUxvzfQMDbILWq4Shksl 8/b04/7nGwqS9ChljHabU7VONfWxjs5pjDP7WaDQ0WuSUE090ZfKQX3/uYUbEAWA3HPq rH84+mR58rdtZY2rGJBEYCINHkHgCyrundtNhi4YxXxsoUvuI94P+NioY4lMUDU/yzI/ BEeg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="NQvtGT/Z"; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id op5si4450185ejb.617.2020.07.01.14.22.15; Wed, 01 Jul 2020 14:22:39 -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=@ti.com header.s=ti-com-17Q1 header.b="NQvtGT/Z"; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727104AbgGAVVk (ORCPT + 99 others); Wed, 1 Jul 2020 17:21:40 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:60074 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727076AbgGAVVi (ORCPT ); Wed, 1 Jul 2020 17:21:38 -0400 Received: from fllv0034.itg.ti.com ([10.64.40.246]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id 061LLXxS130492; Wed, 1 Jul 2020 16:21:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1593638493; bh=rLRInyM1HUBSe42k9HXIZL+IrIZT1shCKCGOH7tBuOA=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=NQvtGT/ZG8cPpHc0YuQ+p+9b1vhq5YCipHI6/SYBsD7VZ89xI6JSjhmmGAZ3vdfRM pAvBkzy2HXQ83NEJmgL6ed2dSkMGtGuXurAmgiFyd9+N30wGt6Ik5/KIlaGzKUDZVs S6rQR1fmb7ywdo1URRKpUo5B6uPA4rE0bXwvKf7c= Received: from DFLE103.ent.ti.com (dfle103.ent.ti.com [10.64.6.24]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 061LLXCX129314 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 1 Jul 2020 16:21:33 -0500 Received: from DFLE113.ent.ti.com (10.64.6.34) by DFLE103.ent.ti.com (10.64.6.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3; Wed, 1 Jul 2020 16:21:33 -0500 Received: from fllv0040.itg.ti.com (10.64.41.20) by DFLE113.ent.ti.com (10.64.6.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1979.3 via Frontend Transport; Wed, 1 Jul 2020 16:21:33 -0500 Received: from [10.250.70.56] (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0040.itg.ti.com (8.15.2/8.15.2) with ESMTP id 061LLWww081460; Wed, 1 Jul 2020 16:21:32 -0500 Subject: Re: [PATCH 2/2] Revert "remoteproc: Add support for runtime PM" To: Mathieu Poirier , , , CC: , References: <20200630163118.3830422-1-mathieu.poirier@linaro.org> <20200630163118.3830422-3-mathieu.poirier@linaro.org> From: Suman Anna Message-ID: <14cdd336-a2d9-537d-cc61-f47e01f89e9c@ti.com> Date: Wed, 1 Jul 2020 16:21:32 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: <20200630163118.3830422-3-mathieu.poirier@linaro.org> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Mathieu, On 6/30/20 11:31 AM, Mathieu Poirier wrote: > This reverts commit a99a37f6cd5a74d5b22c08544aa6c5890813c8ba. > > Removing PM runtime operations from the remoteproc core in order to: > > 1) Keep all power management operations in platform drivers. That way we > do not loose flexibility in an area that is very HW specific. > > 2) Avoid making the support for remote processor managed by external > entities more complex that it already is. > > 3) Fix regression introduced for the Omap remoteproc driver. Thanks for following up on the discussion, I have verified that the autosuspend regression is fixed. > > Signed-off-by: Mathieu Poirier Tested-by: Suman Anna Acked-by: Suman Anna regards Suman > --- > drivers/remoteproc/remoteproc_core.c | 17 +---------------- > 1 file changed, 1 insertion(+), 16 deletions(-) > > diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c > index 9f04c30c4aaf..0f95e025ba03 100644 > --- a/drivers/remoteproc/remoteproc_core.c > +++ b/drivers/remoteproc/remoteproc_core.c > @@ -29,7 +29,6 @@ > #include > #include > #include > -#include > #include > #include > #include > @@ -1383,12 +1382,6 @@ static int rproc_fw_boot(struct rproc *rproc, const struct firmware *fw) > if (ret) > return ret; > > - ret = pm_runtime_get_sync(dev); > - if (ret < 0) { > - dev_err(dev, "pm_runtime_get_sync failed: %d\n", ret); > - return ret; > - } > - > dev_info(dev, "Booting fw image %s, size %zd\n", name, fw->size); > > /* > @@ -1398,7 +1391,7 @@ static int rproc_fw_boot(struct rproc *rproc, const struct firmware *fw) > ret = rproc_enable_iommu(rproc); > if (ret) { > dev_err(dev, "can't enable iommu: %d\n", ret); > - goto put_pm_runtime; > + return ret; > } > > /* Prepare rproc for firmware loading if needed */ > @@ -1452,8 +1445,6 @@ static int rproc_fw_boot(struct rproc *rproc, const struct firmware *fw) > rproc_unprepare_device(rproc); > disable_iommu: > rproc_disable_iommu(rproc); > -put_pm_runtime: > - pm_runtime_put(dev); > return ret; > } > > @@ -1891,8 +1882,6 @@ void rproc_shutdown(struct rproc *rproc) > > rproc_disable_iommu(rproc); > > - pm_runtime_put(dev); > - > /* Free the copy of the resource table */ > kfree(rproc->cached_table); > rproc->cached_table = NULL; > @@ -2183,9 +2172,6 @@ struct rproc *rproc_alloc(struct device *dev, const char *name, > > rproc->state = RPROC_OFFLINE; > > - pm_runtime_no_callbacks(&rproc->dev); > - pm_runtime_enable(&rproc->dev); > - > return rproc; > > put_device: > @@ -2205,7 +2191,6 @@ EXPORT_SYMBOL(rproc_alloc); > */ > void rproc_free(struct rproc *rproc) > { > - pm_runtime_disable(&rproc->dev); > put_device(&rproc->dev); > } > EXPORT_SYMBOL(rproc_free); >