Message ID | 20230620131356.25440-11-bhe@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp3662238vqr; Tue, 20 Jun 2023 06:24:07 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7fQ4owt3FXQUi2qiqnygPkeM33roIR9Hz8Ov23evR91qCca0RLbfgldbHpgeBPexVJbRxS X-Received: by 2002:a17:90b:1188:b0:24e:59d2:6f with SMTP id gk8-20020a17090b118800b0024e59d2006fmr2928277pjb.11.1687267447197; Tue, 20 Jun 2023 06:24:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687267447; cv=none; d=google.com; s=arc-20160816; b=AIu4NfhL5GNlQCFkvP9AfPB6GVYPvIrxnmW7aLPqXw8peM6TFDStNCaZU3Ka3CJPvH xcfR9rcP4yJuT85krdY/bh4S0gRgp22ZLBCBtgQmgIZwmPGhbyS40G5NDbGo8Z+rJRGH XqEuuys/pFnlLClWR4ndunnAJRPF+y8JUg7xZudAk/ksuknvakJRl4azbAbrlRXOLWG9 yvwxFyqrp3Bw1gyVVs5clThPd72TknfOCR2S5MAW/vh4318DrUvQx3gItGQrVF7nsk8R 5KE6WmNPrWDOaY/i5Lj9UzWwqNe35Y36WgVLirTYGk2ix8rR8BG2AnGao11bEoVIVHto B2SA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=6JfLBgWKCdyh6wjUYOWVMGPpT4CuCPxtIaQnHkOENe8=; b=C7fRyL3X4AJChkA1R9CW7s++NW7Wx5qCGUF26x6smncqzn2ePbRKbiugedon8onoPq iz7pKhYO33PEzD0CRxIPtAmSr6w//lZWj6ModK3FujPVNeevoUzvu2Uu+xfLkRQzEo0c Jn0BqxcfXU1pa9cBbUSlTD4/igL3P7hlqhH71KGQOMaf6BKY6tr1IgQiPwqWh3pS+k0h Kgyb2n2P7MxHK8odQQH3utHsNtxxvwCFNQ4OX1L2fCw2cBZf+AhaxK6GblRD5WX/OQBP eOso9G1fqg70AnlvlB6P3tpx0TJ94OBOzn1f+K8xvejmS5dSCc86A3ADvCZTs5H7/5ZE /v6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=WXWbAlvU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t11-20020a17090a3b4b00b0025e7ff46234si9299838pjf.57.2023.06.20.06.23.51; Tue, 20 Jun 2023 06:24:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=WXWbAlvU; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232442AbjFTNSQ (ORCPT <rfc822;maxin.john@gmail.com> + 99 others); Tue, 20 Jun 2023 09:18:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49372 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231727AbjFTNSC (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 20 Jun 2023 09:18:02 -0400 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 DA5DC1BE7 for <linux-kernel@vger.kernel.org>; Tue, 20 Jun 2023 06:16:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1687266997; 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: in-reply-to:in-reply-to:references:references; bh=6JfLBgWKCdyh6wjUYOWVMGPpT4CuCPxtIaQnHkOENe8=; b=WXWbAlvUC8xO4mAm4hN5Kngbt9JVBqqJcWvAs0dhTg8yWzX5kQfGaqfDIqY3RTgxMrKncw cNkU6hH8bPw6n4jq3pHI84MEjIXX/eX9Tgsjo8TOY8bC7TS5u8Hl/fsCX8tvsB+CVt3jxl 6ZkW5fHC2fkEPEVJoQaa3Tf97rFdOMw= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-597-ext3m0EJMzyEfwIVkycz7Q-1; Tue, 20 Jun 2023 09:16:35 -0400 X-MC-Unique: ext3m0EJMzyEfwIVkycz7Q-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 8E29F185A7A8; Tue, 20 Jun 2023 13:15:44 +0000 (UTC) Received: from MiWiFi-R3L-srv.redhat.com (ovpn-12-166.pek2.redhat.com [10.72.12.166]) by smtp.corp.redhat.com (Postfix) with ESMTP id 690B2C1ED96; Tue, 20 Jun 2023 13:15:34 +0000 (UTC) From: Baoquan He <bhe@redhat.com> To: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org, linux-mm@kvack.org, arnd@arndb.de, hch@lst.de, christophe.leroy@csgroup.eu, rppt@kernel.org, willy@infradead.org, agordeev@linux.ibm.com, wangkefeng.wang@huawei.com, schnelle@linux.ibm.com, David.Laight@ACULAB.COM, shorne@gmail.com, deller@gmx.de, nathan@kernel.org, glaubitz@physik.fu-berlin.de, Baoquan He <bhe@redhat.com>, Gerald Schaefer <gerald.schaefer@linux.ibm.com>, Heiko Carstens <hca@linux.ibm.com>, Vasily Gorbik <gor@linux.ibm.com>, Christian Borntraeger <borntraeger@linux.ibm.com>, Sven Schnelle <svens@linux.ibm.com>, linux-s390@vger.kernel.org Subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP Date: Tue, 20 Jun 2023 21:13:47 +0800 Message-Id: <20230620131356.25440-11-bhe@redhat.com> In-Reply-To: <20230620131356.25440-1-bhe@redhat.com> References: <20230620131356.25440-1-bhe@redhat.com> MIME-Version: 1.0 Content-type: text/plain Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_NONE,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 lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1769228150312239180?= X-GMAIL-MSGID: =?utf-8?q?1769228150312239180?= |
Series |
mm: ioremap: Convert architectures to take GENERIC_IOREMAP way
|
|
Commit Message
Baoquan He
June 20, 2023, 1:13 p.m. UTC
By taking GENERIC_IOREMAP method, the generic generic_ioremap_prot(), generic_iounmap(), and their generic wrapper ioremap_prot(), ioremap() and iounmap() are all visible and available to arch. Arch needs to provide wrapper functions to override the generic versions if there's arch specific handling in its ioremap_prot(), ioremap() or iounmap(). This change will simplify implementation by removing duplicated codes with generic_ioremap_prot() and generic_iounmap(), and has the equivalent functioality as before. Here, add wrapper functions ioremap_prot() and iounmap() for s390's special operation when ioremap() and iounmap(). And also replace including <asm-generic/io.h> with <asm/io.h> in arch/s390/kernel/perf_cpum_sf.c, otherwise building error will be seen because macro defined in <asm/io.h> can't be seen in perf_cpum_sf.c. Signed-off-by: Baoquan He <bhe@redhat.com> Reviewed-by: Niklas Schnelle <schnelle@linux.ibm.com> Tested-by: Niklas Schnelle <schnelle@linux.ibm.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Mike Rapoport (IBM) <rppt@kernel.org> Cc: Gerald Schaefer <gerald.schaefer@linux.ibm.com> Cc: Heiko Carstens <hca@linux.ibm.com> Cc: Vasily Gorbik <gor@linux.ibm.com> Cc: Alexander Gordeev <agordeev@linux.ibm.com> Cc: Christian Borntraeger <borntraeger@linux.ibm.com> Cc: Sven Schnelle <svens@linux.ibm.com> Cc: linux-s390@vger.kernel.org --- v6->v7: - Fix building error reported by lkp test robot. https://lore.kernel.org/oe-kbuild-all/202306100105.8GHnoMCP-lkp@intel.com/ arch/s390/Kconfig | 1 + arch/s390/include/asm/io.h | 21 ++++++------ arch/s390/kernel/perf_cpum_sf.c | 2 +- arch/s390/pci/pci.c | 57 ++++++--------------------------- 4 files changed, 24 insertions(+), 57 deletions(-)
Comments
Hi Baoquan, kernel test robot noticed the following build errors: [auto build test ERROR on akpm-mm/mm-everything] url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) compiler: s390-linux-gcc (GCC) 12.3.0 reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202306211329.ticOJCSv-lkp@intel.com/ All error/warnings (new ones prefixed by >>): drivers/tty/ipwireless/main.c: In function 'ipwireless_probe': drivers/tty/ipwireless/main.c:115:30: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, | ^~~~~~~ | iounmap >> drivers/tty/ipwireless/main.c:115:28: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, | ^ drivers/tty/ipwireless/main.c:139:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 139 | ipw->attr_memory = ioremap(p_dev->resource[3]->start, | ^ In file included from include/linux/io.h:13, from drivers/tty/ipwireless/main.c:26: arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] 29 | #define iounmap iounmap | ^~~~~~~ drivers/tty/ipwireless/main.c:155:9: note: in expansion of macro 'iounmap' 155 | iounmap(ipw->attr_memory); | ^~~~~~~ cc1: some warnings being treated as errors -- drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'mhz_mfc_config': >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:17: error: implicit declaration of function 'ioremap'; did you mean 'ifr_map'? [-Werror=implicit-function-declaration] 447 | smc->base = ioremap(link->resource[2]->start, | ^~~~~~~ | ifr_map >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:15: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 447 | smc->base = ioremap(link->resource[2]->start, | ^ In file included from include/linux/scatterlist.h:9, from include/linux/dma-mapping.h:11, from include/linux/skbuff.h:28, from include/net/net_namespace.h:43, from include/linux/netdevice.h:38, from drivers/net/ethernet/smsc/smc91c92_cs.c:38: drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'smc91c92_release': arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] 29 | #define iounmap iounmap | ^~~~~~~ drivers/net/ethernet/smsc/smc91c92_cs.c:962:17: note: in expansion of macro 'iounmap' 962 | iounmap(smc->base); | ^~~~~~~ cc1: some warnings being treated as errors -- drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_config': drivers/net/ethernet/xircom/xirc2ps_cs.c:843:28: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; | ^~~~~~~ | iounmap >> drivers/net/ethernet/xircom/xirc2ps_cs.c:843:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; | ^ In file included from include/linux/scatterlist.h:9, from include/linux/dma-mapping.h:11, from include/linux/skbuff.h:28, from include/linux/if_ether.h:19, from include/linux/ethtool.h:18, from drivers/net/ethernet/xircom/xirc2ps_cs.c:77: drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_release': arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] 29 | #define iounmap iounmap | ^~~~~~~ drivers/net/ethernet/xircom/xirc2ps_cs.c:934:25: note: in expansion of macro 'iounmap' 934 | iounmap(local->dingo_ccr - 0x0800); | ^~~~~~~ cc1: some warnings being treated as errors vim +447 drivers/net/ethernet/smsc/smc91c92_cs.c b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 422 fba395eee7d3f3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2006-03-31 423 static int mhz_mfc_config(struct pcmcia_device *link) ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 424 { ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 425 struct net_device *dev = link->priv; ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 426 struct smc_private *smc = netdev_priv(dev); b5cb259e7fac55 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 427 unsigned int offset; b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 428 int i; ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 429 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 430 link->config_flags |= CONF_ENABLE_SPKR | CONF_ENABLE_IRQ | 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 431 CONF_AUTO_SET_IO; ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 432 ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 433 /* The Megahertz combo cards have modem-like CIS entries, so ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 434 we have to explicitly try a bunch of port combinations. */ b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 435 if (pcmcia_loop_config(link, mhz_mfc_config_check, NULL)) dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 436 return -ENODEV; dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 437 9a017a910346af drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 438 dev->base_addr = link->resource[0]->start; ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 439 ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 440 /* Allocate a memory window, for accessing the ISR */ cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 441 link->resource[2]->flags = WIN_DATA_WIDTH_8|WIN_MEMORY_TYPE_AM|WIN_ENABLE; cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 442 link->resource[2]->start = link->resource[2]->end = 0; cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 443 i = pcmcia_request_window(link, link->resource[2], 0); 4c89e88bfde6a3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-03 444 if (i != 0) dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 445 return -ENODEV; dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 446 cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 @447 smc->base = ioremap(link->resource[2]->start, cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 448 resource_size(link->resource[2])); 7feabb6412ea23 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-29 449 offset = (smc->manfid == MANFID_MOTOROLA) ? link->config_base : 0; cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 450 i = pcmcia_map_mem_page(link, link->resource[2], offset); 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 451 if ((i == 0) && 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 452 (smc->manfid == MANFID_MEGAHERTZ) && 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 453 (smc->cardid == PRODID_MEGAHERTZ_EM3288)) ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 454 mhz_3288_power(link); ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 455 dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 456 return 0; ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 457 } ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 458
Hi, On 06/21/23 at 01:43pm, kernel test robot wrote: > Hi Baoquan, > > kernel test robot noticed the following build errors: > > [auto build test ERROR on akpm-mm/mm-everything] > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) > compiler: s390-linux-gcc (GCC) 12.3.0 > reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) Thanks for reporting this. I followed steps in above reproduce link, it failed as below. Please help check if anything is missing. [root@intel-knightslanding-lb-02 linux]# COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.3.0 ~/bin/make.cross W=1 O=build_dir ARCH=s390 olddefconfig Compiler will be installed in /root/0day lftpget -c https://download.01.org/0day-ci/cross-package/./gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz /root/linux tar Jxf /root/0day/gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz -C /root/0day Please update: libc6 or glibc ldd /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc: /lib64/libc.so.6: version `GLIBC_2.36' not found (required by /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc) setup_crosstool failed > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > the same patch/commit), kindly add following tags > | Reported-by: kernel test robot <lkp@intel.com> > | Closes: https://lore.kernel.org/oe-kbuild-all/202306211329.ticOJCSv-lkp@intel.com/ > > All error/warnings (new ones prefixed by >>): > > drivers/tty/ipwireless/main.c: In function 'ipwireless_probe': > drivers/tty/ipwireless/main.c:115:30: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] > 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, > | ^~~~~~~ > | iounmap > >> drivers/tty/ipwireless/main.c:115:28: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, > | ^ > drivers/tty/ipwireless/main.c:139:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 139 | ipw->attr_memory = ioremap(p_dev->resource[3]->start, > | ^ > In file included from include/linux/io.h:13, > from drivers/tty/ipwireless/main.c:26: > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > 29 | #define iounmap iounmap > | ^~~~~~~ > drivers/tty/ipwireless/main.c:155:9: note: in expansion of macro 'iounmap' > 155 | iounmap(ipw->attr_memory); > | ^~~~~~~ > cc1: some warnings being treated as errors > -- > drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'mhz_mfc_config': > >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:17: error: implicit declaration of function 'ioremap'; did you mean 'ifr_map'? [-Werror=implicit-function-declaration] > 447 | smc->base = ioremap(link->resource[2]->start, > | ^~~~~~~ > | ifr_map > >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:15: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 447 | smc->base = ioremap(link->resource[2]->start, > | ^ > In file included from include/linux/scatterlist.h:9, > from include/linux/dma-mapping.h:11, > from include/linux/skbuff.h:28, > from include/net/net_namespace.h:43, > from include/linux/netdevice.h:38, > from drivers/net/ethernet/smsc/smc91c92_cs.c:38: > drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'smc91c92_release': > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > 29 | #define iounmap iounmap > | ^~~~~~~ > drivers/net/ethernet/smsc/smc91c92_cs.c:962:17: note: in expansion of macro 'iounmap' > 962 | iounmap(smc->base); > | ^~~~~~~ > cc1: some warnings being treated as errors > -- > drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_config': > drivers/net/ethernet/xircom/xirc2ps_cs.c:843:28: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] > 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; > | ^~~~~~~ > | iounmap > >> drivers/net/ethernet/xircom/xirc2ps_cs.c:843:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; > | ^ > In file included from include/linux/scatterlist.h:9, > from include/linux/dma-mapping.h:11, > from include/linux/skbuff.h:28, > from include/linux/if_ether.h:19, > from include/linux/ethtool.h:18, > from drivers/net/ethernet/xircom/xirc2ps_cs.c:77: > drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_release': > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > 29 | #define iounmap iounmap > | ^~~~~~~ > drivers/net/ethernet/xircom/xirc2ps_cs.c:934:25: note: in expansion of macro 'iounmap' > 934 | iounmap(local->dingo_ccr - 0x0800); > | ^~~~~~~ > cc1: some warnings being treated as errors > > > vim +447 drivers/net/ethernet/smsc/smc91c92_cs.c > > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 422 > fba395eee7d3f3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2006-03-31 423 static int mhz_mfc_config(struct pcmcia_device *link) > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 424 { > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 425 struct net_device *dev = link->priv; > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 426 struct smc_private *smc = netdev_priv(dev); > b5cb259e7fac55 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 427 unsigned int offset; > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 428 int i; > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 429 > 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 430 link->config_flags |= CONF_ENABLE_SPKR | CONF_ENABLE_IRQ | > 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 431 CONF_AUTO_SET_IO; > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 432 > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 433 /* The Megahertz combo cards have modem-like CIS entries, so > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 434 we have to explicitly try a bunch of port combinations. */ > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 435 if (pcmcia_loop_config(link, mhz_mfc_config_check, NULL)) > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 436 return -ENODEV; > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 437 > 9a017a910346af drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 438 dev->base_addr = link->resource[0]->start; > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 439 > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 440 /* Allocate a memory window, for accessing the ISR */ > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 441 link->resource[2]->flags = WIN_DATA_WIDTH_8|WIN_MEMORY_TYPE_AM|WIN_ENABLE; > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 442 link->resource[2]->start = link->resource[2]->end = 0; > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 443 i = pcmcia_request_window(link, link->resource[2], 0); > 4c89e88bfde6a3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-03 444 if (i != 0) > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 445 return -ENODEV; > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 446 > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 @447 smc->base = ioremap(link->resource[2]->start, > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 448 resource_size(link->resource[2])); > 7feabb6412ea23 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-29 449 offset = (smc->manfid == MANFID_MOTOROLA) ? link->config_base : 0; > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 450 i = pcmcia_map_mem_page(link, link->resource[2], offset); > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 451 if ((i == 0) && > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 452 (smc->manfid == MANFID_MEGAHERTZ) && > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 453 (smc->cardid == PRODID_MEGAHERTZ_EM3288)) > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 454 mhz_3288_power(link); > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 455 > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 456 return 0; > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 457 } > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 458 > > -- > 0-DAY CI Kernel Test Service > https://github.com/intel/lkp-tests/wiki >
On Wed, Jun 21, 2023 at 06:41:09PM +0800, Baoquan He wrote: Hi Baoquan, > > [auto build test ERROR on akpm-mm/mm-everything] > > > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) > > compiler: s390-linux-gcc (GCC) 12.3.0 > > reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) > > Thanks for reporting this. > > I followed steps in above reproduce link, it failed as below. Please > help check if anything is missing. Could it be because you locally have the fix you posted aganst v6? Thansk!
On 06/21/23 at 12:46pm, Alexander Gordeev wrote: > On Wed, Jun 21, 2023 at 06:41:09PM +0800, Baoquan He wrote: > > Hi Baoquan, > > > > [auto build test ERROR on akpm-mm/mm-everything] > > > > > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > > > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > > > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > > > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > > > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) > > > compiler: s390-linux-gcc (GCC) 12.3.0 > > > reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) > > > > Thanks for reporting this. > > > > I followed steps in above reproduce link, it failed as below. Please > > help check if anything is missing. > > Could it be because you locally have the fix you posted aganst v6? I am not sure. I failed to setup the cross compiling environment accoridng to steps of lkp. I borrowed a s390x machine, will build with the config of lkp test robot to see if I can reproduce it.
On Wed, Jun 21, 2023 at 06:41:09PM +0800, Baoquan He wrote: > Hi, > > On 06/21/23 at 01:43pm, kernel test robot wrote: > > Hi Baoquan, > > > > kernel test robot noticed the following build errors: > > > > [auto build test ERROR on akpm-mm/mm-everything] > > > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) > > compiler: s390-linux-gcc (GCC) 12.3.0 > > reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) > > Thanks for reporting this. > > I followed steps in above reproduce link, it failed as below. Please > help check if anything is missing. > > [root@intel-knightslanding-lb-02 linux]# COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.3.0 ~/bin/make.cross W=1 O=build_dir ARCH=s390 olddefconfig > Compiler will be installed in /root/0day > lftpget -c https://download.01.org/0day-ci/cross-package/./gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz > /root/linux > tar Jxf /root/0day/gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz -C /root/0day > Please update: libc6 or glibc > ldd /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc > /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc: /lib64/libc.so.6: version `GLIBC_2.36' not found (required by /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc) > setup_crosstool failed Certain recent versions of the kernel.org crosstool toolchains were built against a pretty recent glibc so attempting to run it on a system with an older glibc will result in the error above: https://lore.kernel.org/87mt2eoopo.fsf@kernel.org/ Arnd resolved this and reuploaded the binaries, I suspect the Intel folks need to mirror the updated tarballs to 01.org: https://lore.kernel.org/e9601db2-ff7d-4490-abd5-8d3c5946e108@app.fastmail.com/ According to make.cross, you can override the URL it uses with a variable, you could try removing these files /root/0day/gcc-12.3.0-nolibc/s390-linux /root/0day/gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz and running $ COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.3.0 URL=https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64 ~/bin/make.cross W=1 O=build_dir ARCH=s390 olddefconfig to see if that works now. Cheers, Nathan > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > > the same patch/commit), kindly add following tags > > | Reported-by: kernel test robot <lkp@intel.com> > > | Closes: https://lore.kernel.org/oe-kbuild-all/202306211329.ticOJCSv-lkp@intel.com/ > > > > All error/warnings (new ones prefixed by >>): > > > > drivers/tty/ipwireless/main.c: In function 'ipwireless_probe': > > drivers/tty/ipwireless/main.c:115:30: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] > > 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, > > | ^~~~~~~ > > | iounmap > > >> drivers/tty/ipwireless/main.c:115:28: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > > 115 | ipw->common_memory = ioremap(p_dev->resource[2]->start, > > | ^ > > drivers/tty/ipwireless/main.c:139:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > > 139 | ipw->attr_memory = ioremap(p_dev->resource[3]->start, > > | ^ > > In file included from include/linux/io.h:13, > > from drivers/tty/ipwireless/main.c:26: > > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > > 29 | #define iounmap iounmap > > | ^~~~~~~ > > drivers/tty/ipwireless/main.c:155:9: note: in expansion of macro 'iounmap' > > 155 | iounmap(ipw->attr_memory); > > | ^~~~~~~ > > cc1: some warnings being treated as errors > > -- > > drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'mhz_mfc_config': > > >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:17: error: implicit declaration of function 'ioremap'; did you mean 'ifr_map'? [-Werror=implicit-function-declaration] > > 447 | smc->base = ioremap(link->resource[2]->start, > > | ^~~~~~~ > > | ifr_map > > >> drivers/net/ethernet/smsc/smc91c92_cs.c:447:15: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > > 447 | smc->base = ioremap(link->resource[2]->start, > > | ^ > > In file included from include/linux/scatterlist.h:9, > > from include/linux/dma-mapping.h:11, > > from include/linux/skbuff.h:28, > > from include/net/net_namespace.h:43, > > from include/linux/netdevice.h:38, > > from drivers/net/ethernet/smsc/smc91c92_cs.c:38: > > drivers/net/ethernet/smsc/smc91c92_cs.c: In function 'smc91c92_release': > > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > > 29 | #define iounmap iounmap > > | ^~~~~~~ > > drivers/net/ethernet/smsc/smc91c92_cs.c:962:17: note: in expansion of macro 'iounmap' > > 962 | iounmap(smc->base); > > | ^~~~~~~ > > cc1: some warnings being treated as errors > > -- > > drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_config': > > drivers/net/ethernet/xircom/xirc2ps_cs.c:843:28: error: implicit declaration of function 'ioremap'; did you mean 'iounmap'? [-Werror=implicit-function-declaration] > > 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; > > | ^~~~~~~ > > | iounmap > > >> drivers/net/ethernet/xircom/xirc2ps_cs.c:843:26: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > > 843 | local->dingo_ccr = ioremap(link->resource[2]->start, 0x1000) + 0x0800; > > | ^ > > In file included from include/linux/scatterlist.h:9, > > from include/linux/dma-mapping.h:11, > > from include/linux/skbuff.h:28, > > from include/linux/if_ether.h:19, > > from include/linux/ethtool.h:18, > > from drivers/net/ethernet/xircom/xirc2ps_cs.c:77: > > drivers/net/ethernet/xircom/xirc2ps_cs.c: In function 'xirc2ps_release': > > arch/s390/include/asm/io.h:29:17: error: implicit declaration of function 'iounmap'; did you mean 'vunmap'? [-Werror=implicit-function-declaration] > > 29 | #define iounmap iounmap > > | ^~~~~~~ > > drivers/net/ethernet/xircom/xirc2ps_cs.c:934:25: note: in expansion of macro 'iounmap' > > 934 | iounmap(local->dingo_ccr - 0x0800); > > | ^~~~~~~ > > cc1: some warnings being treated as errors > > > > > > vim +447 drivers/net/ethernet/smsc/smc91c92_cs.c > > > > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 422 > > fba395eee7d3f3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2006-03-31 423 static int mhz_mfc_config(struct pcmcia_device *link) > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 424 { > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 425 struct net_device *dev = link->priv; > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 426 struct smc_private *smc = netdev_priv(dev); > > b5cb259e7fac55 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 427 unsigned int offset; > > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 428 int i; > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 429 > > 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 430 link->config_flags |= CONF_ENABLE_SPKR | CONF_ENABLE_IRQ | > > 00990e7ce0b0e5 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-30 431 CONF_AUTO_SET_IO; > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 432 > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 433 /* The Megahertz combo cards have modem-like CIS entries, so > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 434 we have to explicitly try a bunch of port combinations. */ > > b54bf94bf91e4c drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-02 435 if (pcmcia_loop_config(link, mhz_mfc_config_check, NULL)) > > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 436 return -ENODEV; > > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 437 > > 9a017a910346af drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-24 438 dev->base_addr = link->resource[0]->start; > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 439 > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 440 /* Allocate a memory window, for accessing the ISR */ > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 441 link->resource[2]->flags = WIN_DATA_WIDTH_8|WIN_MEMORY_TYPE_AM|WIN_ENABLE; > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 442 link->resource[2]->start = link->resource[2]->end = 0; > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 443 i = pcmcia_request_window(link, link->resource[2], 0); > > 4c89e88bfde6a3 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2008-08-03 444 if (i != 0) > > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 445 return -ENODEV; > > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 446 > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 @447 smc->base = ioremap(link->resource[2]->start, > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 448 resource_size(link->resource[2])); > > 7feabb6412ea23 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-29 449 offset = (smc->manfid == MANFID_MOTOROLA) ? link->config_base : 0; > > cdb138080b7814 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2010-07-28 450 i = pcmcia_map_mem_page(link, link->resource[2], offset); > > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 451 if ((i == 0) && > > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 452 (smc->manfid == MANFID_MEGAHERTZ) && > > 8e95a2026f3b43 drivers/net/pcmcia/smc91c92_cs.c Joe Perches 2009-12-03 453 (smc->cardid == PRODID_MEGAHERTZ_EM3288)) > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 454 mhz_3288_power(link); > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 455 > > dddfbd824b96a2 drivers/net/pcmcia/smc91c92_cs.c Dominik Brodowski 2009-10-18 456 return 0; > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 457 } > > ^1da177e4c3f41 drivers/net/pcmcia/smc91c92_cs.c Linus Torvalds 2005-04-16 458 > > > > -- > > 0-DAY CI Kernel Test Service > > https://github.com/intel/lkp-tests/wiki > > >
On 06/21/23 at 07:21pm, Nathan Chancellor wrote: > On Wed, Jun 21, 2023 at 06:41:09PM +0800, Baoquan He wrote: > > Hi, > > > > On 06/21/23 at 01:43pm, kernel test robot wrote: > > > Hi Baoquan, > > > > > > kernel test robot noticed the following build errors: > > > > > > [auto build test ERROR on akpm-mm/mm-everything] > > > > > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > > > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > > > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > > > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > > > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) > > > compiler: s390-linux-gcc (GCC) 12.3.0 > > > reproduce: (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/reproduce) > > > > Thanks for reporting this. > > > > I followed steps in above reproduce link, it failed as below. Please > > help check if anything is missing. > > > > [root@intel-knightslanding-lb-02 linux]# COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.3.0 ~/bin/make.cross W=1 O=build_dir ARCH=s390 olddefconfig > > Compiler will be installed in /root/0day > > lftpget -c https://download.01.org/0day-ci/cross-package/./gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz > > /root/linux > > tar Jxf /root/0day/gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz -C /root/0day > > Please update: libc6 or glibc > > ldd /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc > > /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc: /lib64/libc.so.6: version `GLIBC_2.36' not found (required by /root/0day/gcc-12.3.0-nolibc/s390-linux/bin/s390-linux-gcc) > > setup_crosstool failed > > Certain recent versions of the kernel.org crosstool toolchains were > built against a pretty recent glibc so attempting to run it on a system > with an older glibc will result in the error above: > > https://lore.kernel.org/87mt2eoopo.fsf@kernel.org/ > > Arnd resolved this and reuploaded the binaries, I suspect the Intel > folks need to mirror the updated tarballs to 01.org: > > https://lore.kernel.org/e9601db2-ff7d-4490-abd5-8d3c5946e108@app.fastmail.com/ > > According to make.cross, you can override the URL it uses with a > variable, you could try removing these files > > /root/0day/gcc-12.3.0-nolibc/s390-linux > /root/0day/gcc-12.3.0-nolibc/x86_64-gcc-12.3.0-nolibc_s390-linux.tar.xz > > and running > > $ COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.3.0 URL=https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64 ~/bin/make.cross W=1 O=build_dir ARCH=s390 olddefconfig > > to see if that works now. Thanks a lot for your help, Nathan. Really appreciated. Above make olddefconfig command works well, however the building failed either becuase of lack of gmp.h. I am not familiar with the manipulation of lkp building, so I gave up after attempt. ====== I finally got a s390x kvm guest from redhat lab, fetched the config file lkp provided and build, I can reproduce those errors and more similar errors are catched. CONFIG_MMU=y # CONFIG_PCI is not set From investigation, I see the lkp config enabled MMU, but disabled PCI. So those drivers which call ioremap()/iounmap() or their devm_xxxx wrappers will fail building because s390's iomem operations rely on pci support enabling. So I just change to make these drivers depend on HAS_IOMEM so that it won't be built. The draft change is pasted at below. Hi Niklas, I remember you ever entioned you would work out patches to solve those those drivers relying on devm_xxx(), not sure if they are related to the compiling error I met here. If I said the right thing, do you have plan to post them? If what you ever said is different thing, or do you have suggestion for below change, should I post them like this or need some adjustment? Look forward to your comments, thanks in advance. diff --git a/drivers/char/xillybus/Kconfig b/drivers/char/xillybus/Kconfig index a8036dad437e..f51d533390a9 100644 --- a/drivers/char/xillybus/Kconfig +++ b/drivers/char/xillybus/Kconfig @@ -29,7 +29,7 @@ config XILLYBUS_PCIE config XILLYBUS_OF tristate "Xillybus over Device Tree" - depends on OF && HAS_DMA + depends on OF && HAS_DMA && HAS_IOMEM help Set to M if you want Xillybus to find its resources from the Open Firmware Flattened Device Tree. If the target is an embedded diff --git a/drivers/clk/Kconfig b/drivers/clk/Kconfig index 016814e15536..52dfbae4f361 100644 --- a/drivers/clk/Kconfig +++ b/drivers/clk/Kconfig @@ -444,6 +444,7 @@ config COMMON_CLK_BD718XX config COMMON_CLK_FIXED_MMIO bool "Clock driver for Memory Mapped Fixed values" depends on COMMON_CLK && OF + depends on HAS_IOMEM help Support for Memory Mapped IO Fixed clocks diff --git a/drivers/dma/Kconfig b/drivers/dma/Kconfig index f5f422f9b850..b6221b4432fd 100644 --- a/drivers/dma/Kconfig +++ b/drivers/dma/Kconfig @@ -211,6 +211,7 @@ config FSL_DMA config FSL_EDMA tristate "Freescale eDMA engine support" depends on OF + depends on HAS_IOMEM select DMA_ENGINE select DMA_VIRTUAL_CHANNELS help @@ -280,6 +281,7 @@ config IMX_SDMA config INTEL_IDMA64 tristate "Intel integrated DMA 64-bit support" + depends on HAS_IOMEM select DMA_ENGINE select DMA_VIRTUAL_CHANNELS help diff --git a/drivers/dma/qcom/Kconfig b/drivers/dma/qcom/Kconfig index 3f926a653bd8..ace75d7b835a 100644 --- a/drivers/dma/qcom/Kconfig +++ b/drivers/dma/qcom/Kconfig @@ -45,6 +45,7 @@ config QCOM_HIDMA_MGMT config QCOM_HIDMA tristate "Qualcomm Technologies HIDMA Channel support" + depends on HAS_IOMEM select DMA_ENGINE help Enable support for the Qualcomm Technologies HIDMA controller. diff --git a/drivers/irqchip/Kconfig b/drivers/irqchip/Kconfig index 09e422da482f..4b9036c6d45b 100644 --- a/drivers/irqchip/Kconfig +++ b/drivers/irqchip/Kconfig @@ -89,6 +89,7 @@ config ALPINE_MSI config AL_FIC bool "Amazon's Annapurna Labs Fabric Interrupt Controller" depends on OF + depends on HAS_IOMEM select GENERIC_IRQ_CHIP select IRQ_DOMAIN help diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig index 433aa4197785..1d2b176a0594 100644 --- a/drivers/misc/Kconfig +++ b/drivers/misc/Kconfig @@ -496,6 +496,7 @@ config HISI_HIKEY_USB config OPEN_DICE tristate "Open Profile for DICE driver" depends on OF_RESERVED_MEM + depends on HAS_IOMEM help This driver exposes a DICE reserved memory region to userspace via a character device. The memory region contains Compound Device diff --git a/drivers/net/ethernet/altera/Kconfig b/drivers/net/ethernet/altera/Kconfig index dd7fd41ccde5..33927fdfff28 100644 --- a/drivers/net/ethernet/altera/Kconfig +++ b/drivers/net/ethernet/altera/Kconfig @@ -2,6 +2,7 @@ config ALTERA_TSE tristate "Altera Triple-Speed Ethernet MAC support" depends on HAS_DMA + depends on HAS_IOMEM select PHYLIB select PHYLINK select PCS_ALTERA_TSE diff --git a/drivers/of/Kconfig b/drivers/of/Kconfig index e40f10bf2ba4..da9826accb1b 100644 --- a/drivers/of/Kconfig +++ b/drivers/of/Kconfig @@ -55,7 +55,7 @@ config OF_FLATTREE config OF_EARLY_FLATTREE bool - select DMA_DECLARE_COHERENT if HAS_DMA + select DMA_DECLARE_COHERENT if HAS_DMA && HAS_IOMEM select OF_FLATTREE config OF_PROMTREE
Hi, On 06/21/23 at 01:43pm, kernel test robot wrote: > Hi Baoquan, > > kernel test robot noticed the following build errors: > > [auto build test ERROR on akpm-mm/mm-everything] > > url: https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/asm-generic-iomap-h-remove-ARCH_HAS_IOREMAP_xx-macros/20230620-212135 > base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything > patch link: https://lore.kernel.org/r/20230620131356.25440-11-bhe%40redhat.com > patch subject: [PATCH v7 10/19] s390: mm: Convert to GENERIC_IOREMAP > config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20230621/202306211329.ticOJCSv-lkp@intel.com/config) I can confirm these reproted errors have nothing to do with my patch. I got a s390 system and build the latest kernel from linus's master branch with above config, all these failures have been existing there. I have made patches to fix them by adding dependency on HAS_IOMEM for drivers. I would suggest lkp adjusts script to test the base firstly so that a reliable base is provided to avoid confusion. Thanks Baoquan
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index 6dab9c1be508..e625bb0cc6c7 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig @@ -142,6 +142,7 @@ config S390 select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL select GENERIC_VDSO_TIME_NS + select GENERIC_IOREMAP if PCI select HAVE_ALIGNED_STRUCT_PAGE if SLUB select HAVE_ARCH_AUDITSYSCALL select HAVE_ARCH_JUMP_LABEL diff --git a/arch/s390/include/asm/io.h b/arch/s390/include/asm/io.h index e3882b012bfa..4453ad7c11ac 100644 --- a/arch/s390/include/asm/io.h +++ b/arch/s390/include/asm/io.h @@ -22,11 +22,18 @@ void unxlate_dev_mem_ptr(phys_addr_t phys, void *addr); #define IO_SPACE_LIMIT 0 -void __iomem *ioremap_prot(phys_addr_t addr, size_t size, unsigned long prot); -void __iomem *ioremap(phys_addr_t addr, size_t size); -void __iomem *ioremap_wc(phys_addr_t addr, size_t size); -void __iomem *ioremap_wt(phys_addr_t addr, size_t size); -void iounmap(volatile void __iomem *addr); +/* + * I/O memory mapping functions. + */ +#define ioremap_prot ioremap_prot +#define iounmap iounmap + +#define _PAGE_IOREMAP pgprot_val(PAGE_KERNEL) + +#define ioremap_wc(addr, size) \ + ioremap_prot((addr), (size), pgprot_val(pgprot_writecombine(PAGE_KERNEL))) +#define ioremap_wt(addr, size) \ + ioremap_prot((addr), (size), pgprot_val(pgprot_writethrough(PAGE_KERNEL))) static inline void __iomem *ioport_map(unsigned long port, unsigned int nr) { @@ -51,10 +58,6 @@ static inline void ioport_unmap(void __iomem *p) #define pci_iomap_wc pci_iomap_wc #define pci_iomap_wc_range pci_iomap_wc_range -#define ioremap ioremap -#define ioremap_wt ioremap_wt -#define ioremap_wc ioremap_wc - #define memcpy_fromio(dst, src, count) zpci_memcpy_fromio(dst, src, count) #define memcpy_toio(dst, src, count) zpci_memcpy_toio(dst, src, count) #define memset_io(dst, val, count) zpci_memset_io(dst, val, count) diff --git a/arch/s390/kernel/perf_cpum_sf.c b/arch/s390/kernel/perf_cpum_sf.c index 7ef72f5ff52e..b0269f3881aa 100644 --- a/arch/s390/kernel/perf_cpum_sf.c +++ b/arch/s390/kernel/perf_cpum_sf.c @@ -22,7 +22,7 @@ #include <asm/irq.h> #include <asm/debug.h> #include <asm/timex.h> -#include <asm-generic/io.h> +#include <asm/io.h> /* Minimum number of sample-data-block-tables: * At least one table is required for the sampling buffer structure. diff --git a/arch/s390/pci/pci.c b/arch/s390/pci/pci.c index afc3f33788da..d34d5813d006 100644 --- a/arch/s390/pci/pci.c +++ b/arch/s390/pci/pci.c @@ -244,62 +244,25 @@ void __iowrite64_copy(void __iomem *to, const void *from, size_t count) zpci_memcpy_toio(to, from, count); } -static void __iomem *__ioremap(phys_addr_t addr, size_t size, pgprot_t prot) +void __iomem *ioremap_prot(phys_addr_t phys_addr, size_t size, + unsigned long prot) { - unsigned long offset, vaddr; - struct vm_struct *area; - phys_addr_t last_addr; - - last_addr = addr + size - 1; - if (!size || last_addr < addr) - return NULL; - + /* + * When PCI MIO instructions are unavailable the "physical" address + * encodes a hint for accessing the PCI memory space it represents. + * Just pass it unchanged such that ioread/iowrite can decode it. + */ if (!static_branch_unlikely(&have_mio)) - return (void __iomem *) addr; + return (void __iomem *)phys_addr; - offset = addr & ~PAGE_MASK; - addr &= PAGE_MASK; - size = PAGE_ALIGN(size + offset); - area = get_vm_area(size, VM_IOREMAP); - if (!area) - return NULL; - - vaddr = (unsigned long) area->addr; - if (ioremap_page_range(vaddr, vaddr + size, addr, prot)) { - free_vm_area(area); - return NULL; - } - return (void __iomem *) ((unsigned long) area->addr + offset); -} - -void __iomem *ioremap_prot(phys_addr_t addr, size_t size, unsigned long prot) -{ - return __ioremap(addr, size, __pgprot(prot)); + return generic_ioremap_prot(phys_addr, size, __pgprot(prot)); } EXPORT_SYMBOL(ioremap_prot); -void __iomem *ioremap(phys_addr_t addr, size_t size) -{ - return __ioremap(addr, size, PAGE_KERNEL); -} -EXPORT_SYMBOL(ioremap); - -void __iomem *ioremap_wc(phys_addr_t addr, size_t size) -{ - return __ioremap(addr, size, pgprot_writecombine(PAGE_KERNEL)); -} -EXPORT_SYMBOL(ioremap_wc); - -void __iomem *ioremap_wt(phys_addr_t addr, size_t size) -{ - return __ioremap(addr, size, pgprot_writethrough(PAGE_KERNEL)); -} -EXPORT_SYMBOL(ioremap_wt); - void iounmap(volatile void __iomem *addr) { if (static_branch_likely(&have_mio)) - vunmap((__force void *) ((unsigned long) addr & PAGE_MASK)); + generic_iounmap(addr); } EXPORT_SYMBOL(iounmap);