Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp2172538rdb; Thu, 7 Dec 2023 23:31:02 -0800 (PST) X-Google-Smtp-Source: AGHT+IFope16Ygkk79R8BUldkMq12kNw8dkJeSLFGfjqp3myndmI8yb/dJ4qGLo/HFKgk0LGkN0z X-Received: by 2002:a05:6a20:158b:b0:18f:97c:9774 with SMTP id h11-20020a056a20158b00b0018f097c9774mr4216913pzj.92.1702020662587; Thu, 07 Dec 2023 23:31:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702020662; cv=none; d=google.com; s=arc-20160816; b=bHbUJQs1liSK8QXN9+zxmSqXjXvtY8HMzL9scpTbIF84p1OmpIwb535ziw0N57qwEl ZUxQJpkLuh1z1PetF7wWEKLcUThN3AdVlxZopS7kWoPmR9x7MS2VlDWNXbHXSX4d8/1p BXJwsCX9o4TYgpSU1PVSIrAyGEr+CaLMIrR9UaCDbv7hRk4Ggqgu8QDfHBeSj93iPyI/ KEEHrL1tt/b4dZgVb+iIQ5bUtZVgomM+OpBeHd8KYaHGhley+ewjq+z1S1uyHePVIJtg vK/tagwhjLU3yWoFNZGPkZmgIy9SSpVi8Bp9rApJIg8hUGdjeaSp0pjiu1aIQ8RixCsi mH+Q== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=Lqd+oR1/9Yw4u2jQUrZmD5XRa3aKzcaLuNSBKTGkq30=; fh=habjxf0YG4WcSNEaenG3Vo3U89MQlBfQp/ZbK3+3bDw=; b=BFkXGRawOj0Ch9TZKum9/3tBzdQiCkl6YTGaxxg1ZJDRtTTM5uHjgoID11H7kvVFdT lnPcqxYmtM63DbwyTvS5nXW5dz4FwC6b4QJ37gK/oCZajNeMdXRkGF/FbElVSVVnwmOz fS2KpVDimhFb8h8lFIa5TC9EhIwJC+sciH19kyir5qEwonNBCMqa/uVoXnqCysJKzPAy HBt5Jo2sABKdDxJOu7n7dH2Cld/keSbHrUC2zi0eL3+UO8yfY7P1txweRBmAMKtjWhLw jA+Pa7ix2dcAGCh3CkdfmrmkGYyM2xPNjzT9+hPH67MmRUu3xPIzWU22hcVjbaPbnb/r SdJQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=LWUjqgxc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id d5-20020a170902654500b001d06d5f9ad1si1159644pln.59.2023.12.07.23.31.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 23:31:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=LWUjqgxc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 81FAA823D9E9; Thu, 7 Dec 2023 23:30:59 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233174AbjLHHan (ORCPT + 99 others); Fri, 8 Dec 2023 02:30:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43888 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232216AbjLHHal (ORCPT ); Fri, 8 Dec 2023 02:30:41 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 30927171E for ; Thu, 7 Dec 2023 23:30:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1702020647; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Lqd+oR1/9Yw4u2jQUrZmD5XRa3aKzcaLuNSBKTGkq30=; b=LWUjqgxc4GW9PMmLyvxP66h1uNrU5SE4KOgQRwk7KR5mNu7VIV/twA4pLviNX793hjZXAb fH6+47MaeFgFWMEShm76cDwODvBoibB4z9A4su4yWmMxiJRHIEfmJGpOJJZ7QhcaloK3Bo P+w2KyQoTlZThfqTUHSy9I23F7nhLbw= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-47-owVotutEOF-CVKYkPKJ4lw-1; Fri, 08 Dec 2023 02:30:45 -0500 X-MC-Unique: owVotutEOF-CVKYkPKJ4lw-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 449CC85A588; Fri, 8 Dec 2023 07:30:44 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.72.112.9]) by smtp.corp.redhat.com (Postfix) with ESMTP id 917B98CD0; Fri, 8 Dec 2023 07:30:39 +0000 (UTC) From: Baoquan He To: linux-kernel@vger.kernel.org Cc: linux-next@vger.kernel.org, loongarch@lists.linux.dev, linux-m68k@lists.linux-m68k.org, linux-mips@vger.kernel.org, linux-sh@vger.kernel.org, x86@kernel.org, akpm@linux-foundation.org, eric_devolder@yahoo.com, sfr@canb.auug.org.au, ignat@cloudflare.com, Baoquan He Subject: [PATCH 0/5] kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC Date: Fri, 8 Dec 2023 15:30:31 +0800 Message-ID: <20231208073036.7884-1-bhe@redhat.com> MIME-Version: 1.0 Content-type: text/plain Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.5 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Thu, 07 Dec 2023 23:30:59 -0800 (PST) The select of KEXEC for CRASH_DUMP in kernel/Kconfig.kexec will be dropped, then compiling errors will be triggered if below config items are set: === CONFIG_CRASH_CORE=y CONFIG_KEXEC_CORE=y CONFIG_CRASH_DUMP=y === E.g on mips, below link error are seen: -------------------------------------------------------------------- mipsel-linux-ld: kernel/kexec_core.o: in function `kimage_free': kernel/kexec_core.c:(.text+0x2200): undefined reference to `machine_kexec_cleanup' mipsel-linux-ld: kernel/kexec_core.o: in function `__crash_kexec': kernel/kexec_core.c:(.text+0x2480): undefined reference to `machine_crash_shutdown' mipsel-linux-ld: kernel/kexec_core.c:(.text+0x2488): undefined reference to `machine_kexec' mipsel-linux-ld: kernel/kexec_core.o: in function `kernel_kexec': kernel/kexec_core.c:(.text+0x29b8): undefined reference to `machine_shutdown' mipsel-linux-ld: kernel/kexec_core.c:(.text+0x29c0): undefined reference to `machine_kexec' -------------------------------------------------------------------- Here, change the incorrect dependency of building kexec_core related object files, and the ifdeffery on architectures from CONFIG_KEXEC to CONFIG_KEXEC_CORE. Testing: ======== Passed on mips and loognarch with the LKP reproducer. Baoquan He (5): loongarch, kexec: change dependency of object files m68k, kexec: fix the incorrect ifdeffery and build dependency of CONFIG_KEXEC mips, kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC sh, kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC x86, kexec: fix the wrong ifdeffery CONFIG_KEXEC arch/loongarch/kernel/Makefile | 2 +- arch/m68k/include/asm/kexec.h | 4 ++-- arch/m68k/kernel/Makefile | 2 +- arch/mips/cavium-octeon/smp.c | 4 ++-- arch/mips/include/asm/kexec.h | 2 +- arch/mips/include/asm/smp-ops.h | 2 +- arch/mips/include/asm/smp.h | 2 +- arch/mips/kernel/Makefile | 2 +- arch/mips/kernel/smp-bmips.c | 4 ++-- arch/mips/kernel/smp-cps.c | 10 +++++----- arch/mips/loongson64/reset.c | 4 ++-- arch/mips/loongson64/smp.c | 2 +- arch/sh/include/asm/kexec.h | 4 ++-- arch/sh/kernel/Makefile | 2 +- arch/sh/kernel/reboot.c | 4 ++-- arch/sh/kernel/setup.c | 2 +- arch/x86/boot/compressed/acpi.c | 2 +- 17 files changed, 27 insertions(+), 27 deletions(-) -- 2.41.0