From patchwork Tue Jun 22 08:38:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: pingshuo X-Patchwork-Id: 466157 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.7 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DEE09C2B9F4 for ; Tue, 22 Jun 2021 08:39:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C76746135A for ; Tue, 22 Jun 2021 08:39:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229890AbhFVIlR (ORCPT ); Tue, 22 Jun 2021 04:41:17 -0400 Received: from lucky1.263xmail.com ([211.157.147.132]:60642 "EHLO lucky1.263xmail.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230411AbhFVIlQ (ORCPT ); Tue, 22 Jun 2021 04:41:16 -0400 Received: from localhost (unknown [192.168.167.235]) by lucky1.263xmail.com (Postfix) with ESMTP id 5CCCDF720B; Tue, 22 Jun 2021 16:38:52 +0800 (CST) X-MAIL-GRAY: 0 X-MAIL-DELIVERY: 1 X-ADDR-CHECKED4: 1 X-SKE-CHECKED: 1 X-ANTISPAM-LEVEL: 2 Received: from localhost.localdomain (unknown [58.240.82.166]) by smtp.263.net (postfix) whith ESMTP id P1335T140034875209472S1624351127067953_; Tue, 22 Jun 2021 16:38:52 +0800 (CST) X-IP-DOMAINF: 1 X-UNIQUE-TAG: X-RL-SENDER: pingshuo@uniontech.com X-SENDER: pingshuo@uniontech.com X-LOGIN-NAME: pingshuo@uniontech.com X-FST-TO: rjw@rjwysocki.net X-RCPT-COUNT: 7 X-SENDER-IP: 58.240.82.166 X-ATTACHMENT-NUM: 0 X-System-Flag: 0 From: pingshuo To: rjw@rjwysocki.net Cc: len.brown@intel.com, pavel@ucw.cz, gregkh@linuxfoundation.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, pingshuo Subject: [PATCH] hibernation:stop resume screen during hibernation Date: Tue, 22 Jun 2021 16:38:44 +0800 Message-Id: <20210622083844.13892-1-pingshuo@uniontech.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org The display will be woken up during hibernation, if the computer equipment is poor, it will cause the screen to flicker. Skip to reusme the display devices in "thaw". Signed-off-by: pingshuo --- drivers/base/power/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c index c7f51c94969d..376b2eca65c7 100644 --- a/drivers/base/power/main.c +++ b/drivers/base/power/main.c @@ -707,7 +707,7 @@ static int dpm_resume_skip_display_devices(struct device *dev, pm_message_t stat { struct pci_dev *pci_test = to_pci_dev(dev); if (state.event == PM_EVENT_THAW) { - /* + /* *Filter out the display devices */ if((pci_test && ((pci_test->class&DISPLAY_PCI_CLASS_VALID_BIT) == DISPLAY_PCI_CLASS))||(dev->driver&&dev->driver->name&&strncmp(dev->driver->name,"video",6)==0))