From patchwork Wed Mar 13 10:52:19 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vikas C Sajjan X-Patchwork-Id: 2271311 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork2.kernel.org (Postfix) with ESMTP id D3FBCDFB79 for ; Thu, 14 Mar 2013 14:07:44 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BF9B5E6951 for ; Thu, 14 Mar 2013 07:07:44 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by gabe.freedesktop.org (Postfix) with ESMTP id 3B3F5E687B for ; Wed, 13 Mar 2013 03:52:32 -0700 (PDT) Received: by mail-pb0-f54.google.com with SMTP id rr4so894649pbb.27 for ; Wed, 13 Mar 2013 03:52:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=+BuQldjNfwY0H3StNR5zpathMNmjtbXwbcsBeiULjH8=; b=S/876gjBB+9+GMDt0aznziWICO4VVOCK7xB8EKV1ujP+gbHGAhRZjcCsywpGJNAEGn YMMjZ6q0KAnX2YVlBVgCGlphFYmCbrxRkmxdpYqxqJ2sZfghSxMxcjr9CNzjFpxHWMG8 auBml7kp/2bbzeD3BAYdSMGpjfdut3/Nk7pV3kd3bmQQTXD5qsQ0zVRK+bOezZ3uBs8V VAtQ46GQkMIImMZmQkbx5ygmjuv7v/i/pmhmE0NJDRQTeqbOtQXB3wH6N31SS6R5GPha e5sqDWRamCNrLyBm0uJ3VUaKV4xu9ICSkvj+MULQUfkW7jw05HxpTR/JRMIXFEZnbcW+ LGvQ== X-Received: by 10.68.135.38 with SMTP id pp6mr45188268pbb.111.1363171951249; Wed, 13 Mar 2013 03:52:31 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id y13sm25319396pbv.0.2013.03.13.03.52.26 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 13 Mar 2013 03:52:30 -0700 (PDT) From: Vikas Sajjan To: dri-devel@lists.freedesktop.org Subject: [PATCH] drm/exynos: change the method for getting the interrupt resource of FIMD Date: Wed, 13 Mar 2013 16:22:19 +0530 Message-Id: <1363171939-9672-1-git-send-email-vikas.sajjan@linaro.org> X-Mailer: git-send-email 1.7.9.5 X-Gm-Message-State: ALoCoQmMNGbNfhIT/Rjt36+wvCfEdoRTCrvZTBbUYLxuw7cYH1gSAHE8+TjT3KhOxQJVH8F6EuQx X-Mailman-Approved-At: Thu, 14 Mar 2013 07:05:16 -0700 Cc: kgene.kim@samsung.com, joshi@samsung.com, linaro-kernel@lists.linaro.org, linux-media@vger.kernel.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Replaces the "platform_get_resource() for IORESOURCE_IRQ" with platform_get_resource_byname(). Both in exynos4 and exynos5, FIMD IP has 3 interrupts in the order: "fifo", "vsync", and "lcd_sys". But The FIMD driver expects the "vsync" interrupt to be mentioned as the 1st parameter in the FIMD DT node. So to meet this expectation of the driver, the FIMD DT node was forced to be made by keeping "vsync" as the 1st paramter. For example in exynos4, the FIMD DT node has interrupt numbers mentioned as <11, 1> <11, 0> <11, 2> keeping "vsync" as the 1st paramter. This patch fixes the above mentioned "hack" of re-ordering of the FIMD interrupt numbers by getting interrupt resource of FIMD by using platform_get_resource_byname(). Signed-off-by: Vikas Sajjan --- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index 1ea173a..cd79d38 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c @@ -945,7 +945,7 @@ static int fimd_probe(struct platform_device *pdev) return -ENXIO; } - res = platform_get_resource(pdev, IORESOURCE_IRQ, 0); + res = platform_get_resource_byname(pdev, IORESOURCE_IRQ, "vsync"); if (!res) { dev_err(dev, "irq request failed.\n"); return -ENXIO;