From patchwork Fri Sep 2 14:40:50 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Manuel Lauss X-Patchwork-Id: 1122442 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p82EfC4e005374 for ; Fri, 2 Sep 2011 14:41:18 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752565Ab1IBOlS (ORCPT ); Fri, 2 Sep 2011 10:41:18 -0400 Received: from mail-fx0-f46.google.com ([209.85.161.46]:62232 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752515Ab1IBOlS (ORCPT ); Fri, 2 Sep 2011 10:41:18 -0400 Received: by mail-fx0-f46.google.com with SMTP id 19so1696692fxh.19 for ; Fri, 02 Sep 2011 07:41:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=1Ais5N4Exd1kEG9UTZcPrEUftYSmjaLO1kZm0Zb23N4=; b=JfcDWvLi+gvisZicGKFH1BhtvzRfRQ3cp/ZpN9utRSEg7xEt/ipYp61VTBcXCFwerc mSR4t9w3K+h/9HhcHfBLPtaHQgj2dUp5FLNh5hb2DcHGCIf2GYbsFJsjPaKL3FM1zUZQ LVu5O+sCIBdD1sBF0fiJWA0Rgfju1kPnVNHdo= Received: by 10.223.62.145 with SMTP id x17mr1890814fah.21.1314974477585; Fri, 02 Sep 2011 07:41:17 -0700 (PDT) Received: from localhost.localdomain (188-22-147-179.adsl.highway.telekom.at [188.22.147.179]) by mx.google.com with ESMTPS id e4sm931401fag.25.2011.09.02.07.41.15 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 02 Sep 2011 07:41:16 -0700 (PDT) From: Manuel Lauss To: linux-fbdev@vger.kernel.org, Florian Tobias Schandinat Cc: Manuel Lauss Subject: [PATCH 5/6] au1200fb: fix hardcoded IRQ Date: Fri, 2 Sep 2011 16:40:50 +0200 Message-Id: <1314974451-8535-6-git-send-email-manuel.lauss@googlemail.com> X-Mailer: git-send-email 1.7.6 In-Reply-To: <1314974451-8535-1-git-send-email-manuel.lauss@googlemail.com> References: <1314974451-8535-1-git-send-email-manuel.lauss@googlemail.com> 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 (demeter1.kernel.org [140.211.167.41]); Fri, 02 Sep 2011 14:41:19 +0000 (UTC) Use the IRQ provided by platform resource information. Required for Au1300 support. Signed-off-by: Manuel Lauss --- 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 b1b16d9..ed5dcdb2 100644 --- a/drivers/video/au1200fb.c +++ b/drivers/video/au1200fb.c @@ -1595,7 +1595,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; @@ -1671,10 +1671,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; } @@ -1722,7 +1724,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; }