From patchwork Sun Jun 12 17:15:29 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Manuel Lauss X-Patchwork-Id: 873142 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p5CHFar0001244 for ; Sun, 12 Jun 2011 17:15:36 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751017Ab1FLRPf (ORCPT ); Sun, 12 Jun 2011 13:15:35 -0400 Received: from mail-ww0-f44.google.com ([74.125.82.44]:42588 "EHLO mail-ww0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751159Ab1FLRPf (ORCPT ); Sun, 12 Jun 2011 13:15:35 -0400 Received: by wwa36 with SMTP id 36so4186788wwa.1 for ; Sun, 12 Jun 2011 10:15:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:date:message-id:x-mailer; bh=ROjG+hFraPoIRE1slvO1e3QcJtiXRHvtgRs7jLMbyBA=; b=pJyJqy/AK4ecJDaTAqJNDxQQn+0XTHcpFx9mSATRTMbqNwEPDzTBFdvkYHUixAYChb W6oxu3WgMzpsFNrI9MwZUIXClAixNQENIpEuWybXCvo5Qqny8ghkd2m8IFR2I4hNA8pL h/yoDBdvFW+2j32KRB4akpbRu0vldAZF0Plgo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=vttPf7sYf0zu/jdLeb8kf6Qdvxhu/IFn/sGXnCQALXVoKGo80E/sPwacFEZ5XHXi7e VbWFQOA3hPGpW5z6eHa0GBsZMhNBj9D6mi5pcS5P1YHE7oAaGTNvRSZ1m7KMv/XRlXRY 0xz7/r0qDbyyoAgYOmUKN4wjyp6H92av8n20g= Received: by 10.216.239.67 with SMTP id b45mr1769561wer.44.1307898933887; Sun, 12 Jun 2011 10:15:33 -0700 (PDT) Received: from localhost.localdomain (188-22-11-39.adsl.highway.telekom.at [188.22.11.39]) by mx.google.com with ESMTPS id o38sm3614597wba.54.2011.06.12.10.15.32 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 12 Jun 2011 10:15:32 -0700 (PDT) From: Manuel Lauss To: Linux-FBDEV Cc: Manuel Lauss Subject: [PATCH] au1200fb: fix hardcoded IRQ Date: Sun, 12 Jun 2011 19:15:29 +0200 Message-Id: <1307898929-12365-1-git-send-email-manuel.lauss@googlemail.com> X-Mailer: git-send-email 1.7.5.3 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Sun, 12 Jun 2011 17:15:36 +0000 (UTC) Use the IRQ provided by platform resource information. Required for Au1300 support. Signed-off-by: Manuel Lauss --- applies on top of the other 3 au1200fb patches sent earlier. drivers/video/au1200fb.c | 12 +++++++----- 1 files changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/video/au1200fb.c b/drivers/video/au1200fb.c index e018373..e6d3478 100644 --- a/drivers/video/au1200fb.c +++ b/drivers/video/au1200fb.c @@ -1631,7 +1631,7 @@ static int __devinit au1200fb_drv_probe(struct platform_device *dev) struct au1200fb_device *fbdev; struct fb_info *fbi = NULL; unsigned long page; - int bpp, plane, ret; + int bpp, plane, ret, irq; /* shut gcc up */ ret = 0; @@ -1707,10 +1707,12 @@ static int __devinit au1200fb_drv_probe(struct platform_device *dev) } /* Now hook interrupt too */ - if ((ret = request_irq(AU1200_LCD_INT, au1200fb_handle_irq, - IRQF_DISABLED | IRQF_SHARED, "lcd", (void *)dev)) < 0) { + irq = platform_get_irq(dev, 0); + ret = request_irq(irq, au1200fb_handle_irq, + IRQF_DISABLED | IRQF_SHARED, "lcd", (void *)dev); + if (ret) { print_err("fail to request interrupt line %d (err: %d)", - AU1200_LCD_INT, ret); + irq, ret); goto failed; } @@ -1758,7 +1760,7 @@ static int __devexit au1200fb_drv_remove(struct platform_device *dev) _au1200fb_infos[plane] = NULL; } - free_irq(AU1200_LCD_INT, (void *)dev); + free_irq(platform_get_irq(dev, 0), (void *)dev); return 0; }