Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp4677835iog; Wed, 22 Jun 2022 03:48:51 -0700 (PDT) X-Google-Smtp-Source: AGRyM1vj1cVOQoobrJ6wr4F3tXABKmv8NaIQbIgma3q4sv94x9mpsbw4LsfW1VVwdn2z1fkibuM9 X-Received: by 2002:a17:907:1612:b0:722:e1b9:45d0 with SMTP id hb18-20020a170907161200b00722e1b945d0mr2502279ejc.439.1655894930703; Wed, 22 Jun 2022 03:48:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655894930; cv=none; d=google.com; s=arc-20160816; b=SPf5QCIo0fO0/ZDTGCNGuiXUr5eF7QqSr10v+cs9IFXUa18xv2gswXZjk6+VCP3MqY vf7SX4z8D6TGoP4DW3NvycyPy7C3cG4tkCYGOqHbRnW5rEXQPqTRE3UiZv1HDv7poqrI XgFAbDAonPOPmuRNzpapHYW48CBcIDUgr09k6N5zltFBce+T8LB5EHVraT5thvQSlV42 KcH9W2rN5P9dgJhg4+ACKc6R5+1KWI3g9FlbgDj8c3kiKPYKwLCzsXnU4AvxOB6+CUXG jG+8i7SW/46ckqk06ZgvgTBGn50VLmMn06JchEerrCR2EDdXlW7lU85C6yDdUe60QWLA oFFw== 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-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=KstnPrZL4rr0aahkBWDZ8zd/1wQWBwwKzIrMw8MswtM=; b=olbT4hcwvpCH8PlmkpFscgJXAEP9B6JGDAHZjO+UKHvrVBY/7nWtsJ6yCHENsFxb1f nEP5vOA557b4GYQazAjhV8LoWNjjvhOMe1gHtKV1HKf0iOgtLkVba2wwPuc6BcqFaXwO VDJa7UdFOLUU5wKc8fFLuF2SiybPyR/KbBBhYO/b5ZB/M69gzvSdN86z17GAZKmGMPjr tq0CVhiz89gDDC4YD6dSlKVLX/3HJuuA1SwRDhidat0FKHPMbJsOZaDbuvGW7Gf8lsDG L3lzCB5C9mp+ZZEYg3xFf6ukgcxmeyric1Z7mQwRAnnIOSi7UoY5XuxRxOsJ4NXuVdpo wd7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=WHVGymPV; 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 i25-20020a0564020f1900b004357f40d9d5si10230385eda.258.2022.06.22.03.48.24; Wed, 22 Jun 2022 03:48:50 -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=@lunn.ch header.s=20171124 header.b=WHVGymPV; 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 S232260AbiFVKh7 (ORCPT + 99 others); Wed, 22 Jun 2022 06:37:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55874 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241614AbiFVKhx (ORCPT ); Wed, 22 Jun 2022 06:37:53 -0400 Received: from vps0.lunn.ch (vps0.lunn.ch [185.16.172.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A36A33B57C; Wed, 22 Jun 2022 03:37:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Transfer-Encoding:Content-Disposition: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:From: Sender:Reply-To:Subject:Date:Message-ID:To:Cc:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Content-Disposition: In-Reply-To:References; bh=KstnPrZL4rr0aahkBWDZ8zd/1wQWBwwKzIrMw8MswtM=; b=WH VGymPVMYAvBYTD31EwQg262dPP8n19uFY3yLtqVOpTYeQxwV8eQgT3DhtTzELKANToYa9nnC1xUPA BLw7cFE1g5pvnOauxhG2CY+x9Rl9X8IyDRfwfZ+swCwRz0leoW7ihHvSuSw5MHH4JP39/aXYlnAmL mRuf/XFW5z2ykHY=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1o3xk2-007qDI-Kd; Wed, 22 Jun 2022 12:37:46 +0200 Date: Wed, 22 Jun 2022 12:37:46 +0200 From: Andrew Lunn To: Marcin Wojtas Cc: Andy Shevchenko , Linux Kernel Mailing List , ACPI Devel Maling List , netdev , "Rafael J. Wysocki" , Len Brown , vivien.didelot@gmail.com, Florian Fainelli , Vladimir Oltean , "David S. Miller" , Eric Dumazet , Jakub Kicinski , pabeni@redhat.com, Russell King - ARM Linux , Heiner Kallweit , Grzegorz Bernacki , Grzegorz Jaszczyk , Tomasz Nowicki , Samer El-Haj-Mahmoud , upstream@semihalf.com Subject: Re: [net-next: PATCH 09/12] Documentation: ACPI: DSD: introduce DSA description Message-ID: References: <20220620150225.1307946-1-mw@semihalf.com> <20220620150225.1307946-10-mw@semihalf.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham 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 Wed, Jun 22, 2022 at 12:22:23PM +0200, Marcin Wojtas wrote: > śr., 22 cze 2022 o 11:24 Andrew Lunn napisał(a): > > > > On Wed, Jun 22, 2022 at 11:08:13AM +0200, Marcin Wojtas wrote: > > > wt., 21 cze 2022 o 13:42 Andy Shevchenko > > > napisał(a): > > > > > > > > On Tue, Jun 21, 2022 at 01:18:38PM +0200, Andrew Lunn wrote: > > > > > On Tue, Jun 21, 2022 at 02:09:14PM +0300, Andy Shevchenko wrote: > > > > > > On Mon, Jun 20, 2022 at 09:47:31PM +0200, Andrew Lunn wrote: > > > > > > > > ... > > > > > > > > > > > > + Name (_CRS, ResourceTemplate () > > > > > > > > + { > > > > > > > > + Memory32Fixed (ReadWrite, > > > > > > > > + 0xf212a200, > > > > > > > > + 0x00000010, > > > > > > > > > > > > > > What do these magic numbers mean? > > > > > > > > > > > > Address + Length, it's all described in the ACPI specification. > > > > > > > > > > The address+plus length of what? This device is on an MDIO bus. As > > > > > such, there is no memory! It probably makes sense to somebody who > > > > > knows ACPI, but to me i have no idea what it means. > > > > > > > > I see what you mean. Honestly I dunno what the device this description is for. > > > > For the DSA that's behind MDIO bus? Then it's definitely makes no sense and > > > > MDIOSerialBus() resources type is what would be good to have in ACPI > > > > specification. > > > > > > > > > > It's not device on MDIO bus, but the MDIO controller's register itself > > > > Ah. So this is equivalent to > > > > CP11X_LABEL(mdio): mdio@12a200 { > > #address-cells = <1>; > > #size-cells = <0>; > > compatible = "marvell,orion-mdio"; > > reg = <0x12a200 0x10>; > > clocks = <&CP11X_LABEL(clk) 1 9>, <&CP11X_LABEL(clk) 1 5>, > > <&CP11X_LABEL(clk) 1 6>, <&CP11X_LABEL(clk) 1 18>; > > status = "disabled"; > > }; > > > > DT seems a lot more readable, "marvell,orion-mdio" is a good hint that > > device this is. But maybe it is more readable because that is what i'm > > used to. > > No worries, this reaction is not uncommon (including myself), I agree > it becomes more readable, the longer you work with it :). > > IMO the ACPI node of orion-mdio looks very similar. Please take a look: > > Device (SMI0) > { > Name (_HID, "MRVL0100") // _HID: Hardware ID > Name (_UID, 0x00) // _UID: Unique ID > Method (_STA) // _STA: Device status > { > Return (0xF) > } > Name (_CRS, ResourceTemplate () > { > Memory32Fixed (ReadWrite, > 0xf212a200, // Address Base > 0x00000010, // Address Length > ) > }) > } > > You can "map" the objects/methods to what you know from DT farly easily: > _HID -> compatible string MRVL0100 is pretty meaningless, but marvell,orion-mdio gives you a much better idea what the device is. That i would say is the key of the problem here. Without knowing what MRVL0100 means, it is hard to guess the rest. Andrew