From patchwork Mon Jul 12 02:50:07 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neal Buckendahl X-Patchwork-Id: 58562 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [18.85.46.34]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id AA9BEB6EF3 for ; Mon, 12 Jul 2010 12:51:47 +1000 (EST) Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1OY95x-0001hw-Aw; Mon, 12 Jul 2010 02:50:13 +0000 Received: from mail-iw0-f177.google.com ([209.85.214.177]) by bombadil.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1OY95v-0001gi-2A for linux-mtd@lists.infradead.org; Mon, 12 Jul 2010 02:50:11 +0000 Received: by iwn40 with SMTP id 40so4812173iwn.36 for ; Sun, 11 Jul 2010 19:50:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:content-type :content-transfer-encoding; bh=z9Im46Ok7lHK/lytwc7aX/sg8fY+NyGtSCD4ZkutEcc=; b=oZn00sLOW8Sj6e6GitKipejVndXR0nld0+dXcZlTK1RQdtQTXj3qwncdU6RmJgzLw/ SHIIO8GCw422GdjYU90sOdv7tVsGMX1cf4A2XFTDW2yA0awR+FtS2oZijWekLnpg6sbl GovckmwPlxHaaM2CTiEfjjguXnXp7bGjw3k18= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :content-type:content-transfer-encoding; b=MuBstRbqsimNWXNy11L1RUeCmcZJ0iCBeNXeRcfepgMkJ3C7mPJgZZQIa4wOcptSzP uP60Dr9NZovJIdnata0OKk1tKs09rTDXf8VJA0iFx7v/QBvRXvyUQ0R5Hh3Ypn/EvDB5 GVEbmMGZ8RAqgmdlP+PFvnex0GbL/KYaQubtI= Received: by 10.231.14.136 with SMTP id g8mr13368686iba.146.1278903010347; Sun, 11 Jul 2010 19:50:10 -0700 (PDT) Received: from [192.168.0.5] (adsl-75-57-125-67.dsl.emhril.sbcglobal.net [75.57.125.67]) by mx.google.com with ESMTPS id r3sm17297886ibk.19.2010.07.11.19.50.09 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 11 Jul 2010 19:50:09 -0700 (PDT) Message-ID: <4C3A82DF.8080604@gmail.com> Date: Sun, 11 Jul 2010 21:50:07 -0500 From: Neal B User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100423 Thunderbird/3.0.4 MIME-Version: 1.0 To: Artem.Bityutskiy@nokia.com Subject: [PATCH 3/6] Mtd: fixed space related issues X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20100711_225011_178930_D4F6F86B X-CRM114-Status: GOOD ( 18.43 ) X-Spam-Score: 2.1 (++) X-Spam-Report: SpamAssassin version 3.3.1 on bombadil.infradead.org summary: Content analysis details: (2.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is freemail (nealb001[at]gmail.com) 2.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends in digit (nealb001[at]gmail.com) -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.0 T_TO_NO_BRKTS_FREEMAIL T_TO_NO_BRKTS_FREEMAIL Cc: maximlevitsky@gmail.com, cascardo@holoscopio.com, linux-kernel@vger.kernel.org, Julia Lawall , linux-mtd@lists.infradead.org, jkosina@suse.cz, mohanlaljangir@gmail.com, rmk+kernel@arm.linux.org.uk, dwmw2@infradead.org X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-mtd-bounces@lists.infradead.org Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From 5af46680b31132acbd587b953d390317796700de Mon Sep 17 00:00:00 2001 From: Neal Buckendahl Date: Sun, 11 Jul 2010 17:26:13 -0500 Subject: [PATCH 3/6] Mtd: fixed space related issues found by the checkpatch.pl tool Signed-off-by: Neal Buckendahl --- drivers/mtd/inftlcore.c | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) if (add_mtd_blktrans_dev(&inftl->mbd)) { @@ -279,7 +279,7 @@ static u16 INFTL_foldchain(struct INFTLrecord *inftl, unsigned thisVUC, unsigned */ silly = MAX_LOOPS; while (thisEUN < inftl->nb_blocks) { - for (block = 0; block < inftl->EraseSize/SECTORSIZE; block ++) { + for (block = 0; block < inftl->EraseSize/SECTORSIZE; block++) { if ((BlockMap[block] != BLOCK_NIL) || BlockDeleted[block]) continue; @@ -291,7 +291,7 @@ static u16 INFTL_foldchain(struct INFTLrecord *inftl, unsigned thisVUC, unsigned else status = oob.b.Status | oob.b.Status1; - switch(status) { + switch (status) { case SECTOR_FREE: case SECTOR_IGNORE: break; @@ -341,7 +341,7 @@ static u16 INFTL_foldchain(struct INFTLrecord *inftl, unsigned thisVUC, unsigned /* * Copy only in non free block (free blocks can only - * happen in case of media errors or deleted blocks). + * happen in case of media errors or deleted blocks). */ if (BlockMap[block] == BLOCK_NIL) continue; @@ -476,7 +476,7 @@ static inline u16 INFTL_findwriteunit(struct INFTLrecord *inftl, unsigned block) { unsigned int thisVUC = block / (inftl->EraseSize / SECTORSIZE); unsigned int thisEUN, writeEUN, prev_block, status; - unsigned long blockofs = (block * SECTORSIZE) & (inftl->EraseSize -1); + unsigned long blockofs = (block * SECTORSIZE) & (inftl->EraseSize - 1); struct mtd_info *mtd = inftl->mbd.mtd; struct inftl_oob oob; struct inftl_bci bci; @@ -504,7 +504,7 @@ static inline u16 INFTL_findwriteunit(struct INFTLrecord *inftl, unsigned block) DEBUG(MTD_DEBUG_LEVEL3, "INFTL: status of block %d in " "EUN %d is %x\n", block , writeEUN, status); - switch(status) { + switch (status) { case SECTOR_FREE: writeEUN = thisEUN; break; @@ -677,7 +677,7 @@ static void INFTL_trydeletechain(struct INFTLrecord *inftl, unsigned thisVUC) else status = bci.Status | bci.Status1; - switch(status) { + switch (status) { case SECTOR_FREE: case SECTOR_IGNORE: break; @@ -943,7 +943,7 @@ static struct mtd_blktrans_ops inftl_tr = { .name = "inftl", .major = INFTL_MAJOR, .part_bits = INFTL_PARTN_BITS, - .blksize = 512, + .blksize = 512, .getgeo = inftl_getgeo, .readsect = inftl_readblock, .writesect = inftl_writeblock, diff --git a/drivers/mtd/inftlcore.c b/drivers/mtd/inftlcore.c index 015a7fe..d318270 100644 --- a/drivers/mtd/inftlcore.c +++ b/drivers/mtd/inftlcore.c @@ -114,7 +114,7 @@ static void inftl_add_mtd(struct mtd_blktrans_ops *tr, struct mtd_info *mtd) "(== 0x%lx sects)\n", inftl->cylinders, inftl->heads , inftl->sectors, (long)inftl->cylinders * (long)inftl->heads * - (long)inftl->sectors ); + (long)inftl->sectors); }