Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp491653rdb; Tue, 5 Dec 2023 10:48:13 -0800 (PST) X-Google-Smtp-Source: AGHT+IHrVg6R7T/yO/GZ6juwT2rChvhTfIm1Fp+njwA10hklxHDaF7GqkFrlONXKb2O3HtLBzAoT X-Received: by 2002:a05:6a00:3685:b0:6cd:ec0b:61ae with SMTP id dw5-20020a056a00368500b006cdec0b61aemr1499732pfb.0.1701802093624; Tue, 05 Dec 2023 10:48:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701802093; cv=none; d=google.com; s=arc-20160816; b=g/3ZrSMeOU3UVZ/ttjyHrWpY/ipLTgLmkGxKjwOgPLfk+H7wRMhvKWj2QbNdUSY6uA 9dTpine2O9hXYEOKYv29ihA/LbAaw42dY4oVxEzx0YZDB+72dUHJBs49t6wirw1BVpsB XBdZWeim5FnY503ge9ukecXlT+TzmJLorWXkyvPKYP9Cas0jQVw9C7OVMAOCT4ZX1SJT Scnr6vbHh1nhL6QeiP57LJvUMbeXEkMn9xU+IWwy1Qt3iNK7WLLACMIQ62xn3DwINXPL DcPgd0g4zN9S3kjfj+l7TJIs8wsns//gTgbNLvs6x2wlODDKKum6kTI2qiGP969cYhQk 31jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=n9X0r27/UbN68GCjekZeYhwtKfth61JxLqxfjcWsu3w=; fh=JtBfHkLwU5057B0nnGl+wIE10FqpQSpetKyOLDjQ+JQ=; b=C5H/OqQjtqHFUytkJl8ZkLAZw+u+xgD/8X2VG/1dJAkVEMLwgZ3oJUIpJWiGCJaKLL pzulH5u9jPAVrtv/SMDs6ii/AWxRin6QYToAn9RKQUo+cCAlHNCLgGTW72kGl/d1Qjdv K+sQcluY1g5ylOwZViFq8zvC25isEiwKjCunarUdrowa0/JABWc6LKoZ5yDJ4OlB4fRQ +nqXfJUWHa1tI7O1SIaLO8jVBjhTezaEzKWSES9kL/rl5HlsjBjxXl0LAEwLZ8yrzrGq fG7XU5ZvsMGI9nkfri6owCGeZkltetjkfIqnTqBTDHvyVW/+t8kFoqgqbYirQB4R4BKH oYdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=YV2NNP5+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id n2-20020a635902000000b005b869e53b1csi9848237pgb.797.2023.12.05.10.48.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 10:48:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=YV2NNP5+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 5CF5080309E0; Tue, 5 Dec 2023 10:48:12 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232239AbjLESsB (ORCPT + 99 others); Tue, 5 Dec 2023 13:48:01 -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-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 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_NONE,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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Tue, 05 Dec 2023 10:48:12 -0800 (PST) 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