From patchwork Thu Aug 18 10:10:58 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 9287371 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 4A3DA607FF for ; Thu, 18 Aug 2016 10:51:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 39B3828A31 for ; Thu, 18 Aug 2016 10:51:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2CF4D28F9F; Thu, 18 Aug 2016 10:51:42 +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 A36FB28A31 for ; Thu, 18 Aug 2016 10:51:41 +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 1baKv6-0002up-Ii; Thu, 18 Aug 2016 10:51:32 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1baKt0-0000E3-J1 for linux-amlogic@bombadil.infradead.org; Thu, 18 Aug 2016 10:49:22 +0000 Received: from mail-wm0-x232.google.com ([2a00:1450:400c:c09::232]) by merlin.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1baKId-0000Ik-Px for linux-amlogic@lists.infradead.org; Thu, 18 Aug 2016 10:11:48 +0000 Received: by mail-wm0-x232.google.com with SMTP id f65so232389090wmi.0 for ; Thu, 18 Aug 2016 03:11:27 -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=Cys7D0R1pmmVe83c2fXZ64fU2+LrnYXvTUzDcsWkjtk=; b=DCXHIFZey9rTstxKBHtCFefklMC/dDtzHu3GRS+QW+YGPxCpAuzC5MOH75UaHB56Jv MIQP/SsLCoDHUHgBmCjv2HIYIyCWIkU9PNNUGjoSYiZKk/bTzB+cUJcnJi5PteD8BOPY rjjrj3v8AQ3x1Erl88FkCCR7gSOJKSp9b28veRB1UYeOYzN8zRa4cu9aTtxisARfaMkd ZGDWk21ZoLYkWf9RHOAazjtHVn5AkzE0Z1WFiwEHuC+iCBbk44vN1PsTyWpDRdCZPm5F iSBOpl7H24GEqJe4iUG5tM4RD8RAdnPQGRjWSQNniMtq5rOGBpZwX7kwcZFZlII8KrNK nQaw== 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=Cys7D0R1pmmVe83c2fXZ64fU2+LrnYXvTUzDcsWkjtk=; b=fQQaTuwTRrfXIUehTt8iq+OnHzB6kXVxcU0nih9Aio33kiyn/c25vzBcjm95UTTtfx udqUfRQyCSrmwKyZox4Wkp0Vtw27hzAkAwSsuXpIR6B3h7WSP6wi4Njqcsc5HFkk9be3 ymP1KIVpWW5frr+1o/gn5PLqZKMDg3auf0yAv52F8GPo/G1JzoxSEWSdyPVf1vOh5bCo evCw/s6fMPQtzveTiJp6QuC4yX2ko9WNYzrDazitrT5gFYJYzmAMBC3nsv/e/ISd4SIn Iapr2gkfuQBGo8YBWKbxhQdYJLpZjozFx4tD14x3grx3eiZM0WKk8vTvZDR0lAPvaQ6S HwnQ== X-Gm-Message-State: AEkoousJ8dwpnNoJ5PgJwY1sV0qHPJSXZ5K+Xg5MdpY7aJWgcdkCPPwf5AFNt6vOIyXOtUAW X-Received: by 10.194.173.74 with SMTP id bi10mr1510452wjc.72.1471515085782; Thu, 18 Aug 2016 03:11:25 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id f4sm30915247wmf.8.2016.08.18.03.11.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 18 Aug 2016 03:11:25 -0700 (PDT) From: Neil Armstrong To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, sudeep.holla@arm.com Subject: [PATCH 05/13] scpi: move of_match table before probe functions Date: Thu, 18 Aug 2016 12:10:58 +0200 Message-Id: <1471515066-3626-6-git-send-email-narmstrong@baylibre.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1471515066-3626-1-git-send-email-narmstrong@baylibre.com> References: <1471515066-3626-1-git-send-email-narmstrong@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160818_061147_968853_BC1C07BB X-CRM114-Status: GOOD ( 11.39 ) X-BeenThere: linux-amlogic@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-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Move the of_match table to prapre adding new compatible strings, with match data in order to be used by the probe function. Signed-off-by: Neil Armstrong --- drivers/firmware/arm_scpi.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/firmware/arm_scpi.c b/drivers/firmware/arm_scpi.c index bb9965f..b0d911b 100644 --- a/drivers/firmware/arm_scpi.c +++ b/drivers/firmware/arm_scpi.c @@ -972,6 +972,13 @@ static int scpi_alloc_xfer_list(struct device *dev, struct scpi_chan *ch) return 0; } +static const struct of_device_id scpi_of_match[] = { + {.compatible = "arm,scpi"}, + {}, +}; + +MODULE_DEVICE_TABLE(of, scpi_of_match); + static int scpi_probe(struct platform_device *pdev) { int count, idx, ret; @@ -1069,13 +1076,6 @@ err: return of_platform_populate(dev->of_node, NULL, NULL, dev); } -static const struct of_device_id scpi_of_match[] = { - {.compatible = "arm,scpi"}, - {}, -}; - -MODULE_DEVICE_TABLE(of, scpi_of_match); - static struct platform_driver scpi_driver = { .driver = { .name = "scpi_protocol",