From patchwork Mon Dec 3 05:43:47 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Qing Xu X-Patchwork-Id: 203292 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail-da0-f64.google.com (mail-da0-f64.google.com [209.85.210.64]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 091752C0098 for ; Mon, 3 Dec 2012 16:43:57 +1100 (EST) Received: by mail-da0-f64.google.com with SMTP id r6sf2042268dad.9 for ; Sun, 02 Dec 2012 21:43:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20120806; h=mime-version:x-beenthere:received-spf:from:to:subject:date :message-id:x-mailer:x-originalarrivaltime:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-google-group-id:list-post:list-help:list-archive:sender :list-subscribe:list-unsubscribe:content-type; bh=HsVOffxm8f1dDq3cAXCp6dP6rbTPxqBCjF9thOvpTrY=; b=tKLwDBWNJDIh/4eBXbHTMDm/RCwkqMg+19wV1eQlEX70bdVLfUjCxeJVsruC20EXSC R5iYgUidFRVOuE4qSk+juKzfYKDe3HpoEQnPqhePD6+bfTHQAPAupqegbMOTefC9XkjV 7+I6K+D/IrqU2FRxkTGhPVVNCJe/uhF7ib7c80rsJSZyaJT8Zm083CoO95hmJaZtZbE1 L6vjIan80N6VSUOI/kKHUe0MBS+UL3VTnvoCajaE3c/L7sKqMr0vHprujbCkPRifu6z0 8TWu3BV5ynUbgFXQCa7x9qOVDiorRpQS+vKN/CerQg7wiew43aYy5/bTgnsS9z1ggrKh Md3Q== Received: by 10.50.91.165 with SMTP id cf5mr1596919igb.4.1354513434166; Sun, 02 Dec 2012 21:43:54 -0800 (PST) MIME-Version: 1.0 X-BeenThere: rtc-linux@googlegroups.com Received: by 10.50.40.134 with SMTP id x6ls1378066igk.21.canary; Sun, 02 Dec 2012 21:43:53 -0800 (PST) Received: by 10.66.86.6 with SMTP id l6mr1980841paz.11.1354513433622; Sun, 02 Dec 2012 21:43:53 -0800 (PST) Received: by 10.66.86.6 with SMTP id l6mr1980840paz.11.1354513433612; Sun, 02 Dec 2012 21:43:53 -0800 (PST) Received: from na3sys009aog108.obsmtp.com (na3sys009aog108.obsmtp.com [74.125.149.199]) by gmr-mx.google.com with SMTP id uz6si2252740pbc.0.2012.12.02.21.43.44 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 02 Dec 2012 21:43:53 -0800 (PST) Received-SPF: neutral (google.com: 74.125.149.199 is neither permitted nor denied by best guess record for domain of qingx@marvell.com) client-ip=74.125.149.199; Received: from MSI-MTA.marvell.com ([65.219.4.132]) (using TLSv1) by na3sys009aob108.postini.com ([74.125.148.12]) with SMTP ID DSNKULw8EHCBgwA/dt7zYqqyWaduIQNIWDbn@postini.com; Sun, 02 Dec 2012 21:43:53 PST Received: from maili.marvell.com ([10.68.76.210]) by MSI-MTA.marvell.com with Microsoft SMTPSVC(6.0.3790.3959); Sun, 2 Dec 2012 21:43:43 -0800 Received: from localhost (unknown [10.38.36.185]) by maili.marvell.com (Postfix) with ESMTP id 912D54E510; Sun, 2 Dec 2012 21:43:43 -0800 (PST) From: Qing Xu To: a.zummo@towertech.it, qingx@marvell.com, zhouqiao@marvell.com, sameo@linux.intel.com, cxie4@marvell.com, linux-kernel@vger.kernel.org, rtc-linux@googlegroups.com Subject: [rtc-linux] [PATCH 4/4] rtc: 88pm80x: update irq base Date: Mon, 3 Dec 2012 13:43:47 +0800 Message-Id: <1354513427-21266-1-git-send-email-qingx@marvell.com> X-Mailer: git-send-email 1.7.0.4 X-OriginalArrivalTime: 03 Dec 2012 05:43:43.0678 (UTC) FILETIME=[27DCC5E0:01CDD119] X-Original-Sender: qingx@marvell.com X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 74.125.149.199 is neither permitted nor denied by best guess record for domain of qingx@marvell.com) smtp.mail=qingx@marvell.com Reply-To: rtc-linux@googlegroups.com Precedence: list Mailing-list: list rtc-linux@googlegroups.com; contact rtc-linux+owners@googlegroups.com List-ID: X-Google-Group-Id: 712029733259 List-Post: , List-Help: , List-Archive: Sender: rtc-linux@googlegroups.com List-Subscribe: , List-Unsubscribe: , From: Qing Xu irq base is stored in 88pm80x's drv data, we need to add irq base to get the correct irq num Signed-off-by: Qiao Zhou Signed-off-by: Qing Xu --- drivers/rtc/rtc-88pm80x.c | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/rtc/rtc-88pm80x.c b/drivers/rtc/rtc-88pm80x.c index 6367984..7c3a264 100644 --- a/drivers/rtc/rtc-88pm80x.c +++ b/drivers/rtc/rtc-88pm80x.c @@ -256,7 +256,7 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev) struct pm80x_rtc_info *info; struct rtc_time tm; unsigned long ticks = 0; - int ret; + int irq, ret; pdata = pdev->dev.platform_data; if (pdata == NULL) @@ -266,12 +266,13 @@ static int __devinit pm80x_rtc_probe(struct platform_device *pdev) devm_kzalloc(&pdev->dev, sizeof(struct pm80x_rtc_info), GFP_KERNEL); if (!info) return -ENOMEM; - info->irq = platform_get_irq(pdev, 0); - if (info->irq < 0) { + irq = platform_get_irq(pdev, 0); + if (irq < 0) { dev_err(&pdev->dev, "No IRQ resource!\n"); ret = -EINVAL; goto out; } + info->irq = irq + chip->irq_base; info->chip = chip; info->map = chip->regmap;