Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp455984ybg; Tue, 9 Jun 2020 05:10:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw9sMJseHWW3arhGQvBh0VYpNa4KeJT9+lAsOJqFyYYtH0WZ7686VsQWOZMyikiOaIUCjAo X-Received: by 2002:a17:906:2615:: with SMTP id h21mr24604661ejc.84.1591704616934; Tue, 09 Jun 2020 05:10:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591704616; cv=none; d=google.com; s=arc-20160816; b=SGrSkPm0sdZfxt9qLwfL1WEijjh8MBpY4BNscWh3G8mFGiHiUWUAR3kSeQt/g22tGD bXG/RFAUlFu2NwAW+ZQfEIa/rIYjntH3xJeN/0AcOtNGjrPfRKHAd1RsdfnIqk3HvM/O D8Dgm5OqlC1Bl17ImupLCjvoYrsTRnOlZ+6AN5MCQu9si020Yeu6OiVRZuz1I99/XKGU k6rPcUJ3v7nDW30l1rxwYXI6gR1UXaR/rEBoSxxuJpO5gMlTIZ1TsmBjzKAvjC09+89J DTeTmSJoB/otBfG5ZaQpGegu26OlhPL8xZyEsy48CBe28fWw7gpZe8CADPMluwQZz+xb mD1Q== 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 :message-id:date:subject:cc:to:from; bh=Tt2P1pNkzS/wgJQ+M1fkH1Q6XjtJq/KuafSc7LA7tCE=; b=EkNThNwEEE/tMllPAbms6kXicVl83BGQHoULXwGPcg/8CyUQzn+ae3QtQL7mlrIJPZ YQF8aucpNLQbLZBWedIoJ2ywXYnYeZm2IzbK0tTFqGZayi11jiHjJBVDzwM1RSJhbWVR N7c9WA3cQMajbQtv9gHQf/eG7rLRpwQIQuqvOEg9HMPfBrWoXG3c2fUMMmMqithGuwmx I9fln1lvVlbIQcO0uCS8/YPRbNd+GHtbHbwtUOdbVN0fQs2VfT+URp6CYNYsEvliL4cm 4vfeeSQbdpvrKDUElaTL6AJAyK85G5yGT82FotLntBxeuAY4CWdlOBiQRieD8ynotHbZ LRwg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w11si11326876edl.171.2020.06.09.05.09.53; Tue, 09 Jun 2020 05:10:16 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729217AbgFIMF3 (ORCPT + 99 others); Tue, 9 Jun 2020 08:05:29 -0400 Received: from alexa-out-blr-01.qualcomm.com ([103.229.18.197]:42521 "EHLO alexa-out-blr-01.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728051AbgFIMF0 (ORCPT ); Tue, 9 Jun 2020 08:05:26 -0400 Received: from ironmsg02-blr.qualcomm.com ([10.86.208.131]) by alexa-out-blr-01.qualcomm.com with ESMTP/TLS/AES256-SHA; 09 Jun 2020 17:35:23 +0530 Received: from harigovi-linux.qualcomm.com ([10.204.66.157]) by ironmsg02-blr.qualcomm.com with ESMTP; 09 Jun 2020 17:35:01 +0530 Received: by harigovi-linux.qualcomm.com (Postfix, from userid 2332695) id 3D1C82055; Tue, 9 Jun 2020 17:35:01 +0530 (IST) From: Harigovindan P To: dri-devel@lists.freedesktop.org, linux-arm-msm@vger.kernel.org, freedreno@lists.freedesktop.org, devicetree@vger.kernel.org Cc: Harigovindan P , linux-kernel@vger.kernel.org, robdclark@gmail.com, seanpaul@chromium.org, hoegsberg@chromium.org, kalyan_t@codeaurora.org, nganji@codeaurora.org, sam@ravnborg.org Subject: [v3] drm/bridge: ti-sn65dsi86: ensure bridge suspend happens during PM sleep Date: Tue, 9 Jun 2020 17:34:55 +0530 Message-Id: <20200609120455.20458-1-harigovi@codeaurora.org> X-Mailer: git-send-email 2.27.0 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 ti-sn65dsi86 bridge is enumerated as a runtime device. When suspend is triggered, PM core adds a refcount on all the devices and calls device suspend, since usage count is already incremented, runtime suspend will not be called and it kept the bridge regulators and gpios ON which resulted in platform not entering into XO shutdown. Add changes to force suspend on the runtime device during pm sleep. Signed-off-by: Harigovindan P --- Changes in v2: - Include bridge name in the commit message and remove dependent patchwork link from the commit text as bridge is independent of OEM(Stephen Boyd) Changes in v3: - Updating changelog to explain the need for patch drivers/gpu/drm/bridge/ti-sn65dsi86.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/bridge/ti-sn65dsi86.c b/drivers/gpu/drm/bridge/ti-sn65dsi86.c index 6ad688b320ae..2eef755b2917 100644 --- a/drivers/gpu/drm/bridge/ti-sn65dsi86.c +++ b/drivers/gpu/drm/bridge/ti-sn65dsi86.c @@ -159,6 +159,8 @@ static int __maybe_unused ti_sn_bridge_suspend(struct device *dev) static const struct dev_pm_ops ti_sn_bridge_pm_ops = { SET_RUNTIME_PM_OPS(ti_sn_bridge_suspend, ti_sn_bridge_resume, NULL) + SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, + pm_runtime_force_resume) }; static int status_show(struct seq_file *s, void *data) -- 2.27.0