From patchwork Mon Jun 11 12:25:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 138232 Delivered-To: patch@linaro.org Received: by 2002:a2e:970d:0:0:0:0:0 with SMTP id r13-v6csp3991076lji; Mon, 11 Jun 2018 05:25:26 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKYnYHU5R+OMkGaZrxcCA/DSs7U4HAkBvQlBfdayGucmDIkWlUwX+71qrtAy+kO71MgcSmX X-Received: by 2002:a65:6346:: with SMTP id p6-v6mr14530211pgv.281.1528719926448; Mon, 11 Jun 2018 05:25:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528719926; cv=none; d=google.com; s=arc-20160816; b=lw+nK775JQIyO/jgmPyU1aQs6+gCXbriqeNou8otAzvmEe/bo0hlP2NiNQN0V9vO+l 9NAZOmp4qC7F9dNv7nY4FEVzRrEyac73o0eR9abcit0GSyiP5ktJjGEDT8nDmW9e8PxH VuR7dr8tyEj98rADjCCf2AUcFmtTgFKL1Nc64VC+4tJRe5ItbDmHD4BPNbgByzRMg/Fm yQTF/lZbhpxsnPFpD+SdAG8xJmfiKXvnPQ2uWWlFiwtyT/1JnPFuKnIPf7hTfIxjBOdJ OgzOCfMOndOXpXVjsd+fsJ2/F1pdGDsnNC2GSl/UcLqnGfcXE76yrFuGcNgmd1V4gqf4 PSSA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:cms-type:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature:dkim-filter :arc-authentication-results; bh=RI+usLrpAeG+UyYLvqMqbAhjnxaBIGvVnhns6Rrh9GQ=; b=OKrP53dZA3TIAUEzJxQGhDv3mx0hoYAB97Fov7j5PkcCDkICZGpQ3epMUs3FjAlIPI NWlWcXNCsU1tVRc/5aabwM6tAYbD9nTyH6qRqbAkfHnfUCfD1e6j+amixnvPJAiCPlRh FUktDUKRHdnVnyIhPjIjraz3jiiU4ibSJWIVt6q2IeXRgSjRpr4PRCrZGKm0JGzI5Ent WfgbQUOIw2K0hVwOO12RkTnuyY4pLwEVEEmK4xvPM0Ds1jIxl+1/TWr5tR/j9q3NxH2a 2sZPmiRWScXdLLiluFJanp7YA5qc46JjttiXtdjO/RQugj/Xa48JelY5VOTFglIz8ZHc jHcA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@samsung.com header.s=mail20170921 header.b=KrreDM7R; spf=pass (google.com: best guess record for domain of linux-samsung-soc-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-samsung-soc-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y15-v6si14596657pgv.452.2018.06.11.05.25.26; Mon, 11 Jun 2018 05:25:26 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-samsung-soc-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@samsung.com header.s=mail20170921 header.b=KrreDM7R; spf=pass (google.com: best guess record for domain of linux-samsung-soc-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-samsung-soc-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932910AbeFKMZZ (ORCPT + 3 others); Mon, 11 Jun 2018 08:25:25 -0400 Received: from mailout2.w1.samsung.com ([210.118.77.12]:57918 "EHLO mailout2.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932894AbeFKMZZ (ORCPT ); Mon, 11 Jun 2018 08:25:25 -0400 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20180611122523euoutp02e197b251e3cba827db3632a167bfe759~3Gqu3THAi1593415934euoutp02X; Mon, 11 Jun 2018 12:25:23 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20180611122523euoutp02e197b251e3cba827db3632a167bfe759~3Gqu3THAi1593415934euoutp02X DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1528719923; bh=BX5Y+jTF/G9pPS+/YCSA5+dGGg8sEZfA3jztzseDQJU=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=KrreDM7RacnfkIlnQB4amTnXpzFdUBp/x+ufcOfl0bVc3Mj2JzOjUVDKduSAOlGv+ sQUFGjH6vZ8wo5p3Ma1TWhv4VwsOwY1hRmUTciUCJpNeWu5TdQinGifTiLP1eKCCKC fdEXbLf29W1aygXhPEbJ1+xo9Z57himzY+LKRGxs= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20180611122512eucas1p2a688317698fc1588e0ea3b781d4265c5~3GqkjxuwZ0810708107eucas1p2U; Mon, 11 Jun 2018 12:25:12 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id CD.2B.05700.72A6E1B5; Mon, 11 Jun 2018 13:25:11 +0100 (BST) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20180611122511eucas1p24427aac5e0fe4cc198fbcb43ef4f66c7~3Gqjej4kI1565415654eucas1p20; Mon, 11 Jun 2018 12:25:11 +0000 (GMT) X-AuditID: cbfec7f2-1dbff70000011644-e4-5b1e6a276d32 Received: from eusync1.samsung.com ( [203.254.199.211]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 53.02.04183.72A6E1B5; Mon, 11 Jun 2018 13:25:11 +0100 (BST) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0PA500JG3RTSPN30@eusync1.samsung.com>; Mon, 11 Jun 2018 13:25:11 +0100 (BST) From: Marek Szyprowski To: dri-devel@lists.freedesktop.org, linux-samsung-soc@vger.kernel.org Cc: Marek Szyprowski , Inki Dae , Seung-Woo Kim , Andrzej Hajda , Bartlomiej Zolnierkiewicz , Krzysztof Kozlowski Subject: [PATCH 3/3] drm/exynos: Ensure suspended runtime PM state during system suspend Date: Mon, 11 Jun 2018 14:25:00 +0200 Message-id: <20180611122500.11587-4-m.szyprowski@samsung.com> X-Mailer: git-send-email 2.17.1 In-reply-to: <20180611122500.11587-1-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrFIsWRmVeSWpSXmKPExsWy7djPc7rqWXLRBh8/mlncWneO1WLjjPWs Fle+vmezmHR/AovF+fMb2C1mnN/HZLH2yF0ga/JLNgcOj02rOtk87ncfZ/Lo27KK0ePzJrkA ligum5TUnMyy1CJ9uwSujJVPv7EWbNSt2HTzG2sD4yH1LkZODgkBE4mDu8+wg9hCAisYJbq+ enYxcgHZnxklVl/pY4YperGukw0isYxR4tG/WVBOA5PE3vb/YFVsAoYSXW+72EBsEQE3iabD M1lBiphBiia2LADbISwQJfH6wHZGEJtFQFVixZ5bYHFeAVuJV29OskCsk5dYveEA0FAODk4B O4ldfUIgcyQEGtkktl1qZIOocZF4uLgfql5Y4tXxLewQtozE5cndLBANzYwS7TNmsUM4PYwS W+fsgOq2ljh8/CIriM0swCcxadt0sG0SArwSHW1CECUeEle2H2GFeHMio8TJl3tYJzBKLmBk WMUonlpanJueWmyYl1quV5yYW1yal66XnJ+7iREYg6f/Hf+0g/HrpaRDjAIcjEo8vArpstFC rIllxZW5hxglOJiVRHi9FOSihXhTEiurUovy44tKc1KLDzFKc7AoifPGadRFCQmkJ5akZqem FqQWwWSZODilGhgnusR+b/13xmhrVc3kw8FxFVn3LqvEtVfdivl9Uff3tYtsoW9DbpzYUH25 7GnsdsYlc1P9OC/lch0rO/Uh6oqzbJK4Xez1M29Oq3u8W7LsI+dco6y2ecuSVpnPnlk7xXce v4iqwJZInpyFrBV5rpZSLu05OqfWi59Zu+/BHbUdSX2+GkW7GPcosRRnJBpqMRcVJwIAZCtq +b0CAAA= X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpnluLIzCtJLcpLzFFi42I5/e/4ZV31LLlog+3PWCxurTvHarFxxnpW iytf37NZTLo/gcXi/PkN7BYzzu9jslh75C6QNfklmwOHx6ZVnWwe97uPM3n0bVnF6PF5k1wA SxSXTUpqTmZZapG+XQJXxsqn31gLNupWbLr5jbWB8ZB6FyMnh4SAicSLdZ1sXYxcHEICSxgl /r7ZzQzhNDFJPJz5gg2kik3AUKLrbReYLSLgJtF0eCYrSBEzSNGVtp3sIAlhgSiJ1we2M4LY LAKqEiv23AKL8wrYSrx6c5IFYp28xOoNB4A2cHBwCthJ7OoTAgkLAZVsWTGZfQIjzwJGhlWM IqmlxbnpucVGesWJucWleel6yfm5mxiBwbPt2M8tOxi73gUfYhTgYFTi4VVIl40WYk0sK67M PcQowcGsJMLrpSAXLcSbklhZlVqUH19UmpNafIhRmoNFSZz3vEFllJBAemJJanZqakFqEUyW iYNTqoHxFHds6lThf2azX82a3moaurw9TuZs0AvLBfWu1o0HdPR5s0o3x/7WnL20V9PYPc5u 4mNnizf/Ob+5/A/7erVvnaByxwneTffloudaHigWtj+2V3mz4XYt86Wn+8/8sJFaui9z4rmm 6ktfCxmm+x+J1rLhT73+V/6xvuAyP5mP71hCY42zLvoosRRnJBpqMRcVJwIAm2yQ+RoCAAA= X-CMS-MailID: 20180611122511eucas1p24427aac5e0fe4cc198fbcb43ef4f66c7 X-Msg-Generator: CA CMS-TYPE: 201P X-CMS-RootMailID: 20180611122511eucas1p24427aac5e0fe4cc198fbcb43ef4f66c7 References: <20180611122500.11587-1-m.szyprowski@samsung.com> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org Add calls to pm_runtime_force_{suspend,resume} as SYSTEM_SLEEP_PM_OPS for all drivers for the real Exynos DRM hardware modules. This ensures that the resources will be released for the system PM suspend/resume cycle. Exynos DRM core already takes care of suspending the whole display pipeline before PM callbacks of the real devices are called. Signed-off-by: Marek Szyprowski --- drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 2 ++ drivers/gpu/drm/exynos/exynos7_drm_decon.c | 2 ++ drivers/gpu/drm/exynos/exynos_dp.c | 3 +++ drivers/gpu/drm/exynos/exynos_drm_dsi.c | 2 ++ drivers/gpu/drm/exynos/exynos_drm_fimd.c | 2 ++ drivers/gpu/drm/exynos/exynos_drm_mic.c | 2 ++ drivers/gpu/drm/exynos/exynos_hdmi.c | 2 ++ drivers/gpu/drm/exynos/exynos_mixer.c | 2 ++ 8 files changed, 17 insertions(+) -- 2.17.1 -- To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c index 82c95c34447f..aac0b383027e 100644 --- a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c +++ b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c @@ -673,6 +673,8 @@ static int exynos5433_decon_resume(struct device *dev) static const struct dev_pm_ops exynos5433_decon_pm_ops = { SET_RUNTIME_PM_OPS(exynos5433_decon_suspend, exynos5433_decon_resume, NULL) + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, + pm_runtime_force_resume) }; static const struct of_device_id exynos5433_decon_driver_dt_match[] = { diff --git a/drivers/gpu/drm/exynos/exynos7_drm_decon.c b/drivers/gpu/drm/exynos/exynos7_drm_decon.c index 3931d5e33fe0..88cbd000eb09 100644 --- a/drivers/gpu/drm/exynos/exynos7_drm_decon.c +++ b/drivers/gpu/drm/exynos/exynos7_drm_decon.c @@ -832,6 +832,8 @@ static int exynos7_decon_resume(struct device *dev) static const struct dev_pm_ops exynos7_decon_pm_ops = { SET_RUNTIME_PM_OPS(exynos7_decon_suspend, exynos7_decon_resume, NULL) + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, + pm_runtime_force_resume) }; struct platform_driver decon_driver = { diff --git a/drivers/gpu/drm/exynos/exynos_dp.c b/drivers/gpu/drm/exynos/exynos_dp.c index 86330f396784..7bda7cbb6666 100644 --- a/drivers/gpu/drm/exynos/exynos_dp.c +++ b/drivers/gpu/drm/exynos/exynos_dp.c @@ -16,6 +16,7 @@ #include #include #include +#include #include