Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp3195256rdb; Wed, 13 Sep 2023 05:16:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGT6GxhaA2SPWSNtgQWkIHCRDwBffFXJuDiPhsxMvcrkLzjm07QqJcrTXyCjoK49TT1w/Nv X-Received: by 2002:a17:90a:c293:b0:268:29a3:bd05 with SMTP id f19-20020a17090ac29300b0026829a3bd05mr1722642pjt.48.1694607406998; Wed, 13 Sep 2023 05:16:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694607406; cv=none; d=google.com; s=arc-20160816; b=fe0awzdTiHi7E1/hVpo4QZ8K54193LCHD8uT1Et/2tlEiruX7yC612UmLza1RmfFBl 3LcquUsCIgeGx5ro6S3VVySSfVFBbKk2TYPkot3dR43ZIGW5On37gBIoWP7rc3T7xuqY Td1xMCrhqqdHRcicKyH7nYz0eiRzQlaQGoiir7SCd0+tfc4pCVUnc3QzB7kEn/IkDS4F 7kj/M/1gjMM7ilZA9NC9nbq8l2QyxHQUMvf2vZsoKB9VB1T7g6R6GgsDYD3r4tpURQLK iKt7fXTnAIo0VW0rDOpPALLuoM7jCRF3mu480sXe0P4CkOjCtZt2k4EdHSr2Rew5zFiC c33g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:cc:to:from:date:references:in-reply-to :message-id:mime-version:user-agent:feedback-id:dkim-signature; bh=3zPKWMxi7CXd1WX3nlpaihktbEkVrTG6YivmUk1Ql7s=; fh=sI4r+OhhO078PrCj8rCarJIcZs6qUiM8dmBBtyz3CzU=; b=RkMHC5qcbXBzmVe5dAVlD2g7U4ji9T8uBDAqNx22jWG6oovfAAXkt6DvfMCjcVBOy7 IuA8RFaPL0LzGd4hUppkbbdU1CEkA0NvUKatYRRv1Dy6yEdsqHuzIYqktsYVHkWfMd93 +mIGR1cYw/Y8299Og7cnJl7VoE6PWLRITAX7T56AuR9bZJucYNDr6/zphqmizra8cleV zznq4WEfZSVAh8A+yeGn9BxfJ7gW9eDqwdix9pzWfAEMV2lyTvD+sbSM7bfKRmpvbVtQ InmJO2iEHkuPXVPPdNTKqTox1pzuf7X0coi2x3IGcQqSQgdNpybu3Yno72Wkag2vWlFx aFmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GBpdFEhn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id y4-20020a17090322c400b001bb42c27496si10579351plg.233.2023.09.13.05.16.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 05:16:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GBpdFEhn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 0A17581C7AA9; Wed, 13 Sep 2023 05:04:21 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240183AbjIMMEX (ORCPT + 99 others); Wed, 13 Sep 2023 08:04:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58508 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235205AbjIMMEW (ORCPT ); Wed, 13 Sep 2023 08:04:22 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DD1419A7 for ; Wed, 13 Sep 2023 05:04:18 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1098BC433C8; Wed, 13 Sep 2023 12:04:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1694606658; bh=UDg0s7wg1AHZ02vnovZRJjJnJM/odDz8x2qPN11Cjt0=; h=In-Reply-To:References:Date:From:To:Cc:Subject:From; b=GBpdFEhnj1S+t8m5Kdtk7+yAUbjGV282+HVn7GHEFcLewWYKIhUVlq6UEBd5R8Gd7 1Xc1/FA2QxqzIKzcyx7rCFtn7+v+CEUn38lJsDmDMcaDuwXkTf1cpKDZTafUF4RTY3 rIyaaYWcLTMNvBEuZd/2yiMr1qMJ/g83D1Q2jJ7yk0j/YZxUcJ/v/3XIW9SnnjHJaK cPT5FLryZM/KVLy2yCOGGGcKzR8TsRaLlSJDvFHwkbYnJHfyl9zcKzngxJUnM8Etn/ G+jZGqBoa/9VtKS0VmVrNOviwMQWK/sNRDkpJlnqY0PP1KxRLm8evvecG+K6cOMJ1g wTST/wBj5NswA== Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailauth.nyi.internal (Postfix) with ESMTP id EE06D27C005C; Wed, 13 Sep 2023 08:04:16 -0400 (EDT) Received: from imap51 ([10.202.2.101]) by compute6.internal (MEProxy); Wed, 13 Sep 2023 08:04:16 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudeikedggeejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvfevufgtsehttdertderredtnecuhfhrohhmpedftehr nhguuceuvghrghhmrghnnhdfuceorghrnhgusehkvghrnhgvlhdrohhrgheqnecuggftrf grthhtvghrnhepvdeviefgtedugeevieelvdfgveeuvdfgteegfeeiieejjeffgeeghedu gedtveehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomh eprghrnhguodhmvghsmhhtphgruhhthhhpvghrshhonhgrlhhithihqdduvdekhedujedt vdegqddvkeejtddtvdeigedqrghrnhgupeepkhgvrhhnvghlrdhorhhgsegrrhhnuggsrd guvg X-ME-Proxy: Feedback-ID: i36794607:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id 79DCEB60089; Wed, 13 Sep 2023 08:04:16 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.9.0-alpha0-745-g95dd7bea33-fm-20230905.001-g95dd7bea Mime-Version: 1.0 Message-Id: <51a9af18-a5e4-4cb1-9f95-491bf73d35f1@app.fastmail.com> In-Reply-To: <20230913112032.90618-6-abbotti@mev.co.uk> References: <20230913112032.90618-1-abbotti@mev.co.uk> <20230913112032.90618-6-abbotti@mev.co.uk> Date: Wed, 13 Sep 2023 14:03:55 +0200 From: "Arnd Bergmann" To: "Ian Abbott" , linux-kernel@vger.kernel.org Cc: "Niklas Schnelle" Subject: Re: [PATCH 05/13] comedi: 8255_pci: Conditionally remove devices that use port I/O Content-Type: text/plain 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 (snail.vger.email [0.0.0.0]); Wed, 13 Sep 2023 05:04:21 -0700 (PDT) On Wed, Sep 13, 2023, at 13:20, Ian Abbott wrote: > In a future patch, the port I/O functions (`inb()`, `outb()`, and > friends will only be declared in the `HAS_IOPORT` configuration option > is enabled. > > The 8255_pci module supports PCI digital I/O devices from various > manufacturers that consist of one or more 8255 Programmable Peripheral > Interface chips (or equivalent hardware) to provide their digital I/O > ports. Some of the devices use port I/O and some only use memory-mapped > I/O. > > Conditionally compile in support for the devices that need port I/O if > and only if the `CONFIG_HAS_PORTIO` macro is defined. Change > `pci_8255_auto_attach()` to return an error if the device actually > requires port I/O (based on the PCI BAR resource flags) but the > `HAS_IOPORT` configuration is not enabled. > > Cc: Arnd Bergmann > Cc: Niklas Schnelle > Signed-off-by: Ian Abbott > --- > drivers/comedi/drivers/8255_pci.c | 11 ++++++++++- > 1 file changed, 10 insertions(+), 1 deletion(-) > > diff --git a/drivers/comedi/drivers/8255_pci.c > b/drivers/comedi/drivers/8255_pci.c > index 0fec048e3a53..4c4c0ef1db05 100644 > --- a/drivers/comedi/drivers/8255_pci.c > +++ b/drivers/comedi/drivers/8255_pci.c > @@ -57,6 +57,7 @@ > #include > > enum pci_8255_boardid { > +#ifdef CONFIG_HAS_PORTIO I think this is a typo: HAS_IOPORT vs HAS_PORTIO? Arnd