From patchwork Wed Apr 25 04:12:17 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 8105 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 3A5AD23E13 for ; Wed, 25 Apr 2012 04:22:22 +0000 (UTC) Received: from mail-iy0-f180.google.com (mail-iy0-f180.google.com [209.85.210.180]) by fiordland.canonical.com (Postfix) with ESMTP id EAE7FA1860D for ; Wed, 25 Apr 2012 04:22:21 +0000 (UTC) Received: by mail-iy0-f180.google.com with SMTP id e36so2775712iag.11 for ; Tue, 24 Apr 2012 21:22:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=XgavSn3li9wiATzCvPgfbRHPcnJU2/+yKZzqA1f4Tvs=; b=V0lLWlK7EoPsNRdWwjpZG4a+PupE05fhBiy5dudZoGQNaPqieOoEfN5tn8AoUuR5sg X4VzEILEmDnrqoeJf1dwUAfemqdPxglo03TfZs6N5dKtF7Xb/f8L2QRNa5ZsFgE0IsLH Qvq1fCat50ZJubp2tlDBV4BrSUJbrCEV3uDHmh39U4VmSx0r5JfQDAc4h6G7oQd/MTwz /uiyjtmMKspikPykWAoC8F/9c34JhsgOuqZzZkekvk4xZ4xvz5NQFCjfFpn7R/fpqXKm wLORboY5bABqEaI/IbGWn0akpuiqurYQEMDbSoG5hwyTCMy7E3KwunERnBrzKVnMTJ/x IjtQ== Received: by 10.50.41.201 with SMTP id h9mr12676610igl.19.1335327741728; Tue, 24 Apr 2012 21:22:21 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.137.198 with SMTP id x6csp231164ibt; Tue, 24 Apr 2012 21:22:21 -0700 (PDT) Received: by 10.68.241.164 with SMTP id wj4mr2672677pbc.1.1335327740857; Tue, 24 Apr 2012 21:22:20 -0700 (PDT) Received: from mail-pz0-f44.google.com (mail-pz0-f44.google.com [209.85.210.44]) by mx.google.com with ESMTPS id of4si22406508pbb.262.2012.04.24.21.22.20 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 Apr 2012 21:22:20 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.210.44 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) client-ip=209.85.210.44; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.210.44 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) smtp.mail=tushar.behera@linaro.org Received: by mail-pz0-f44.google.com with SMTP id z14so5396129dad.17 for ; Tue, 24 Apr 2012 21:22:20 -0700 (PDT) Received: by 10.68.233.105 with SMTP id tv9mr3729236pbc.99.1335327740613; Tue, 24 Apr 2012 21:22:20 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id pv9sm9954480pbc.37.2012.04.24.21.22.16 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 Apr 2012 21:22:20 -0700 (PDT) From: Tushar Behera To: linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: kgene.kim@samsung.com, linux@arm.linux.org.uk, patches@linaro.org, Ben Dooks Subject: [PATCH 07/33] ARM: S3C24XX: bast-ide: Use common macro to define resources Date: Wed, 25 Apr 2012 09:42:17 +0530 Message-Id: <1335327163-11794-8-git-send-email-tushar.behera@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1335327163-11794-1-git-send-email-tushar.behera@linaro.org> References: <1335327163-11794-1-git-send-email-tushar.behera@linaro.org> X-Gm-Message-State: ALoCoQk0+4mCgEadHc+kUvKYsMLr4vERyGhn8a3ip+3JN/B+ciwB/ewicIgHH8hHjPexRIZd5VKm CC: Ben Dooks CC: Kukjin Kim Signed-off-by: Tushar Behera --- arch/arm/mach-s3c24xx/bast-ide.c | 36 ++++++------------------------------ 1 files changed, 6 insertions(+), 30 deletions(-) diff --git a/arch/arm/mach-s3c24xx/bast-ide.c b/arch/arm/mach-s3c24xx/bast-ide.c index 298ecec..ba02cf8 100644 --- a/arch/arm/mach-s3c24xx/bast-ide.c +++ b/arch/arm/mach-s3c24xx/bast-ide.c @@ -37,21 +37,9 @@ static struct pata_platform_info bast_ide_platdata = { #define IDE_CS S3C2410_CS5 static struct resource bast_ide0_resource[] = { - [0] = { - .start = IDE_CS + BAST_PA_IDEPRI, - .end = IDE_CS + BAST_PA_IDEPRI + (8 * 0x20) - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = IDE_CS + BAST_PA_IDEPRIAUX + (6 * 0x20) , - .end = IDE_CS + BAST_PA_IDEPRIAUX + (7 * 0x20) - 1, - .flags = IORESOURCE_MEM, - }, - [2] = { - .start = IRQ_IDE0, - .end = IRQ_IDE0, - .flags = IORESOURCE_IRQ, - }, + [0] = DEFINE_RES_MEM(IDE_CS + BAST_PA_IDEPRI, 8 * 0x20), + [1] = DEFINE_RES_MEM(IDE_CS + BAST_PA_IDEPRIAUX + (6 * 0x20), 0x20), + [2] = DEFINE_RES_IRQ(IRQ_IDE0), }; static struct platform_device bast_device_ide0 = { @@ -67,21 +55,9 @@ static struct platform_device bast_device_ide0 = { }; static struct resource bast_ide1_resource[] = { - [0] = { - .start = IDE_CS + BAST_PA_IDESEC, - .end = IDE_CS + BAST_PA_IDESEC + (8 * 0x20) - 1, - .flags = IORESOURCE_MEM, - }, - [1] = { - .start = IDE_CS + BAST_PA_IDESECAUX + (6 * 0x20), - .end = IDE_CS + BAST_PA_IDESECAUX + (7 * 0x20) - 1, - .flags = IORESOURCE_MEM, - }, - [2] = { - .start = IRQ_IDE1, - .end = IRQ_IDE1, - .flags = IORESOURCE_IRQ, - }, + [0] = DEFINE_RES_MEM(IDE_CS + BAST_PA_IDESEC, 8 * 0x20), + [1] = DEFINE_RES_MEM(IDE_CS + BAST_PA_IDESECAUX + (6 * 0x20), 0x20), + [2] = DEFINE_RES_IRQ(IRQ_IDE1), }; static struct platform_device bast_device_ide1 = {