Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp6917713rwp; Tue, 18 Jul 2023 07:36:01 -0700 (PDT) X-Google-Smtp-Source: APBJJlHnvghujAivWeG4qO4WYdCj5pVMyXT3vATXPSivYpIrIWvWepnQY7CObs7AEYnUaJinSkMq X-Received: by 2002:a17:906:7386:b0:994:5396:e32c with SMTP id f6-20020a170906738600b009945396e32cmr118076ejl.3.1689690960777; Tue, 18 Jul 2023 07:36:00 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1689690960; cv=pass; d=google.com; s=arc-20160816; b=crqjJzGMgGfVSOgrwof9tPdn9PZN97ic2lDYmmFkxiI6BSj28QjRyd5vNet1y2cZgr 0K+nJueoJxaysxyc77ul5oWC4goByu56uM2pwuFt7NKo4loFJkzym4IqV4C1VC6cm6Pa gPNs0dAfRQPUiTB+PY6VezxVzOj0FA1a5w5ZSPx7HucCiK355QBHbDNjmYyUd1+oSs4Y XyT8hc8c5b+cTf/pO808f2chDvHXTThCB9cuwy9/y4OxzvllHHlZ3oYiSLrORE/nm9Iy Y5kS1z3h/57co4jxflemAQgeMKDnLGSVikhaiyiTZP0rvI/A7V4MBPbX9IH4IMTDfKBg hMKQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:from:references:cc:to:content-language:subject :user-agent:date:message-id:dkim-signature; bh=QlKDGBgg8n3lzsa1apvlsgMvaw3NMAO1kxD/F3WVsbk=; fh=aviYD9xE1isYt1zt8bHXXccWLNaVqbQ9ABSGsinM2dg=; b=aCok2kLA8R6oZrhzaMFufxui7s9hmXI2BMTp+P8baiTon8jC+DEE02yymEYbc21Z0n yFI2qio29hQhHaqRjm5hL9/9g08pSWxr9es8fDXIl4a8XsfOXjUwECQtNWWGCRBYXTMT fqeWWleZWw6G9FLm0i/PcrHmHNqp9TONz0pxrWwr80kta9UBwXqWXp8/Z32441Cmaa3z Uo/RZ37r21l0ki0q/IY/pHm6IX77ubDl4CFxLnLwkzwYWFFXrzSnBKwTqQGM1hro9qC9 zwX6R6t5WC4ubxEsED8b2XvABlJ8P8IED95ZSzkLALP13eaDWN2ifq77TKIaxRwVjtqM Si7A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=4roAWtEi; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l12-20020a170906414c00b00992b0932003si1222664ejk.745.2023.07.18.07.35.36; Tue, 18 Jul 2023 07:36:00 -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=@amd.com header.s=selector1 header.b=4roAWtEi; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232479AbjGROBP (ORCPT + 99 others); Tue, 18 Jul 2023 10:01:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59484 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233162AbjGROAu (ORCPT ); Tue, 18 Jul 2023 10:00:50 -0400 Received: from NAM04-MW2-obe.outbound.protection.outlook.com (mail-mw2nam04on2078.outbound.protection.outlook.com [40.107.101.78]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5BDBE170E; Tue, 18 Jul 2023 07:00:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kONNpFfKxWX1nvDndg2gFmu/dcPRtSQvpbxtRqoBcVPCs8W2KX+BYSZQgAYzaXmYE1544xfQDhhu8u9Gm2qyxDUZFOgzT3Bum9IuJbllaKHJbzNtQFS2Z/mjHJSCKInxPg/1uz9LG+MdYcVROqJ8M3zlS0JCawjpFBN7ebvKuBXagINYc5nH4miMw6cqtBnHdQosYKw7qaFYCpja51cmzWutN2ZmDjiTjpasjvH6YucHmrkdGro3eYDCvOcDJYUaEkfYQBAi9XIf+gHetXg7IxtzqNTYAqNFAI3saXjpP8yH2IAt+EmgAbb7Og0FHWBiRQrhKUWLgZpJfY9HC+WCQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=QlKDGBgg8n3lzsa1apvlsgMvaw3NMAO1kxD/F3WVsbk=; b=XG20DGUatG0Y3VBy5hrgfr50j3RTXobAjdcTRhWW0XZOd2NSBf38cVh8tmmvoMGsR0x8EDNGGagRxd9kEchFDHU1Z06twGcBBU8AiY/2k9AN7R82rQpQf6O8YGjehryaeB/1cOX+jp83Rg/uINU89dFM5vToZrn6pgiPy0AVbjOEZ/T/baSBHShN+hUEBw3GXi0QEmlCXS9XUdkdSflp9qjaADEIrLRLNyPcm0z7vgx2HfGKvmWzoEplXVCeL/wIz4gPJtj8wMaaEG70VChB+e9SLZUzXG/sPxKJ1wE9XRyTdKjoR/yjNpwVuCTpwLUDSWKZluFnW0J7tDa6mS3DFg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=QlKDGBgg8n3lzsa1apvlsgMvaw3NMAO1kxD/F3WVsbk=; b=4roAWtEij97NYv4Z9MTXZIbzYmPEONXSuS84EgnevryOaKy23fdZHHjhCnWwA2QBYZ2fk/3aiXY8Am3QFpO3JYS9pyM+M7Sk0urhx8Xf/jhZObUOYFvuUhB/gb1cPZco3lAfORrQaRP48CmhVgZ545JNWcn3c5o4rGbrfl6ujwI= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from BYAPR12MB4758.namprd12.prod.outlook.com (2603:10b6:a03:a5::28) by CY5PR12MB6057.namprd12.prod.outlook.com (2603:10b6:930:2e::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6609.23; Tue, 18 Jul 2023 13:59:49 +0000 Received: from BYAPR12MB4758.namprd12.prod.outlook.com ([fe80::be39:45a4:cd9b:4684]) by BYAPR12MB4758.namprd12.prod.outlook.com ([fe80::be39:45a4:cd9b:4684%3]) with mapi id 15.20.6588.031; Tue, 18 Jul 2023 13:59:49 +0000 Message-ID: <109990fa-fb67-48e2-6424-37ce47cf68f7@amd.com> Date: Tue, 18 Jul 2023 15:59:42 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: [PATCH 1/2] dt-bindings: reset: Updated binding for Versal-NET reset driver Content-Language: en-US To: Krzysztof Kozlowski , Conor Dooley , Piyush Mehta Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, p.zabel@pengutronix.de, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, git@amd.com References: <20230717112348.1381367-1-piyush.mehta@amd.com> <20230717112348.1381367-2-piyush.mehta@amd.com> <20230717-explode-caucus-82c12e340e39@spud> <694a1314-0b25-ff5e-b19f-5a0efe07bf64@linaro.org> <22e7dc73-2411-5cb1-6cef-daa5f2af8297@linaro.org> <5c45d89b-00c5-a330-2e1f-b99043736527@linaro.org> From: Michal Simek In-Reply-To: <5c45d89b-00c5-a330-2e1f-b99043736527@linaro.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FRYP281CA0001.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10::11) To BYAPR12MB4758.namprd12.prod.outlook.com (2603:10b6:a03:a5::28) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BYAPR12MB4758:EE_|CY5PR12MB6057:EE_ X-MS-Office365-Filtering-Correlation-Id: 5e4ed501-5d74-4e4d-5706-08db87973ffb X-LD-Processed: 3dd8961f-e488-4e60-8e11-a82d994e183d,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: PR/DmYu6PVlJsIzxkYHYc2oNKHCPFQaIxrT9srzdsymkGiRfJjfDw9AtwfkEqxFgp7ItPjo+TEqwqPKXu1mXLFAbmdEEuZO6d9Of/3KS70lSGfUd2wdJfk8MIPFub01kOpz5PCqAVEVvU9GG73qa5d6AhJyrFAmpz0jyD9eNGifXypQ3C3626enL5cpf4c5QgMpK29Kd/2apc6r5rhM/P3i+Q1sdndNiz+PPUc2ZLLtE97Ls3wpwgccTkXq6gx7BvbSuAdcxY5bNZb/avUuyVPVAN68KO+Ma1KHKrc0wbgSolAVfeegdYmsb9Fz0sMxlvE77g//uVCspKp0kqvAdi+W7TA2/N2HQczZ4gkJJyFQjjiRDpVXpYZOkWk1OmJ9QzSR9bog6JP2d8uShqxo8Mk3z2EulmFiljoFGNaNrcw8rCkDDM0dziufmAIHaqiC24Lch8XTTWDZVlOcRh08uL5bNatHgXVXYqiX/g4Cr4Y/Ct6ezBNFsw3+yUQ4XvJn1kKB+oeO2Cy3UNf6A8wRxOHhLL08umLX1XUCAvM+LKhPoSQJ3ybpdQc9hv+U7lBr/V5obdzQ+baB1Y+w4q7b89LIqVCRi+rg8o/+FkA6OAMAzKpQW8ay/Km9aR1Qf2nb+qxetUtvAbZJXj3jvxug2pQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BYAPR12MB4758.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(346002)(366004)(376002)(136003)(39860400002)(396003)(451199021)(15650500001)(110136005)(83380400001)(26005)(6512007)(966005)(6506007)(53546011)(6486002)(86362001)(31696002)(6666004)(36756003)(186003)(2616005)(478600001)(2906002)(6636002)(4326008)(66556008)(66476007)(316002)(5660300002)(66946007)(44832011)(8676002)(31686004)(8936002)(41300700001)(38100700002)(43740500002)(45980500001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?K2dOWXcwSFF3ZUdkN2JLaVFvaWlZaDRJaWFsM2lpN3JnU1RTZTNYaVdaSk9F?= =?utf-8?B?TjZzMndMQVZ5TmZHVGlzK090Z3FuQXJhNHg3bnp6UEhLcTVoZlVzRnZ3ejgz?= =?utf-8?B?aXVZOEtQUWxSaE8zUktGZkNmVmNUc1FKOE9GQXRKc1BlRXRHa2ZpY09YOGNH?= =?utf-8?B?eGRmVWEyUnZFQWV3S0tLdWxxSmhQVVlUNTNuaXg1VTBTd2NMVHhXSHZ2U0NM?= =?utf-8?B?V2RFQmgzd1lMQkJ4aHFxcS9sUVRVcmh5T1hyTWdGcWhmblg0MzQ2Tkhrbmkx?= =?utf-8?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UU1b1VFTld3aWpj?= =?utf-8?Q?c4Ab0D+4hjub4Sk39MVj10E7u?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5e4ed501-5d74-4e4d-5706-08db87973ffb X-MS-Exchange-CrossTenant-AuthSource: BYAPR12MB4758.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Jul 2023 13:59:48.9520 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: vIHTBwpBVj6IZ1P3eKzyfJ2SmPOj8cHw2HjtqaD6rVtFzcRdDGeynx5MLyztWSse X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6057 X-Spam-Status: No, score=-1.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_SPF_HELO,NICE_REPLY_A, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_NONE, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 On 7/18/23 15:21, Krzysztof Kozlowski wrote: > On 18/07/2023 15:20, Krzysztof Kozlowski wrote: >> On 18/07/2023 15:11, Michal Simek wrote: >>>>> >>>>> That numbers in DT are virtual no matter if you use ID from 0 to max or random >>>>> values it is up to code to handle them. Checking nr_pins against ID is done in >>>>> core but it is up to drivers. >>>> >>>> No, you confuse "virtual" and "ID". IDs are not virtual. IDs are real >>>> and have representation in Linux driver. You do not need to define >>>> anything virtual in the bindings. >>> >>> Not sure how you define ID itself. But HW doesn't know ID. HW knows only >>> register which you can use to perform the reset. It is not really 128bit >>> register where every bit targets to different IP. >>> >>> And this is SW-firmware interface like SCMI reset driver. >>> >>> Firmware is saying that ID 0 is QSPI, ID 1 is MMC. >>> Their Linux driver is asking for nr_reset via firmware call which can be >>> different for different SOC and that's fine and I have no problem with it. >>> But only SCMI server is dictating that ID 0 is QSPI and ID 1 is MMC. Different >>> SCMI server implementation can map it differently. >> >> Sure, and all this points to: no need for bindings. >> >>> >>> >>>>> In our case that IDs are coming from firmware and driver itself is just matching >>>>> them. >>>> >>>> So they are the same as if coming from hardware - no need for IDs. >>> >>> It is hard to say what hardware here exactly is. From my perspective and I am >>> not advocating not using IDs from 0 to max, it is just a number. >>> >>> If my firmware knows that QSPI reset is 0xc10402dU then I will just pass it to >>> reach my goal which is reset QSPI IP. >>> >>> If you think that we should use IDs from 0 to max NR I am happy to pass this >>> message to PM team and we should extend any SW to do translation between. >> >> When we talk about IDs and bindings, we mean IDs meaningful to Linux. >> Whatever is ignored by Linux and passed to anyone else - hardware or >> firmware - is not a ID anymore from bindings point of view. It's just >> some value. > > And just some proofs: > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/include/dt-bindings/reset/xlnx-versal-resets.h?h=v6.5-rc2 > $ git grep VERSAL_RST > Results: No users. I know this. I should likely submit one DT for Versal to start to use it. Thanks, Michal