Received: by 2002:ac0:8c9a:0:0:0:0:0 with SMTP id r26csp1492038ima; Sat, 2 Feb 2019 01:41:55 -0800 (PST) X-Google-Smtp-Source: ALg8bN6MkaVfYZmKQlMdlShyA2FbnfGQSTYFPYg29NQtwiyk0GhzfMa4+PfgqO/0QP19cB5YRlZD X-Received: by 2002:a62:33c1:: with SMTP id z184mr42622511pfz.104.1549100515261; Sat, 02 Feb 2019 01:41:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549100515; cv=none; d=google.com; s=arc-20160816; b=ez4Bcac1oN0jZMqLNX5sZOQWaHWwRnwqMWrMnhN5XlDo/gAAdLPBdz9xySbfUtQgLc 5zZ5WyEzLe8qfQUIHo3aHWSJNJAiZKPg/ckarGQwiSFWdhBOcZvxVXA1K9pFtnFg7u/Z IdPJbPvBdREYvKGE6jc+nFi1GYe8fXdHXBRyv6G8nOLElZPtGCaUMV3Bh1pY2j98ugkp SwnIuCtO7j2Y7wolMhzeVJnF9O3+ftawKqjoovH+r+EAJ9pOeKnR1QB2x0K5g580n7CB KMQnkHh0EGPUk4C/5xSuBZVb0hCVVk9MWDrEdalnUTilnn2HiTa4bNyWgRmEZvbtQrLf /ViA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=5ao+30GUUv3JmbT29dbzmjqtVn+kpmSTNQBPMeuNpw0=; b=QBSGYsOPCFFmX1YvdY65Biv0/r5NQAykg22HiWSfRX5YcruhEmyZDMngKU4QAwXO5m gjfsVEo6HG6WBgcMpGB2T3l1LNkKcPNrzrE4/NVLJYG2xs1lUEXhnY6/RnbSzcFXKG7m u4+uNWq+DN7X3gHAQf/BqA2zJAQR+rK3N59qDdMGuSkx7447VQvYbG/NhVcrrY4aNtxE wQ0KXnmKTlEaGfvVLkNs4dtoWNF9i8KU5MfXCrRSZFuGcd28/Zx8VxVcr+HY+sh5aRlX Hjw7/W1f+IaaFDTOMY0lMjgp4sHEs1HQXuC/HgOxE6U2OdRV/gShLTH2nXQF/uJqV/Yn lCZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="QtL/btXv"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w6si9849840pfb.191.2019.02.02.01.41.39; Sat, 02 Feb 2019 01:41:55 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="QtL/btXv"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727399AbfBBJld (ORCPT + 99 others); Sat, 2 Feb 2019 04:41:33 -0500 Received: from mail-ed1-f66.google.com ([209.85.208.66]:38718 "EHLO mail-ed1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726757AbfBBJl3 (ORCPT ); Sat, 2 Feb 2019 04:41:29 -0500 Received: by mail-ed1-f66.google.com with SMTP id h50so7470693ede.5 for ; Sat, 02 Feb 2019 01:41:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=5ao+30GUUv3JmbT29dbzmjqtVn+kpmSTNQBPMeuNpw0=; b=QtL/btXv+JQejhbxpnCT/+uaHPxfhK9CQdc/bjQyvOIzCvoxLQ7yjdqOPuu5mnWhG/ TnYWSMZYJv42Lf1xev1Rj0B/OBJ47rUtPxc6KdVrrsk84d2pR8OJ6lbWc5tmL6lbA/dq r/0r6OCF/p5JNkmMo/78bFLebXYKu92zd57Go= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=5ao+30GUUv3JmbT29dbzmjqtVn+kpmSTNQBPMeuNpw0=; b=JXpAQrC9WlSncONVKqykQPZcDM9Qhq7qS2AN4k/Od7k1p2RREjo6SMBTPZNPYAjaP6 ixjVUoh2jIBm3CedJtGLNzHKiMNj/bs2QoCZ4/ALi6mSzxkrQwzbfrTtUgjk3GaFRuZo pwcHk8KjjBZ6s+L0nXRh3MZn3hpG89chHVlg2B1idy1sVFP3BIHM69pc3yAAoozZmaBQ Gm+ve0G6H0Hlx1/kz88KfZCCflkW0YStOU7uB0w+6/oYp8NHvKAyM0VbtGm2Df0lLqCz 85TfFXQCr2nT1H6RvLvUWPDsyVr4pS8gvo0lXOhrotH7QM+wNQP4wp22+9o47mZCS8A3 uzuw== X-Gm-Message-State: AJcUukfLLtAhIp4eD1C7d9vicRlp6FXI9P+USNstYeK13HgA/nzL4Bmo RRbd6dQlwzTxNaLoLKEd0a3hIY6pibuH9A== X-Received: by 2002:a50:c9c3:: with SMTP id c3mr42040854edi.56.1549100488380; Sat, 02 Feb 2019 01:41:28 -0800 (PST) Received: from mba13.c.hoisthospitality.com ([109.236.135.164]) by smtp.gmail.com with ESMTPSA id l41sm2608824eda.83.2019.02.02.01.41.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 02 Feb 2019 01:41:27 -0800 (PST) From: Ard Biesheuvel To: linux-efi@vger.kernel.org, Ingo Molnar , Thomas Gleixner Cc: Ard Biesheuvel , linux-kernel@vger.kernel.org, AKASHI Takahiro , Alexander Graf , Bjorn Andersson , Borislav Petkov , Heinrich Schuchardt , Jeffrey Hugo , Lee Jones , Leif Lindholm , Linus Torvalds , Peter Jones , Peter Zijlstra , Sai Praneeth Prakhya Subject: [PATCH 01/10] x86/efi: Mark can_free_region() as an __init function Date: Sat, 2 Feb 2019 10:41:10 +0100 Message-Id: <20190202094119.13230-2-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190202094119.13230-1-ard.biesheuvel@linaro.org> References: <20190202094119.13230-1-ard.biesheuvel@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sai Praneeth Prakhya can_free_region() is called only once during _boot_ by efi_reserve_boot_services(). Hence, mark it as __init function. Signed-off-by: Sai Praneeth Prakhya Signed-off-by: Ard Biesheuvel --- arch/x86/platform/efi/quirks.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/platform/efi/quirks.c b/arch/x86/platform/efi/quirks.c index 17456a1d3f04..9ce85e605052 100644 --- a/arch/x86/platform/efi/quirks.c +++ b/arch/x86/platform/efi/quirks.c @@ -304,7 +304,7 @@ void __init efi_arch_mem_reserve(phys_addr_t addr, u64 size) * - Not within any part of the kernel * - Not the BIOS reserved area (E820_TYPE_RESERVED, E820_TYPE_NVS, etc) */ -static bool can_free_region(u64 start, u64 size) +static __init bool can_free_region(u64 start, u64 size) { if (start + size > __pa_symbol(_text) && start <= __pa_symbol(_end)) return false; -- 2.17.1