From mboxrd@z Thu Jan 1 00:00:00 1970 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=-15.1 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable 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 C16F4C433B4 for ; Thu, 22 Apr 2021 02:16:54 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (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 E9D026144E for ; Thu, 22 Apr 2021 02:16:53 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E9D026144E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4FQgz83jsnz30G7 for ; Thu, 22 Apr 2021 12:16:52 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; secure) header.d=infradead.org header.i=@infradead.org header.a=rsa-sha256 header.s=casper.20170209 header.b=F777hQDb; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=infradead.org (client-ip=2001:8b0:10b:1236::1; helo=casper.infradead.org; envelope-from=rdunlap@infradead.org; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=infradead.org header.i=@infradead.org header.a=rsa-sha256 header.s=casper.20170209 header.b=F777hQDb; dkim-atps=neutral Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) (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 lists.ozlabs.org (Postfix) with ESMTPS id 4FQgyf1Rmlz2yQq for ; Thu, 22 Apr 2021 12:16:25 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description; bh=JuQAmZqUk3bRNh1XZwrWFpM3HTNgjK1ts7jiO0LN48c=; b=F777hQDbPDuiwIs+waU1S9C5+L GpkOWCurFKa85QLdjS7vbpkS0e0K1ZTM3/tsgOmM3RPY+HQuALOiCu3yZB/pAxHlUTwOtTFmMsK/E MQGXlT35VrZGI96F7+HEyUdwjsU2BnpQ1JuZW4xvvAEkfn99IvHVJK7c17ByrWuIYAhRydSvXR/rE q8MDIsSTCvBZUyOr4yRlbNcbCwky9aRcxVV1waGaAL5qMZqWr6aGS1wEzWmBB50PTx5opG/bJzcUZ 43lkYfB0WP4Cx3GXnrEwn2mP7hRZeSoXVMDWLB4rMd/lSquSnfWOD1HYIsI1NO5sZ7P0RCdUXQxPp 3Vsa/e3A==; Received: from [2601:1c0:6280:3f0::df68] by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1lZOsy-00HK4T-D3; Thu, 22 Apr 2021 02:16:12 +0000 Subject: Re: mmu.c:undefined reference to `patch__hash_page_A0' To: Christophe Leroy , kernel test robot References: <202102271820.WlZCxtzY-lkp@intel.com> <06227600-c5c5-3da7-a495-ae0b0849b62d@infradead.org> <0a301d17-136c-df65-17cc-3c9ddbe06de8@infradead.org> From: Randy Dunlap Message-ID: Date: Wed, 21 Apr 2021 19:16:04 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 8bit X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: PowerPC , kbuild-all@lists.01.org, linux-kernel@vger.kernel.org Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On 4/21/21 1:43 AM, Christophe Leroy wrote: > > > Le 18/04/2021 à 19:15, Randy Dunlap a écrit : >> On 4/18/21 3:43 AM, Christophe Leroy wrote: >>> >>> >>> Le 18/04/2021 à 02:02, Randy Dunlap a écrit : >>>> HI-- >>>> >>>> I no longer see this build error. >>> >>> Fixed by https://github.com/torvalds/linux/commit/acdad8fb4a1574323db88f98a38b630691574e16 >>> >>>> However: >>>> ... >>>> >>>> I do see this build error: >>>> >>>> powerpc-linux-ld: arch/powerpc/boot/wrapper.a(decompress.o): in function `partial_decompress': >>>> decompress.c:(.text+0x1f0): undefined reference to `__decompress' >>>> >>>> when either >>>> CONFIG_KERNEL_LZO=y >>>> or >>>> CONFIG_KERNEL_LZMA=y >>>> >>>> but the build succeeds when either >>>> CONFIG_KERNEL_GZIP=y >>>> or >>>> CONFIG_KERNEL_XZ=y >>>> >>>> I guess that is due to arch/powerpc/boot/decompress.c doing this: >>>> >>>> #ifdef CONFIG_KERNEL_GZIP >>>> #    include "decompress_inflate.c" >>>> #endif >>>> >>>> #ifdef CONFIG_KERNEL_XZ >>>> #    include "xz_config.h" >>>> #    include "../../../lib/decompress_unxz.c" >>>> #endif >>>> >>>> >>>> It would be nice to require one of KERNEL_GZIP or KERNEL_XZ >>>> to be set/enabled (maybe unless a uImage is being built?). >>> >>> >>> Can you test by https://patchwork.ozlabs.org/project/linuxppc-dev/patch/a74fce4dfc9fa32da6ce3470bbedcecf795de1ec.1591189069.git.christophe.leroy@csgroup.eu/ ? >> >> Hi Christophe, >> >> I get build errors for both LZO and LZMA: >> > > Can you check with the following changes on top of my patch: > > diff --git a/lib/decompress_unlzo.c b/lib/decompress_unlzo.c > index a8dbde4b32d4..f06f925385c0 100644 > --- a/lib/decompress_unlzo.c > +++ b/lib/decompress_unlzo.c > @@ -23,13 +23,15 @@ >  #include >  #endif > > -#include >  #ifdef __KERNEL__ >  #include > +#endif > +#include > +#ifdef __KERNEL__ >  #include > +#include >  #endif > > -#include >  #include > >  static const unsigned char lzop_magic[] = { Hi Christophe, Sorry for the delay -- it's been a very busy day here. For CONFIG_KERNEL_LZMA=y, I get a couple of warnings: BOOTCC arch/powerpc/boot/decompress.o In file included from ../arch/powerpc/boot/decompress.c:38: ../arch/powerpc/boot/../../../lib/decompress_unlzma.c: In function 'unlzma': ../arch/powerpc/boot/../../../lib/decompress_unlzma.c:582:21: warning: pointer targets in passing argument 3 of 'rc_init' differ in signedness [-Wpointer-sign] 582 | rc_init(&rc, fill, inbuf, in_len); | ^~~~~ | | | unsigned char * ../arch/powerpc/boot/../../../lib/decompress_unlzma.c:107:18: note: expected 'char *' but argument is of type 'unsigned char *' 107 | char *buffer, long buffer_size) | ~~~~~~^~~~~~ and for CONFIG_KERNEL_LZO=y, this one warning: BOOTCC arch/powerpc/boot/decompress.o In file included from ../arch/powerpc/boot/decompress.c:43: ../arch/powerpc/boot/../../../lib/decompress_unlzo.c: In function 'parse_header': ../arch/powerpc/boot/../../../lib/decompress_unlzo.c:51:5: warning: variable 'level' set but not used [-Wunused-but-set-variable] 51 | u8 level = 0; | ^~~~~ Note: the patch above did not apply cleanly for me so any problems above could be due to my mangling the patch. The patch that I used is below. Thanks. --- --- lib/decompress_unlzo.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) --- linux-next-20210421.orig/lib/decompress_unlzo.c +++ linux-next-20210421/lib/decompress_unlzo.c @@ -23,13 +23,16 @@ #include #endif -#include #ifdef __KERNEL__ #include -#include #endif +#include +#ifdef __KERNEL__ +#include #include +#endif + #include static const unsigned char lzop_magic[] = {