Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp493181rwl; Sat, 25 Mar 2023 06:04:13 -0700 (PDT) X-Google-Smtp-Source: AKy350ZkwbU/l7MSh0GUbN1jseKB/CO0yD/6fTj8WaZxqtLQIdCUJVbmtuCWpnmnt69dH5ao9yAt X-Received: by 2002:a17:903:1391:b0:1a0:48c6:3b43 with SMTP id jx17-20020a170903139100b001a048c63b43mr5473640plb.37.1679749453338; Sat, 25 Mar 2023 06:04:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679749453; cv=none; d=google.com; s=arc-20160816; b=Gh9Q8GRVkAQ/+pWLhlpYyex2H8Le9aCA4Z3L5l27zxCTQN6Df23CLnmpn6z7fY3h8B j7R02uvE7Jxsip5xxVBWNMdGOzGH2iGwwG7NtN4LwRQKjhrX52KuflDNC1llwlPG1AIN DFfFCofMsZeNjwll0qcJP1GxoZjTzeyUZ8usmdKCYs6KZmPNktG6VF+0MC6J/j57BSXX +wJvfGzEUifKgtZoY+U2HTmTy+nY9FI1/AG/T8QoqMUfevU8UwHXsc0M/EbQWucuojO6 jGBFeY1QqcElz3zpKfajahkrRKHsnYxxh1aMi7fqFWcjOxWqJ+OrgnMOfafI0pkyW2mV J/9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version; bh=RtCdX52DC4/zs+1qnx48jSvvaJ1OxQNWxfR5bfU/2WA=; b=gtaniY+wCjTGXmG8YJ2lBbdL+DfsqYPKo4WW2H0zOmSJG2DAZVewUUDF5zrIssgs3B 4FA/4/kE8O+4BK+i5jp5Y4P4pVrim6O3ve5ucoH6mDptKpze6ayqaBQ5OemEwWNSF2Nr XZoZgtXbWcC40FZnZhDW51zi0lx7CsruSspvbX+WBSnH0t7K2YY8Ap5WOcrq+rmST3zb xyXVdfm9997wD4WapiXT1kC//7ncnZ3BdxFDAVrUbACgKqxNxpViL5/4urakEoTLZNYJ ZU6cujn58QmppkpEDHZ1QVyuIHRM2A1UoTD7nWgg0KrtNIGknaRAyWldbjBzFog9HsCd CTpg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 7-20020a631447000000b00508cd5d9f6dsi22665278pgu.290.2023.03.25.06.04.01; Sat, 25 Mar 2023 06:04:13 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231501AbjCYMpF convert rfc822-to-8bit (ORCPT + 99 others); Sat, 25 Mar 2023 08:45:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44504 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229505AbjCYMpD (ORCPT ); Sat, 25 Mar 2023 08:45:03 -0400 Received: from mail-lj1-f178.google.com (mail-lj1-f178.google.com [209.85.208.178]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2F7E111171 for ; Sat, 25 Mar 2023 05:45:02 -0700 (PDT) Received: by mail-lj1-f178.google.com with SMTP id o20so1423715ljp.3 for ; Sat, 25 Mar 2023 05:45:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679748300; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=I3FEH8eZrFvGP+z3Ek8xngh+/YrLq34X8EDL4pF+Bk0=; b=1R0leLUNmpOn4Ju0jJsAo6Z8rOhoF5Ul9cswW46b7UHIVBulzhoIrtbXxYBphHJZlv XY1KAWtHm059mDx8ssipMvwpiMzrZl1pYHXUbdXxfjRqZHXZTV19AzbKkRB5UU45D/2A 70Of4gra5WmdAmT8QQ54m44YVtfbDl7TJhXlCkWiRMsUHH2t8BW/VOcM0eRrSx1RkkVB kQLzw58IlQhJqiB6cPfr5u857X4CvFzmOKe9chHpgP9TnUYW1Qbqu1Kfgiqgnx88yh0a LHoASYgssoRqDnsgfwOWUzkYiCH5sAL2gnxUcHMAJ9y7NSjQaju7zLWDWPjdU7YTg+hG OlhQ== X-Gm-Message-State: AAQBX9dSrfATUQIOBJXgKqUhy40ICcg+8/Knd31bHgy0l/Bfx1W64EZp khI1vckSALrIMgaRGrdD4EFnzNW9B8mcJXA+ X-Received: by 2002:a2e:7005:0:b0:295:93eb:e795 with SMTP id l5-20020a2e7005000000b0029593ebe795mr1976945ljc.41.1679748299595; Sat, 25 Mar 2023 05:44:59 -0700 (PDT) Received: from mail-lf1-f45.google.com (mail-lf1-f45.google.com. [209.85.167.45]) by smtp.gmail.com with ESMTPSA id u22-20020a2e8456000000b00295b2e08b90sm3680485ljh.65.2023.03.25.05.44.59 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 25 Mar 2023 05:44:59 -0700 (PDT) Received: by mail-lf1-f45.google.com with SMTP id t11so5581565lfr.1 for ; Sat, 25 Mar 2023 05:44:59 -0700 (PDT) X-Received: by 2002:a05:6512:143:b0:4db:266c:4338 with SMTP id m3-20020a056512014300b004db266c4338mr1703638lfo.1.1679748299291; Sat, 25 Mar 2023 05:44:59 -0700 (PDT) MIME-Version: 1.0 References: <5b7c473247d66776343d82a55b9815195b1b11fb.1679551394.git.fthain@linux-m68k.org> <072fd894-ec50-ae5f-2be5-ebbeb0e7b39b@linux-m68k.org> <20230324085927.GA6354@allandria.com> <0cd7f288-ba43-7764-01a7-2e1e5c7a1640@linux-m68k.org> In-Reply-To: <0cd7f288-ba43-7764-01a7-2e1e5c7a1640@linux-m68k.org> From: Geert Uytterhoeven Date: Sat, 25 Mar 2023 13:44:43 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2] nubus: Don't list card resources by default To: Finn Thain Cc: Brad Boyer , linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT X-Spam-Status: No, score=0.5 required=5.0 tests=FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no 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 Hi Finn, On Sat, Mar 25, 2023 at 12:33 AM Finn Thain wrote: > On Fri, 24 Mar 2023, Brad Boyer wrote: > > On Fri, Mar 24, 2023 at 10:13:51AM +1100, Finn Thain wrote: > > > On Thu, 23 Mar 2023, Geert Uytterhoeven wrote: > > > > On Thu, Mar 23, 2023 at 7:02???AM Finn Thain wrote: > > > > > --- a/drivers/nubus/nubus.c > > > > > +++ b/drivers/nubus/nubus.c > > > > > @@ -34,6 +34,9 @@ > > > > > > > > > > LIST_HEAD(nubus_func_rsrcs); > > > > > > > > > > +bool procfs_rsrcs; > > > > > +module_param(procfs_rsrcs, bool, 0444); > > > > > > > > With the expanded functionality, is "rsrcs" still a good name? > > > > Perhaps this should be an integer, so you can define different > > > > levels? E.g. > > > > - 0 = just devices > > > > - 1 = above + boards + public resources > > > > - 2 = above + private resources > > > > > > That really depends on how the proc entries get used. I think it's > > > probably going to be developers who would use them so I consider all > > > of this to be outside of the UAPI and subject to change. But it would > > > be nice to hear from other developers on that point. > > > > I don't know of anything that currently uses them, but there's a number > > of potential uses depending on how far we want to take things. A real > > video driver for X.org for some of the more advanced cards could take > > advantage of some of the secondary information made available. I've got > > a number of NuBus video cards with some acceleration capabilities that > > were pretty advanced for the time. > > Good point. I had not considered Xorg drivers. But I'm not sure why > userspace drivers would access /proc when they already need /dev/mem or > some more modern graphics API to be implemented by an in-kernel driver. > > > There's even a driver in the ROM on video cards that could be used, but > > that also requires more emulation of the MacOS environment. KVM could > > potentially need more information if we got it running on m68k, although > > I doubt any real Mac has enough RAM to make that useful. > > You only need a few MB to run MacOS (or an early Linux distro). So I > rather think that KVM could be workable with 64 or 128 MB of RAM. > > The /proc/bus/nubus/boards file is not affected by this patch, so userland > tools could still identify the available boards if need be. Perhaps it would be worthwhile to move the resources out of /proc, but into a separate virtual file system? That way people who need access to the additional info can load the separate virtual file system kernel module, and mount the file system? Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds