From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 41E23C4167B for ; Tue, 5 Dec 2023 18:48:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232261AbjLESsC (ORCPT ); Tue, 5 Dec 2023 13:48:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232183AbjLESr6 (ORCPT ); Tue, 5 Dec 2023 13:47:58 -0500 Received: from mail-pl1-x632.google.com (mail-pl1-x632.google.com [IPv6:2607:f8b0:4864:20::632]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1377C1BC for ; Tue, 5 Dec 2023 10:48:05 -0800 (PST) Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-1d0481b68ebso10158865ad.0 for ; Tue, 05 Dec 2023 10:48:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1701802084; x=1702406884; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=n9X0r27/UbN68GCjekZeYhwtKfth61JxLqxfjcWsu3w=; b=YV2NNP5+YFYUnHdaeV4f6/85wPAFHWoasarITInW0kh+SFHFbfPwIyYU6WgGtvE98P xP9YrLa2YLFqpTVvsguubIcm9Sd+HxuIE7XW252He/6OiWRYT3v1NJlneHu/1WjpqFU6 Z+LWKyT9WKAFwEFMpEA9SLzDKtQdfj+td3nEc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701802084; x=1702406884; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=n9X0r27/UbN68GCjekZeYhwtKfth61JxLqxfjcWsu3w=; b=GhIhKnshYeL/kYgkpATmks+h9qj/kQUs/GE3T20B5t4YN7j2Sw69tCRSpBRQ/QqjEr 7hyEYk+KGEm++A0wrayP+XbZa48ULiMpKVqynmHeGtvEpq6AxUCpuCTcBrXTFhWN5Iff BYTkpsYPFpaKDrbHxbY1IOFBVxqfY5N89Cfpw1qGk68tk2CDIhl1adtXT4FPGSehGVAN gT2FJBSAbq+MPT8JmF8sZFmuErtowVur5xbIUeH5XdRNjW7wUsi3Ey14cW2N+rxCT3jS zmmLmieKTddedkP+64+nMt9jyYDOTb83pwZDc/kB547dIehC4bqnINXzKsh47IBrE8lx iZew== X-Gm-Message-State: AOJu0YwbOIxhOYdKFR0OoyNx+L1i31/6J06hraBzLqH9SbdZG1uDVc0v D0kRpdUsKw9GQ8/xESRvUtLPTQ== X-Google-Smtp-Source: AGHT+IE1+yOzhmVcL8taX+gYSSTqB7TcNtmGAbJ+dH168Aul+Cu6lmHkkattSuS8hRhsTx9zw4Jk4g== X-Received: by 2002:a17:903:41c1:b0:1d0:6eae:8e57 with SMTP id u1-20020a17090341c100b001d06eae8e57mr12590444ple.1.1701802084368; Tue, 05 Dec 2023 10:48:04 -0800 (PST) Received: from lbrmn-mmayer.ric.broadcom.net ([192.19.161.248]) by smtp.gmail.com with ESMTPSA id b11-20020a1709027e0b00b001bbb7af4963sm10726422plm.68.2023.12.05.10.48.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 10:48:03 -0800 (PST) Received: by lbrmn-mmayer.ric.broadcom.net (Postfix, from userid 1000) id 7555AD00; Tue, 5 Dec 2023 10:48:02 -0800 (PST) From: Markus Mayer To: Krzysztof Kozlowski , Florian Fainelli , Rob Herring , Conor Dooley Cc: Markus Mayer , Linux ARM Kernel List , Device Tree Mailing List , Linux Kernel Mailing List Subject: [PATCH 0/4] memory: brcmstb_dpfe: support DPFE API v4 Date: Tue, 5 Dec 2023 10:47:33 -0800 Message-ID: <20231205184741.3092376-1-mmayer@broadcom.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org It has become necessary to distinguish between the various DPFE API versions by version number. Having just chip-specific compatible strings and one generic version is no longer meeting our needs. Also, a new DPFE API version, v4, needs to be supported by the driver. As a result, an intermediate compatible string format is being introduced: brcm,dpfe-cpu-v where represents the API version number. This is more specific than the catch-all "brcm,dpfe-cpu" and more generic than chip-specific compatible strings, such as "brcm,bcm7271-dpfe-cpu". The changes are split into several steps. First, we update the binding and introduce the versioned compatible strings. Secondly, we add support for brcm,dpfe-cpu-v1 through brcm,dpfe-cpu-v3 in the driver to match existing API versions. Thirdly, we introduce DPFE API v4. Lastly, there is a change that isn't directly related to the introduction of the new binding format or DPFE API v4. However, with the increasing number of API versions, broadening compatibility can be helpful. If registering the driver using the DT-provided compatible string fails, the driver will try all DPFE APIs (except for v1) to see if one might end up working. This can come in handy if the driver moves on and learns about new API versions while Device Tree cannot be updated. Markus Mayer (4): dt-bindings: memory: additional compatible strings for Broadcom DPFE memory: brcmstb_dpfe: introduce version-specific compatible strings memory: brcmstb_dpfe: support DPFE API v4 memory: brcmstb_dpfe: introduce best-effort API detection .../memory-controllers/brcm,dpfe-cpu.yaml | 8 +- drivers/memory/brcmstb_dpfe.c | 95 ++++++++++++++++++- 2 files changed, 100 insertions(+), 3 deletions(-) -- 2.43.0