Received: by 2002:a19:651b:0:0:0:0:0 with SMTP id z27csp3647905lfb; Mon, 9 May 2022 00:45:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy6osdZYwzsRdtD7d51CAMYNikTTVJOX0Ns0/Zy9l69LvZE5yG0xLZHo9SZ6Rgmayt+IoG0 X-Received: by 2002:a05:6a00:10d3:b0:4fe:5d:75c8 with SMTP id d19-20020a056a0010d300b004fe005d75c8mr14905917pfu.6.1652082310517; Mon, 09 May 2022 00:45:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652082310; cv=none; d=google.com; s=arc-20160816; b=P4pe0lYU6zg8MHdkQzeg+YKqO6oUXnw5ZC/ev3OdUN2ANfPQ2ot1EExXi2DFv7kGWB tVLlqss2qoOZlfCYeRgx3ZAfuhZfcLd97CQ75wZTrAtc7g6oyHNBBpE7/Qv535Du3yRk KTbXzlrOx4NrNRSxbuY7qm4pjG2rKhS/xmzgAmbl/cWjdhSUpA4ZAV45BCUrYIx+yXs0 K7h1XsPKQr4ggcRFaO3CgXx7Axmm0mr8+Z6nUjcXJB8Eslk6demXJaaSdeB1/6yrqXZn rlXXsYhJ+1yDN5t8NMNP3kJqAsjYF5+247bW5P2mGzWFO75xKYjKxP/u0xdcO+hF/iXN JTCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :message-id:subject:cc:to:from:date:dkim-signature; bh=b8k7r7T+k8bsJfhUtRsF1M5Q1pEUFk5VmKbgS0ZlfIc=; b=wZJIqtsPthqq4gx97YVPXaf3RDq4j5AnlxFBsXd1DMCzmDs6jf8dnW7uXLs0o2Uo8m wEN5C0/Tw8fU/cG8ZAY0K9yiyHS0iYLKea48WVf8rubRyU/RjIxsfWDDw4i4watyHeDy rUwjyX2ikrHhG98nFsV9OjKXfga8HzAOW64tEQJf7m3eTyLmmOZpEfeUOeGV8e1XB+4x fKM2nnavujL+tg3SxeWtERmv+5hznAGXJ1KzIinKnbF7pM76zF9cEb89gwJaRd4PjhPi 0/WFMQF4f2pADc9N8o7rwPOjwr2dJQCDBRAKVNB24YMXuxpzWc4lz7R3lFp0SBbPNE4A vPxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GCAXCFuH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id a190-20020a624dc7000000b004fa3a8e002csi13153925pfb.227.2022.05.09.00.45.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 May 2022 00:45:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GCAXCFuH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 8C44B1C83EA; Mon, 9 May 2022 00:39:52 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1385200AbiEETmr (ORCPT + 99 others); Thu, 5 May 2022 15:42:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240224AbiEETmo (ORCPT ); Thu, 5 May 2022 15:42:44 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B98DE5D5F0; Thu, 5 May 2022 12:39:04 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 65FFBB82FAB; Thu, 5 May 2022 19:39:03 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B1BF1C385A4; Thu, 5 May 2022 19:39:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1651779542; bh=nvJ0vKCyj+OxDQA4BLRRzvEtpD2Bij13dOiL8LL8YsA=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=GCAXCFuH/hYZK9EncBIRU6MfSTdzmvcYVBiEkgukAJFyPch+57l6fM7K++h3l2ahh w8Wya2kzM9ZkI8cBsGkE0juf8uZt9tpiPAAY7FHcyNiixr7/8sbH2TRksQSaEkHSnh NSFqnE5jp1FrblYSSi0euVSGNBRFL7YApv7bpPPA47aC2oDo4TRc2bOA08+8FL1C3i TG1YWIhfbeu4EqAPOArqRNVSWpBeJiNJlqOxERmkXZG/ApBI243954L1v6uR2pWRkV rwaCj3TY/yBVdDPBd5tGIED3r9mzX3Uyf8l50hRScAGVvmWmbCZ2e2O1vexeqxKgIc pj2tFgc48frog== Date: Thu, 5 May 2022 14:38:59 -0500 From: Bjorn Helgaas To: "Maciej W. Rozycki" Cc: Arnd Bergmann , Niklas Schnelle , Arnd Bergmann , Greg Kroah-Hartman , Linux Kernel Mailing List , linux-arch , linux-pci , Dominik Brodowski Subject: Re: [RFC v2 25/39] pcmcia: add HAS_IOPORT dependencies Message-ID: <20220505193859.GA509737@bhelgaas> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_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: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 05, 2022 at 09:45:14AM +0100, Maciej W. Rozycki wrote: > On Wed, 4 May 2022, Bjorn Helgaas wrote: > > > > Well, yes, except I would expect POWER9_CPU (and any higher versions we > > > eventually get) to clear HAS_IOPORT. Generic configurations (GENERIC_CPU) > > > would set HAS_IOPORT of course, as would any lower architecture variants > > > that do or may support port I/O (it's not clear to me if there are any > > > that do not). Ideally a generic configuration would not issue accesses to > > > random MMIO locations for port I/O accesses via `inb'/`outb', etc. for > > > systems that do not support port I/O (which it now does, or at least used > > > to until recently). > > > > It would seem weird to me that a module would build and run on a > > generic kernel running on POWER9 (with some safe way of handling > > inb/outb that don't actually work), but not on a kernel built > > specifically for POWER9_CPU. > > Why? If you say configure your Alpha kernel for ALPHA_JENSEN, a pure > EISA system, then you won't get PCI support nor any PCI drivers offered > even though a generic Alpha kernel will get them all and still run on a > Jensen system. I find that no different from our case here. > > And if we do ever get TURBOchannel Alpha support, then a generic kernel > configuration will offer EISA, PCI and TURBOchannel drivers, while you > won't be offered TURBOchannel drivers for a PCI system and vice versa. > It would make no sense to me. > > Please mind that the main objective for system-specific configurations is > optimisation, including both size and speed, and a part of the solution is > discarding stuff that's irrelevant for the respective system. So in our > case we do want any port I/O code not to be there at all in compiled code > and consequently any driver that absolutely requires port I/O code to work > will have to become a useless stub in its compiled form. What would be > the point then of having it there in the first place except to spread > confusion? Good points.