From patchwork Fri Feb 19 19:51:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pasha Tatashin X-Patchwork-Id: 12096067 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.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,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 34D79C433E0 for ; Fri, 19 Feb 2021 19:53:40 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DB09F64E77 for ; Fri, 19 Feb 2021 19:53:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DB09F64E77 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=soleen.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe :List-Id:MIME-Version:Message-Id:Date:Subject:To:From:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Owner; bh=h9TabqRf5Q7l+12m8LJzTQlCkONS3k14UlMbQc8I0Gc=; b=SjOKvDRiah+TAaAFjKr8MWgg8p 7cEhhCNQ29bqcztSpGYZ/U6dqhmTsZxkfkeY0NoGJwcccb8ldDTTs1wbRaUS3EW4zJNddjWCQ1kFz bUZggmfJ2MgP3xdgLs4Ic91o4S5OEfEPG47p4yOWdn1HS9V9riNwGYJWZEsk5prBIwfHaM/1V2udE 4J+wz9/TjGdsYDDl59mdnBXyR95O+9MErdf8MUYMkCV6mGFA8wmXfjaCUY/3zC8Hhu9EqmWAjK9Rk aQBf2MLZRr08FrguadXtCyx2bkVnrGYh/o4n9peLnXXlk40b2J4eF1dYFQw/Bt/TglN+vKS/1Pk25 WtFm/+Mg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1lDBob-00008K-N1; Fri, 19 Feb 2021 19:51:49 +0000 Received: from mail-qt1-x835.google.com ([2607:f8b0:4864:20::835]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1lDBoY-00007X-G5 for linux-arm-kernel@lists.infradead.org; Fri, 19 Feb 2021 19:51:47 +0000 Received: by mail-qt1-x835.google.com with SMTP id t21so1346871qtr.10 for ; Fri, 19 Feb 2021 11:51:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=soleen.com; s=google; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=UqokZIMMK8aC34B+KeiFCW275H8P/pPHySRTbbLs8og=; b=iwXazviBnhZbDsAGWJ5xN0xWYMsrMY8hW7aaidkSL8gG1ktLKKJah9783TJZe87anL 8OfebB7HAKZsup0izD0dbrIlIJWaMgevxubMMovv6zDmMhg/jEnnbEeLhecN0TiiKIso CvXPxhwxSDLdF8P5D5er1s4ghaYtBCoM66oGhRPEyH6L8XmVh+8PK8o7ZlX1VxXN4Uj/ EKboaR1l/m8sINFC29RhOQ8AMm5xA6xBUKR9zsnxIVBNscMLtCv34LtkOJNKGQdEqiSn +mkIIWRi/ZVWR4bU/sNKM8AMr7e6Vosp8BlvU1nfZBlEAoffJIuoQaW/nuvVtMj1IRid CKhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=UqokZIMMK8aC34B+KeiFCW275H8P/pPHySRTbbLs8og=; b=U/bZ4aAvorVLNWx3p4avZJgjaZYsnd3a/8oF1CbzkIPeEkZYpLWb0QCiIVXTyec2mt NT7LlQ90iikqyuxVMvvBMKr11NFM2yTYIsQeTj1oE7YYrZgwuLC/lHhdZh/CPQdy5Drj sbpeOrISRNPnvnBHE6TvTX73oa3EhuUcC899Z1oUHJnAsxHhWlIsyfTmQx9R3JDWygeQ wrY/d5uwSprPqBJQW0TQU9PnoSgSbYMQY2plF7pH5JwVRSTcjyl0IHwqfBCRtJqVGD30 uvuuelkuhqdfy8wtmKOdaVvixSKumRbFFiNUXIfaeas0/8nmi+qKKEDrLW1LxV3k/Pzt QRyw== X-Gm-Message-State: AOAM532eJhRoGv/uSXwUkfWV4o4vK8rKaCk6Z/TpnfKUWsIIYvR5w/nQ UOCn75aSn5dd3u8awjzdNBLObQ== X-Google-Smtp-Source: ABdhPJx20Qu9QiZKnKzdV1KMAiyS4BsADc5EBP+5RQ4Gig0FhAXp9osZQT5d3yaqLiMvIbDB8FNsAw== X-Received: by 2002:ac8:5995:: with SMTP id e21mr10295910qte.294.1613764304102; Fri, 19 Feb 2021 11:51:44 -0800 (PST) Received: from localhost.localdomain (c-73-69-118-222.hsd1.nh.comcast.net. [73.69.118.222]) by smtp.gmail.com with ESMTPSA id b7sm7022848qkj.115.2021.02.19.11.51.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Feb 2021 11:51:43 -0800 (PST) From: Pavel Tatashin To: pasha.tatashin@soleen.com, linux-arm-kernel@lists.infradead.org, jmorris@namei.org, linux-kernel@vger.kernel.org, tyhicks@linux.microsoft.com, will@kernel.org, james.morse@arm.com, ebiederm@xmission.com, kexec@lists.infradead.org Subject: [PATCH v2] kexec: move machine_kexec_post_load() to public interface Date: Fri, 19 Feb 2021 14:51:42 -0500 Message-Id: <20210219195142.13571-1-pasha.tatashin@soleen.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210219_145146_623032_4BA11E48 X-CRM114-Status: GOOD ( 18.86 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org machine_kexec_post_load() is called after kexec load is finished. It must declared in public header not in kexec_internal.h Fixes the following compiler warning: arch/arm64/kernel/machine_kexec.c:62:5: warning: no previous prototype for function 'machine_kexec_post_load' [-Wmissing-prototypes] int machine_kexec_post_load(struct kimage *kimage) Reported-by: kernel test robot Link: https://lore.kernel.org/linux-arm-kernel/202102030727.gqTokACH-lkp@intel.com Signed-off-by: Pavel Tatashin --- include/linux/kexec.h | 2 ++ kernel/kexec_internal.h | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/kexec.h b/include/linux/kexec.h index 9e93bef52968..3671b845cf28 100644 --- a/include/linux/kexec.h +++ b/include/linux/kexec.h @@ -309,6 +309,8 @@ extern void machine_kexec_cleanup(struct kimage *image); extern int kernel_kexec(void); extern struct page *kimage_alloc_control_pages(struct kimage *image, unsigned int order); +int machine_kexec_post_load(struct kimage *image); + extern void __crash_kexec(struct pt_regs *); extern void crash_kexec(struct pt_regs *); int kexec_should_crash(struct task_struct *); diff --git a/kernel/kexec_internal.h b/kernel/kexec_internal.h index 39d30ccf8d87..48aaf2ac0d0d 100644 --- a/kernel/kexec_internal.h +++ b/kernel/kexec_internal.h @@ -13,8 +13,6 @@ void kimage_terminate(struct kimage *image); int kimage_is_destination_range(struct kimage *image, unsigned long start, unsigned long end); -int machine_kexec_post_load(struct kimage *image); - extern struct mutex kexec_mutex; #ifdef CONFIG_KEXEC_FILE