Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2657919pxj; Mon, 14 Jun 2021 04:13:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyJOS1BZMHIrBQLK6gid5eEq9pt/+Upe/TyVBNl4w81DaUmkj1x/NBvK7g45y1Io7Hcofx6 X-Received: by 2002:a05:6402:cb1:: with SMTP id cn17mr16446358edb.42.1623669199997; Mon, 14 Jun 2021 04:13:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623669199; cv=none; d=google.com; s=arc-20160816; b=C08UGeq6KWrt6fnyUSXsoCj/Y6cJb3QhmRmnNJPooV3qJwRj9oW3iAAH5qM79Wcy17 c0/y03jf8kq/QVkJCqBX/hWWDUNdMSr6Vw6OgrEtpKxk5C3EN4Rm6TqDwnKDiraAM52x Ti/+zPdaUqeotW3Od2gzv6hCP6LyuMOgdrKTGqw5Iw4veLCcWuK1ymE7bmcMDjQdTFDc tSqYZX4x0uqiUmLqboW71sX2qaVtfTtOLYArLztRW8ZXp9/vKXHsTZfWefJls7oAIpFd o//n1HQbuKXIW4mU2ebrNr0Eq3ogZnfiEaHpwQl8zj71QOMfwnKiUA4zuCmGO+2KZK9H 2dvg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=HBj3X5qEobP/YGH/FveVgaS9DbUiDfgRhUx/yMRoN94=; b=Ji/gFFxVlA8Ys9LpCS0gxw1pjQLiMkX6VauoRSKfJgKwNS61ou8g4yJd3uSwE1b38Z VteSSg9G6HcErWMM0HpnP1BVw6imWL7gZQ0Mcgk0nu8LAuY4g9Go/SCQiX93bldKpWBm MjZgxAaKizejA3IcXwrEQDnJgeim99o6D/B9JGsd+gKnqp1okP1SR+PZr6YgSzYhgH3i 8O20RwQC3bAGe4/4gYrBu4g5bEXMw9VFSRncXQuMH+5sP2YhX669jfjZoyY6DKYADYWK fl4QmV0H6ToNo33qJNCEx3zE/wMY6QpeMf5ekcgJMw0cBoAvo34r+mQZn+Mx/gTxWYtt iaeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=AkqhyDcN; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j3si11476744ejj.516.2021.06.14.04.12.56; Mon, 14 Jun 2021 04:13:19 -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=@linuxfoundation.org header.s=korg header.b=AkqhyDcN; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234540AbhFNLMw (ORCPT + 99 others); Mon, 14 Jun 2021 07:12:52 -0400 Received: from mail.kernel.org ([198.145.29.99]:35824 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233830AbhFNLAp (ORCPT ); Mon, 14 Jun 2021 07:00:45 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C49FA6162F; Mon, 14 Jun 2021 10:43:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1623667391; bh=yP091ATsF9sSYq3kWijW/heKOsq+HSjUAsAoy4i+UiM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AkqhyDcN85NIjaoYR+1UMUHKqRjfRiFNK2H/eka4V1is9gESB8aGKWgTLc7Qu7ArU TdMu9N7oK33JNfELsRgBtB8mmgJOYGYpo1a766GnRGCTu3wRxQYqnB/+jCxAEWn1fb 8aYDWGP/hUBQtho05eAp3rv4TXqKUrKeRpXWAxIE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Stephan Hohe , Zhang Rui , "Rafael J. Wysocki" Subject: [PATCH 5.10 053/131] Revert "ACPI: sleep: Put the FACS table after using it" Date: Mon, 14 Jun 2021 12:26:54 +0200 Message-Id: <20210614102654.826578905@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210614102652.964395392@linuxfoundation.org> References: <20210614102652.964395392@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Zhang Rui commit f1ffa9d4cccc8fdf6c03fb1b3429154d22037988 upstream. Commit 95722237cb2a ("ACPI: sleep: Put the FACS table after using it") puts the FACS table during initialization. But the hardware signature bits in the FACS table need to be accessed, after every hibernation, to compare with the original hardware signature. So there is no reason to release the FACS table mapping after initialization. This reverts commit 95722237cb2ae4f7b73471058cdb19e8f4057c93. An alternative solution is to use acpi_gbl_FACS variable instead, which is mapped by the ACPICA core and never released. Link: https://bugzilla.kernel.org/show_bug.cgi?id=212277 Reported-by: Stephan Hohe Signed-off-by: Zhang Rui Cc: 5.8+ # 5.8+ Signed-off-by: Rafael J. Wysocki Signed-off-by: Greg Kroah-Hartman --- drivers/acpi/sleep.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/drivers/acpi/sleep.c +++ b/drivers/acpi/sleep.c @@ -1290,10 +1290,8 @@ static void acpi_sleep_hibernate_setup(v return; acpi_get_table(ACPI_SIG_FACS, 1, (struct acpi_table_header **)&facs); - if (facs) { + if (facs) s4_hardware_signature = facs->hardware_signature; - acpi_put_table((struct acpi_table_header *)facs); - } } #else /* !CONFIG_HIBERNATION */ static inline void acpi_sleep_hibernate_setup(void) {}