From patchwork Tue Nov 3 08:38:25 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: vimal singh X-Patchwork-Id: 57234 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nA38clGR012630 for ; Tue, 3 Nov 2009 08:38:48 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753343AbZKCIil (ORCPT ); Tue, 3 Nov 2009 03:38:41 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755419AbZKCIil (ORCPT ); Tue, 3 Nov 2009 03:38:41 -0500 Received: from mail-bw0-f227.google.com ([209.85.218.227]:45904 "EHLO mail-bw0-f227.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751716AbZKCIik convert rfc822-to-8bit (ORCPT ); Tue, 3 Nov 2009 03:38:40 -0500 Received: by bwz27 with SMTP id 27so7277521bwz.21 for ; Tue, 03 Nov 2009 00:38:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :from:date:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=aBceDllpUuPVkFsqjLgunZlUL0foVp3BqxGRtnsFzs4=; b=OmtmLfKa21GjAUcrVpR6qwOQYA3cpgXulkBF0sP6YmxKCdRQbuRLYVIGl4WB1P0AoA W7+ded1etn2EeYOO8d1+yVJUc330Tx3gT6dK0/6NKQYPzaM4r3aPy7LDeXQxdMBg4xM1 Tj9dHED923QTtPVR/X0ZVbogKmWuq454C1AU4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=ItGA68Uluz8koo2Gf8Bww5Pv7lu/LYSYr0f6THj+fC9xyK1wppXwhArLNHIfPn3PLK SCjUASZ/lFL2SAOd3RHr4pW18YlBarKQzAFoAwwJMzU/E3folZbG6uo2XvSZ/LgIROV8 0V/0qmUDqcr52tYfg9ZgTPBTyqWzJMdfiClFY= MIME-Version: 1.0 Received: by 10.204.3.19 with SMTP id 19mr4598338bkl.151.1257237525126; Tue, 03 Nov 2009 00:38:45 -0800 (PST) In-Reply-To: <1257236323.21596.56.camel@localhost> References: <1257236323.21596.56.camel@localhost> From: Vimal Singh Date: Tue, 3 Nov 2009 14:08:25 +0530 Message-ID: Subject: Re: [PATCH 1/3] Fixing compilation warning for 'nand/omap2.c' To: dedekind1@gmail.com Cc: Linux MTD , linux-omap@vger.kernel.org Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/drivers/mtd/nand/omap2.c b/drivers/mtd/nand/omap2.c index 090ab87..92573d5 100644 --- a/drivers/mtd/nand/omap2.c +++ b/drivers/mtd/nand/omap2.c @@ -501,11 +501,13 @@ static void omap_read_buf_dma_pref(struct mtd_info *mtd, u_char static void omap_write_buf_dma_pref(struct mtd_info *mtd, const u_char *buf, int len) { + u_char *p = (u_char *)buf; + if (len <= mtd->oobsize) - omap_write_buf_pref(mtd, buf, len); + omap_write_buf_pref(mtd, p, len); else /* start transfer in DMA mode */ - omap_nand_dma_transfer(mtd, buf, len, 0x1); + omap_nand_dma_transfer(mtd, p, len, 0x1); }