From patchwork Wed Dec 9 14:00:15 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 58149 Delivered-To: patch@linaro.org Received: by 10.112.147.194 with SMTP id tm2csp686518lbb; Wed, 9 Dec 2015 06:00:47 -0800 (PST) X-Received: by 10.98.12.20 with SMTP id u20mr12909124pfi.71.1449669637933; Wed, 09 Dec 2015 06:00:37 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id qd3si12892112pab.208.2015.12.09.06.00.37; Wed, 09 Dec 2015 06:00:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754949AbbLIOAg (ORCPT + 4 others); Wed, 9 Dec 2015 09:00:36 -0500 Received: from mailout1.w1.samsung.com ([210.118.77.11]:63277 "EHLO mailout1.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754449AbbLIOA3 (ORCPT ); Wed, 9 Dec 2015 09:00:29 -0500 Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NZ300LQ9G8R7280@mailout1.w1.samsung.com>; Wed, 09 Dec 2015 14:00:27 +0000 (GMT) X-AuditID: cbfec7f5-f79b16d000005389-92-566833fbadb5 Received: from eusync1.samsung.com ( [203.254.199.211]) by eucpsbgm2.samsung.com (EUCPMTA) with SMTP id 23.AF.21385.BF338665; Wed, 9 Dec 2015 14:00:27 +0000 (GMT) Received: from amdc1339.digital.local ([106.116.147.30]) by eusync1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0NZ300N2FG8M3900@eusync1.samsung.com>; Wed, 09 Dec 2015 14:00:27 +0000 (GMT) From: Marek Szyprowski To: linux-media@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: Marek Szyprowski , Sylwester Nawrocki , Kamil Debski Subject: [PATCH 3/4] media: s5p-mfc: remove non-device-tree init code Date: Wed, 09 Dec 2015 15:00:15 +0100 Message-id: <1449669616-24802-3-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.2 In-reply-to: <1449669616-24802-1-git-send-email-m.szyprowski@samsung.com> References: <1449669616-24802-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrNJMWRmVeSWpSXmKPExsVy+t/xy7q/jTPCDCavYrb48foCm0XPhq2s FjPO72OyWHvkLrvF4TftrA6sHn1bVjF6fN4kF8AUxWWTkpqTWZZapG+XwJWxa91TxoLrghWn Lh5hamA8zdfFyMkhIWAisXPGKWYIW0ziwr31bF2MXBxCAksZJU4s/8ME4TQxSZxov8EEUsUm YCjR9baLDcQWEXCSWDjrLztIEbNAK1DHvaesIAlhAVeJzp4LLCA2i4CqxKQd+8EaeAU8JO70 P2CEWCcn8f/lCqChHBycAp4S66c7gYSFgEpuPPzIOoGRdwEjwypG0dTS5ILipPRcI73ixNzi 0rx0veT83E2MkCD5uoNx6TGrQ4wCHIxKPLwVTulhQqyJZcWVuYcYJTiYlUR4T+hnhAnxpiRW VqUW5ccXleakFh9ilOZgURLnnbnrfYiQQHpiSWp2ampBahFMlomDU6qBMYE1UdoqK4Vp4mwb lbUNuzuvaGdmK1RlzX5uny5+UnD5h/5pv5QrAn7KzjCbEHaUYRIX67F176M3OoRWXVLeUKq9 6rJxaeft/7OzsqcVP2JKW6r78bV91KGjspvd7YueGKix6ZanfeZKzpsUqtCwLPDMnU+bzuwy aq045jh3s5rIJQWXbpEYJZbijERDLeai4kQAXCsRVA4CAAA= Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Exynos and Samsung S5Pxxxx platforms has been fully converted to device tree, so old platform device based init data can be now removed. Signed-off-by: Marek Szyprowski --- drivers/media/platform/s5p-mfc/s5p_mfc.c | 37 +++++--------------------------- 1 file changed, 5 insertions(+), 32 deletions(-) -- 1.9.2 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c b/drivers/media/platform/s5p-mfc/s5p_mfc.c index bae7c0f..5d0a75e 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c @@ -1489,27 +1489,6 @@ static struct s5p_mfc_variant mfc_drvdata_v8 = { .fw_name[0] = "s5p-mfc-v8.fw", }; -static const struct platform_device_id mfc_driver_ids[] = { - { - .name = "s5p-mfc", - .driver_data = (unsigned long)&mfc_drvdata_v5, - }, { - .name = "s5p-mfc-v5", - .driver_data = (unsigned long)&mfc_drvdata_v5, - }, { - .name = "s5p-mfc-v6", - .driver_data = (unsigned long)&mfc_drvdata_v6, - }, { - .name = "s5p-mfc-v7", - .driver_data = (unsigned long)&mfc_drvdata_v7, - }, { - .name = "s5p-mfc-v8", - .driver_data = (unsigned long)&mfc_drvdata_v8, - }, - {}, -}; -MODULE_DEVICE_TABLE(platform, mfc_driver_ids); - static const struct of_device_id exynos_mfc_match[] = { { .compatible = "samsung,mfc-v5", @@ -1531,24 +1510,18 @@ MODULE_DEVICE_TABLE(of, exynos_mfc_match); static void *mfc_get_drv_data(struct platform_device *pdev) { struct s5p_mfc_variant *driver_data = NULL; + const struct of_device_id *match; + + match = of_match_node(exynos_mfc_match, pdev->dev.of_node); + if (match) + driver_data = (struct s5p_mfc_variant *)match->data; - if (pdev->dev.of_node) { - const struct of_device_id *match; - match = of_match_node(exynos_mfc_match, - pdev->dev.of_node); - if (match) - driver_data = (struct s5p_mfc_variant *)match->data; - } else { - driver_data = (struct s5p_mfc_variant *) - platform_get_device_id(pdev)->driver_data; - } return driver_data; } static struct platform_driver s5p_mfc_driver = { .probe = s5p_mfc_probe, .remove = s5p_mfc_remove, - .id_table = mfc_driver_ids, .driver = { .name = S5P_MFC_NAME, .pm = &s5p_mfc_pm_ops,