Received: by 2002:a05:7412:a9a3:b0:f9:93eb:408e with SMTP id o35csp7442rdh; Wed, 20 Dec 2023 20:24:52 -0800 (PST) X-Google-Smtp-Source: AGHT+IFR9m63XfQMiSlO9I1pwt13JNnmsqs9KpetBLmUb1TM4kW/3FkbMCSMRSDHeKpB8dMFId1K X-Received: by 2002:a05:6830:1249:b0:6db:ac45:fd1c with SMTP id s9-20020a056830124900b006dbac45fd1cmr2101228otp.16.1703132692661; Wed, 20 Dec 2023 20:24:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703132692; cv=none; d=google.com; s=arc-20160816; b=c9UXNOxpMyyMISkyFlIL+6ldL29+27gamVvVsBssxpHLXucv2u9ZMM5ZNhboyh6DPQ q1gr7nBJhJvBjs6VYEYrq1xsY7DyAXOZI43GQ5gQrkJ+vvdvA8Y8CHAhkTV9Xbn4wgI1 8o1T/McFC+hji/KHNBROteiTv3aW4TmzXXHNTXRV5uV65sMDhEjGljGkheHBLGTPX7IQ nCZooLidMRBIW97Jc095lxJ83Ex+4k6sCM4G1wAwFSuxIBwbczkKxSl6no7fqWGvB0nb itXk3vebIiof5sMP8mmofdL7wOoFefTqU1JSxG4Rm4pg97cGfPaThd8WCz23CO/VKKjW t+Hw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=WhkevBRKRAIXA24fCJp1C71d7JyUUhFCr+p5mrM6R0s=; fh=Z7AG/6tiMfOTl9Ta/UZNZdI1a8EWhwLqe+KzD+UASyc=; b=oaTIas6Y/BtmpL97mTn8vtNpsFluNqcqEkT0ImrJrc0HLABj5twHLyMbiYMGw+qWuB +ZQvTqKoUendg2M2+fhK/itSO4pFZ11X+ANR9A3Uk+tNiMfVPcnLCkNIvk8TDynZ87Qg cI0DK0dqvHGX2LCqjEmb6+a4DZVcWlK18/0c4x+aSOA43gEmYEL/odfml5v/3DOYQP0Y uzLMfDHObRmDMDwofH1cJYPM2JcqimAFLaKfTdDrrwLDXxxrl4n8ztBBHaFB3WsLqxz4 HMsLy1wC2+zLdXh/Qai5uQUhI/bCLL8q75RPUre0P0ff4hzTxri/3CcokLYkHpR4jH/K iQ8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=BJyFJ2i5; spf=pass (google.com: domain of linux-kernel+bounces-7833-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-7833-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id s7-20020a635e07000000b005c20241fdf2si874900pgb.49.2023.12.20.20.24.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Dec 2023 20:24:52 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-7833-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=BJyFJ2i5; spf=pass (google.com: domain of linux-kernel+bounces-7833-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-7833-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 50F6E287D2E for ; Thu, 21 Dec 2023 04:24:52 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EB3F9848C; Thu, 21 Dec 2023 04:24:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="BJyFJ2i5" X-Original-To: linux-kernel@vger.kernel.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6415D7481 for ; Thu, 21 Dec 2023 04:24:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1703132682; 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: in-reply-to:in-reply-to:references:references; bh=WhkevBRKRAIXA24fCJp1C71d7JyUUhFCr+p5mrM6R0s=; b=BJyFJ2i5vSMOm66FOLRDcRN9j8GAE6TpsNARwFnAreP3DB2vUy6WCk1ZHS7z4OmxNJc6q1 6vXUMKRmrpQ5GOqzx7zpXw/+KWntLicPlM0kd5Vc+Yc51DN7cmKWPSB28M+i5u82NdikUQ AV4R0XJF79kiuCtq5I+gasu8q/naZ8Y= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-591-O5_yBCcsMgqWoLnAiNkmRg-1; Wed, 20 Dec 2023 23:24:38 -0500 X-MC-Unique: O5_yBCcsMgqWoLnAiNkmRg-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) (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 535C038562CA; Thu, 21 Dec 2023 04:24:37 +0000 (UTC) Received: from localhost (unknown [10.72.116.38]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5A42140C6EB9; Thu, 21 Dec 2023 04:24:36 +0000 (UTC) Date: Thu, 21 Dec 2023 12:24:28 +0800 From: Baoquan He To: Al Viro Cc: kernel test robot , oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org, Andrew Morton , Linux Memory Management List Subject: Re: arch/sh/kernel/relocate_kernel.S:38: Error: invalid operands for opcode Message-ID: References: <202312182200.Ka7MzifQ-lkp@intel.com> <20231220060030.GV1674809@ZenIV> <20231220173710.GX1674809@ZenIV> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231220173710.GX1674809@ZenIV> X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.2 On 12/20/23 at 05:37pm, Al Viro wrote: > On Wed, Dec 20, 2023 at 09:27:32PM +0800, Baoquan He wrote: > > Since the kexec_core code building depends on CONFIG_MMU=y, we may > > need to add dependency on MMU for ARCH_SUPPORTS_CRASH_DUMP. I made below > > change, do you think it's OK? > > > > diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig > > index 7500521b2b98..fe1500871648 100644 > > --- a/arch/sh/Kconfig > > +++ b/arch/sh/Kconfig > > @@ -548,6 +548,7 @@ config ARCH_SUPPORTS_KEXEC > > > > config ARCH_SUPPORTS_CRASH_DUMP > > def_bool BROKEN_ON_SMP > > + depends on MMU > > > > config ARCH_SUPPORTS_KEXEC_JUMP > > def_bool y > > > > I'm *not* familiar with crashdump or kexec machinery, let alone the > current changes in there, so take the following with a cartload of > salt, but... does sh crash dump support depend upon the code in > question? From quick grep it looks like we only want it in machine_kexec(), > so the conditionals used in the commit in question might be wrong... Hmm, I checked commit d70c27b728b8da1 ("sh, kexec: fix the incorrect ifdeffery and dependency of CONFIG_KEXEC") again, those ifdeffery of CONFIG_KEXEC_CORE should be changed to CONFIG_CRASH_CORE because those embraced codes are crash_core related codes. machine_kexec() is needed by kexec reboot and crash dumping. We either enable CONFIG_KEXEC_CORE, CONFIG_KEXEC or CONFIG_KEXEC_FILE only for kexec reboot, or enable CONFIG_KEXEC_CORE, CONFIG_KEXEC or CONFIG_KEXEC_FILE and CONFIG_CRASH_CORE, CONFIG_CRASH_DUMP to support kexec reboot and crash dumping. Seems KEXEC_CORE codes can be built not relying on CRASH_CORE, while CRASH_CORE need be built relying on KEXEC_CORE, otherwise it doesn't make sense. Anyway, I will try to clean up the ifdeffery so that they looks clearer.