From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (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 13E54215182; Mon, 9 Dec 2024 12:04:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.163.158.5 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733745856; cv=none; b=AU72ZKJ/om9ZOaE848/pAMDwziStsTIXoXiEu1pBPaO8OQPj5RZ0U0oC8l9kM2eyhkIoBICj5PuhonCHHWHCT8pkR/AuQ71qMEibAEO9AIg2wlbqdrpIx9+KE14LCx5Hy2+SO3gNV8PyOMu53ZQCTBWPE6eZJGkBzdIKtTski3Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733745856; c=relaxed/simple; bh=YhKb8NztGStJO1d7wV5dNFtNiTgrQFruuBmZZdZJe9Q=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=l28cemYA9GN9pwQJX60ppmi+A0PW+M/4dssLI6A5Wx4tNFNtwElAuskjMuc8a+QB1fC+enG7vHc6r0YjldpFB8P2RO9z09o/skBAyxbsp8pxI5CS1XXNnjdpsVG73gCA9O+Atio9K8vNLsoyRMNoA85Y2pE3obAKSACcRjpzKzM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com; spf=pass smtp.mailfrom=linux.ibm.com; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b=X1DWqvOf; arc=none smtp.client-ip=148.163.158.5 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="X1DWqvOf" Received: from pps.filterd (m0356516.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 4B96lUVo001478; Mon, 9 Dec 2024 12:00:05 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc :content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=pp1; bh=VzoQrl KifGO/+daTs9Y4n2DDkNruouGpa4uTqTdzTNQ=; b=X1DWqvOfPDi5KEyDVB1K5n T8O7pd4B5gqnlkz+UsZbWN3aBuJcObB1i3uF8xI9gwgSVwOFL5Ot0iR+owDVVTWF ZoO53dPyOe3dtPDBEJEvBoCWO35oalMa15+OC+dVTqDgfaQjoZR2Gi8Lw1Pumehy 8h7Zm/lBmUip7iT+dYf1WeIqAoK160g7T4pj2r3nf1KVMTbSH0+5751QYpfbCpO+ vhFRgw/C5Y5yZXl3dpfkdzllqnPQYDv/qqxu4isXOycDEcw6KxVjLg4bnXyytddv 5+NlHQwL1/kjFKaBIHMtsUlmHSGkxBdAZajn5l2gk2W9s/KT7LrNTWBecmqXJrgw == Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 43cbsq0gsu-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 09 Dec 2024 12:00:04 +0000 (GMT) Received: from m0356516.ppops.net (m0356516.ppops.net [127.0.0.1]) by pps.reinject (8.18.0.8/8.18.0.8) with ESMTP id 4B9BgTJx024304; Mon, 9 Dec 2024 12:00:04 GMT Received: from ppma22.wdc07v.mail.ibm.com (5c.69.3da9.ip4.static.sl-reverse.com [169.61.105.92]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 43cbsq0gsp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 09 Dec 2024 12:00:04 +0000 (GMT) Received: from pps.filterd (ppma22.wdc07v.mail.ibm.com [127.0.0.1]) by ppma22.wdc07v.mail.ibm.com (8.18.1.2/8.18.1.2) with ESMTP id 4B99osS7016919; Mon, 9 Dec 2024 12:00:03 GMT Received: from smtprelay06.dal12v.mail.ibm.com ([172.16.1.8]) by ppma22.wdc07v.mail.ibm.com (PPS) with ESMTPS id 43d12xxmbw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 09 Dec 2024 12:00:03 +0000 Received: from smtpav02.wdc07v.mail.ibm.com (smtpav02.wdc07v.mail.ibm.com [10.39.53.229]) by smtprelay06.dal12v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 4B9C02pU30802654 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 9 Dec 2024 12:00:02 GMT Received: from smtpav02.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5E6EA58071; Mon, 9 Dec 2024 12:00:02 +0000 (GMT) Received: from smtpav02.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9F4D25805D; Mon, 9 Dec 2024 12:00:00 +0000 (GMT) Received: from [9.152.212.155] (unknown [9.152.212.155]) by smtpav02.wdc07v.mail.ibm.com (Postfix) with ESMTP; Mon, 9 Dec 2024 12:00:00 +0000 (GMT) Message-ID: Subject: Re: [PATCH] net: ethernet: 8390: Add HAS_IOPORT dependency for mcf8390 From: Niklas Schnelle To: Arnd Bergmann , Andrew Lunn , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Greg Ungerer Cc: Netdev , linux-kernel@vger.kernel.org, kernel test robot Date: Mon, 09 Dec 2024 12:59:59 +0100 In-Reply-To: <3ca55478-a5a9-442b-ae4f-a0a822f786d9@app.fastmail.com> References: <20241209-mcf8390_has_ioport-v1-1-f263d573e243@linux.ibm.com> <3ca55478-a5a9-442b-ae4f-a0a822f786d9@app.fastmail.com> Autocrypt: addr=schnelle@linux.ibm.com; prefer-encrypt=mutual; keydata=mQINBGHm3M8BEAC+MIQkfoPIAKdjjk84OSQ8erd2OICj98+GdhMQpIjHXn/RJdCZLa58k /ay5x0xIHkWzx1JJOm4Lki7WEzRbYDexQEJP0xUia0U+4Yg7PJL4Dg/W4Ho28dRBROoJjgJSLSHwc 3/1pjpNlSaX/qg3ZM8+/EiSGc7uEPklLYu3gRGxcWV/944HdUyLcnjrZwCn2+gg9ncVJjsimS0ro/ 2wU2RPE4ju6NMBn5Go26sAj1owdYQQv9t0d71CmZS9Bh+2+cLjC7HvyTHKFxVGOznUL+j1a45VrVS XQ+nhTVjvgvXR84z10bOvLiwxJZ/00pwNi7uCdSYnZFLQ4S/JGMs4lhOiCGJhJ/9FR7JVw/1t1G9a UlqVp23AXwzbcoV2fxyE/CsVpHcyOWGDahGLcH7QeitN6cjltf9ymw2spBzpRnfFn80nVxgSYVG1d w75ksBAuQ/3e+oTQk4GAa2ShoNVsvR9GYn7rnsDN5pVILDhdPO3J2PGIXa5ipQnvwb3EHvPXyzakY tK50fBUPKk3XnkRwRYEbbPEB7YT+ccF/HioCryqDPWUivXF8qf6Jw5T1mhwukUV1i+QyJzJxGPh19 /N2/GK7/yS5wrt0Lwxzevc5g+jX8RyjzywOZGHTVu9KIQiG8Pqx33UxZvykjaqTMjo7kaAdGEkrHZ dVHqoPZwhCsgQARAQABtChOaWtsYXMgU2NobmVsbGUgPHNjaG5lbGxlQGxpbnV4LmlibS5jb20+iQ JXBBMBCABBAhsBBQsJCAcCBhUKCQgLAgQWAgMBAh4BAheAAhkBFiEEnbAAstJ1IDCl9y3cr+Q/Fej CYJAFAmWVooIFCQWP+TMACgkQr+Q/FejCYJCmLg/+OgZD6wTjooE77/ZHmW6Egb5nUH6DU+2nMHMH UupkE3dKuLcuzI4aEf/6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R+66Im0= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.54.2 (3.54.2-1.fc41) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: qzuFTvx1pC2sVVwFmJxpHJ90AozDNHy1 X-Proofpoint-GUID: TIP9S2c7WPMOCNdreaVxcxt4QyxllkCi X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1051,Hydra:6.0.680,FMLib:17.12.62.30 definitions=2024-10-15_01,2024-10-11_01,2024-09-30_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=308 adultscore=0 lowpriorityscore=0 clxscore=1011 phishscore=0 impostorscore=0 suspectscore=0 spamscore=0 mlxscore=0 priorityscore=1501 malwarescore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2411120000 definitions=main-2412090094 On Mon, 2024-12-09 at 12:49 +0100, Arnd Bergmann wrote: > On Mon, Dec 9, 2024, at 11:28, Niklas Schnelle wrote: > > Since commit 6f043e757445 ("asm-generic/io.h: Remove I/O port accessors > > for HAS_IOPORT=3Dn") the I/O port accessors are compile-time optional. = As > > m68k may or may not select HAS_IOPORT the COLDFIRE dependency is not > > enough to guarantee I/O port access. Add an explicit HAS_IOPORT > > dependency for mcf8390 to prevent a build failure as seen by the kernel > > test robot. > >=20 > > Reported-by: kernel test robot > > Closes:=20 > > https://lore.kernel.org/oe-kbuild-all/202412080511.ORVinTDs-lkp@intel.c= om/ > > Signed-off-by: Niklas Schnelle > > --- >=20 > Hi Niklas, >=20 > I think your patch is correct in the sense that the I/O port > handling on m68k coldfire is only defined for the PCI bus > the port operations is this driver have nowhere to go when > PCI is disabled. >=20 > However, I suspect what you actually found is a different > preexisting bug, likely introduced in the addition of PCI > support in commits 927c28c252dc ("m68k: setup PCI support > code in io_no.h") and d97cf70af097 ("m68k: use asm-generic/io.h > for non-MMU io access functions"). >=20 > As far as I can tell, the driver predates this patch and > presumably relied on inb/outb getting redirected to readb/writeb, > using the port number as a pointer (without the=20 > ((void __iomem *) PCI_IO_PA) offset). >=20 > Note that the dev->base_addr that gets passed into inb()/outb() > is a physical address from a IORESOURCE_MEM resource, > which is normally different from both 16-bit I/O port numbers > and from virtual __iomem pointers, though on coldfire nommu > the three traditionally could be used interchangeably. >=20 > Adding Greg Ungerer to Cc, as he maintains the coldfire > platform and wrote the driver. Thanks for taking a closer look. Note that I was a bit hasty in sending this and forgot the "PATCH net" suffix so resent[0] with that just before your reply and discussing it here might not be seen by all the netdev folks. I did get a checkpatch warning that this driver is depreated too. But hey, seems like our HAS_IOPORT patches have a talent for uncovering old bugs. [0] https://lore.kernel.org/netdev/3ca55478-a5a9-442b-ae4f-a0a822f786d9@app.fas= tmail.com/T/#t >=20 > > drivers/net/ethernet/8390/Kconfig | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > >=20 > > diff --git a/drivers/net/ethernet/8390/Kconfig=20 > > b/drivers/net/ethernet/8390/Kconfig > > index=20 > > 345f250781c6d9c3c6cbe5445250dc5987803b1a..f2ee99532187d133fdb02bc4b82c7= fc4861f90af=20 > > 100644 > > --- a/drivers/net/ethernet/8390/Kconfig > > +++ b/drivers/net/ethernet/8390/Kconfig > > @@ -87,7 +87,7 @@ config MAC8390 > >=20 > > config MCF8390 > > tristate "ColdFire NS8390 based Ethernet support" > > - depends on COLDFIRE > > + depends on COLDFIRE && HAS_IOPORT > > select CRC32 > > help > > This driver is for Ethernet devices using an NS8390-compatible > >=20 > > --- ---8<---