From patchwork Wed Sep 7 15:34:33 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 9319569 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id D9AA9601C0 for ; Wed, 7 Sep 2016 15:36:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CB07C293DD for ; Wed, 7 Sep 2016 15:36:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BFD1E293E1; Wed, 7 Sep 2016 15:36:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DAF3D293DD for ; Wed, 7 Sep 2016 15:36:35 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bhesN-000665-5D; Wed, 07 Sep 2016 15:34:59 +0000 Received: from mail-wm0-x232.google.com ([2a00:1450:400c:c09::232]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1bhesG-0005zv-Iv for linux-arm-kernel@lists.infradead.org; Wed, 07 Sep 2016 15:34:53 +0000 Received: by mail-wm0-x232.google.com with SMTP id b187so122485245wme.1 for ; Wed, 07 Sep 2016 08:34:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=SuruDcybFFZq2ncWg6AS7sV9kxGcc6mGXgI8Naxmyzs=; b=Df9xpNJ7kqVTNQlOQBexcpXCiMOO9wp8EkLPN+h6InX1xu0AlVZsRhDW4Psqyeg0QV UKKwHxi88teHiJVuhXSyL1WlWix/JS06MLgEYtaKhBj+N2dDO0+UZMyBrmtgH6Be9tCz N1Q6d3WbCQ4m7Dncjpgx7LSQxL43lG2HVjV7UtEa/QeYr/s9RncJkSsnTIkdLUHXj/Ti W5nJFn+nGiBLvSiJCUWHgzNaSCh3OgLdDxipcOlstL1+nyCr5ttEeqztRoUKw1EFLK8n LQB3gpsY68YJlHWNlQFCdRYyaDTyLDZVnqSA0moLvT8kNHeqpbhNzCC3pdXZU1hOX8Nr ghkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=SuruDcybFFZq2ncWg6AS7sV9kxGcc6mGXgI8Naxmyzs=; b=BOIoQeomtwe+Rp+oq8g+tBg7GI7jvkWb/rM6s9Fkrx/mJWO2tRvJUT+tQ9TyRTuNZY oYBcFV5vTOmmO2ZO/hwABJpxUJ7Cuzn/m3ggv7OLyX3FkOsTleL83p9yXkFIMRbsfpdH W0bRWj4dJbTW6xtcSrXQStuCi2Sxuor8zZqNV8Eyk0yRKC/0q3eAnLxGSzrRq7B2kbyu pYd1dBEIpOtfrbCbZM1VnKS+JUhhUbHVhkJV0JzNAMfja4XTCZTAv13TVGkNi+h2Ni3A Jj01q+2MesFyDcM6DUHdqcjiGwTz569S1Y4XELMAJ8wXB5XSLrf3GdWPqSe66Ju+YfJ6 9eYQ== X-Gm-Message-State: AE9vXwOIg6XrD5O8h/GGeM+WRperdma0rbFsTvK/EKMmqRVsKl9YF8rZMgLsN0y1lBkI/tRq X-Received: by 10.194.84.234 with SMTP id c10mr41460735wjz.34.1473262475174; Wed, 07 Sep 2016 08:34:35 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id q65sm4838480wmd.24.2016.09.07.08.34.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 07 Sep 2016 08:34:34 -0700 (PDT) From: Neil Armstrong To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, sudeep.holla@arm.com Subject: [PATCH v3 4/8] scpi: Add support for Legacy match table for Amlogic GXBB SoC Date: Wed, 7 Sep 2016 17:34:33 +0200 Message-Id: <1473262477-18045-5-git-send-email-narmstrong@baylibre.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1473262477-18045-1-git-send-email-narmstrong@baylibre.com> References: <1473262477-18045-1-git-send-email-narmstrong@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160907_083452_866087_22F593C5 X-CRM114-Status: GOOD ( 11.89 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: heiko@sntech.de, Neil Armstrong , frank.wang@rock-chips.com, khilman@baylibre.com, linux-amlogic@lists.infradead.org, wxt@rock-chips.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Add new DT match table to setup the is_legacy boolean value across the scpi functions. Add the Amlogic GXBB SoC compatible for platform and as legacy match entry. Signed-off-by: Neil Armstrong --- drivers/firmware/arm_scpi.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/firmware/arm_scpi.c b/drivers/firmware/arm_scpi.c index 6a16100..60a76e63 100644 --- a/drivers/firmware/arm_scpi.c +++ b/drivers/firmware/arm_scpi.c @@ -979,6 +979,11 @@ static int scpi_alloc_xfer_list(struct device *dev, struct scpi_chan *ch) return 0; } +static const struct of_device_id legacy_scpi_of_match[] = { + {.compatible = "amlogic,meson-gxbb-scpi"}, + {}, +}; + static int scpi_probe(struct platform_device *pdev) { int count, idx, ret; @@ -991,6 +996,9 @@ static int scpi_probe(struct platform_device *pdev) if (!scpi_info) return -ENOMEM; + if (of_match_device(legacy_scpi_of_match, &pdev->dev)) + scpi_info->is_legacy = true; + count = of_count_phandle_with_args(np, "mboxes", "#mbox-cells"); if (count < 0) { dev_err(dev, "no mboxes property in '%s'\n", np->full_name); @@ -1097,6 +1105,7 @@ err: static const struct of_device_id scpi_of_match[] = { {.compatible = "arm,scpi"}, + {.compatible = "amlogic,meson-gxbb-scpi"}, {}, };