Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp157397pxy; Thu, 6 May 2021 23:37:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw37/Nj4vPF+C7bjs95CbD1aaeQ+SfEv5iMhj/+5vJTnxsYScfiA+xZk+yPi8gBJEd+WM6W X-Received: by 2002:a17:906:58d6:: with SMTP id e22mr8412010ejs.216.1620369430183; Thu, 06 May 2021 23:37:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620369430; cv=none; d=google.com; s=arc-20160816; b=KTCzzowAp6OJ6vDwL1dcESIFvwucnbNX4P4x74Jtg228nayHuuApSEa9klrNMUXpcZ 1fYG77rnKQPs9vMHwbKE+6EEC3nTYWrHH4IZ+4fPkzHo+vkhVSpIrCWXAPz/hj19ia99 xm57N6x/rRwDJ91Nhi6perPrRjSGQE7L9YiaRI/Sa8zdNx30CooAZJOXcQ42Y5etA8jA QRcZic1IjAGhFj4AS/1PLgwLid6QoPtenZPASPOYkCN2WhRrA7B6PPahglEy+2zGscki aFIamtQeWUsu/iBnZeBlPIVDwI6ya5FelgaC+PDZfKGL+hrELceobJpXKR6VZGAyZmKu Yvdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=rZzXsWAp82UhBV/cokkkVpE7UbqBBMYmOiymy5YiT88=; b=g4iqM4Gh64mAiRuFJVWO/BxJYDv1hx3MUXPSdTfNejhYprGGn2PJHJRU6Hxm4vkLpm Q7Xg3Hs/csS0O2TLeb81HnIGQ3MAZ/qn8M3Qb4/vYsxDva6qiwGOTiawBpblo+P2T4j3 WvSEpUhaIEYQIgCrp0Hb/oE8/39uSjy2HwucVMiuIDl0QfA8+dzy00F6howjgX/nd2xs REZHGm4VqMcqypFsZ0hIcxahNMd6D07n23TlwZlSekxzG8EDG8OxQfWXF4zTczceeDHT TQHAtmE6UAka5rn+ukf14faQQcCsg06GxsUbBah6VE3ly6/h++3ReJMXhvCYlXSMgQms SH1Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=NZCHB4ER; 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=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ke10si4178316ejc.625.2021.05.06.23.36.46; Thu, 06 May 2021 23:37:10 -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=@oracle.com header.s=corp-2020-01-29 header.b=NZCHB4ER; 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=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233179AbhEGFPF (ORCPT + 99 others); Fri, 7 May 2021 01:15:05 -0400 Received: from aserp2130.oracle.com ([141.146.126.79]:34926 "EHLO aserp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229666AbhEGFPF (ORCPT ); Fri, 7 May 2021 01:15:05 -0400 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 1475Dm3E123155; Fri, 7 May 2021 05:13:48 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2020-01-29; bh=rZzXsWAp82UhBV/cokkkVpE7UbqBBMYmOiymy5YiT88=; b=NZCHB4ER1d7tCmdyBNmnlZaokeLVMXDXMhzbTttoTIO2F6G5e0Di4+rVq/c407EHvQMW wSKyki6XtDEHFFVp8hDtDNIDxCXH7m0t98J2pex3qJaDCrzb7oDsYXe7uY8Ea1oZ3put 1pFj10Zgtm1KVYOjYWIpBVUTV+qJLy7MpS809/v3sJyBlDKT6ES+xPUAWnz0MRyjpmWY JdsJ+bqX7WUAmduTfQdeuCoS08L6xOPx38MkBXOLXIHd18gPomUayRqQ49Zq4r6R0nMG EcLmbNtTA2Dvz9DyzTo8DCWLC9vzToeas5W/z7e0wpjtiZyD7FnesIB5gdzmEupIC7Jb DA== Received: from userp3020.oracle.com (userp3020.oracle.com [156.151.31.79]) by aserp2130.oracle.com with ESMTP id 38csrd8d4s-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 07 May 2021 05:13:47 +0000 Received: from pps.filterd (userp3020.oracle.com [127.0.0.1]) by userp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 14759hms174669; Fri, 7 May 2021 05:13:47 GMT Received: from pps.reinject (localhost [127.0.0.1]) by userp3020.oracle.com with ESMTP id 38csrgd545-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 07 May 2021 05:13:47 +0000 Received: from userp3020.oracle.com (userp3020.oracle.com [127.0.0.1]) by pps.reinject (8.16.0.36/8.16.0.36) with SMTP id 1475DkAZ002799; Fri, 7 May 2021 05:13:46 GMT Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userp3020.oracle.com with ESMTP id 38csrgd53x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 07 May 2021 05:13:46 +0000 Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id 1475DibK031033; Fri, 7 May 2021 05:13:44 GMT Received: from kadam (/102.36.221.92) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 06 May 2021 22:13:43 -0700 Date: Fri, 7 May 2021 08:13:33 +0300 From: Dan Carpenter To: Mauro Carvalho Chehab Cc: linuxarm@huawei.com, mauro.chehab@huawei.com, Dmitry Osipenko , Greg Kroah-Hartman , Jonathan Hunter , Mauro Carvalho Chehab , Thierry Reding , linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-staging@lists.linux.dev, linux-tegra@vger.kernel.org Subject: Re: [PATCH v5 05/25] staging: media: tegra-vde: use pm_runtime_resume_and_get() Message-ID: <20210507051333.GE1955@kadam> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-ORIG-GUID: DEXyVdiDsR6x8uVn6eHnJuSxhy2rmyHO X-Proofpoint-GUID: DEXyVdiDsR6x8uVn6eHnJuSxhy2rmyHO X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=9976 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 clxscore=1015 malwarescore=0 adultscore=0 mlxlogscore=999 impostorscore=0 phishscore=0 lowpriorityscore=0 bulkscore=0 priorityscore=1501 mlxscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2104190000 definitions=main-2105070037 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 06, 2021 at 05:25:43PM +0200, Mauro Carvalho Chehab wrote: > @@ -1069,11 +1071,19 @@ static int tegra_vde_probe(struct platform_device *pdev) > * power-cycle it in order to put hardware into a predictable lower > * power state. > */ > - pm_runtime_get_sync(dev); > + if (pm_runtime_resume_and_get(dev) < 0) > + goto err_pm_runtime; Needs an error code on this path. These days the kbuild bot will send a warning for this eventually. > + > pm_runtime_put(dev); > > return 0; > > +err_pm_runtime: > + misc_deregister(&vde->miscdev); > + > + pm_runtime_dont_use_autosuspend(dev); > + pm_runtime_disable(dev); > + > err_deinit_iommu: > tegra_vde_iommu_deinit(vde); > regards, dan carpenter