From patchwork Fri Oct 30 08:42:20 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: vimal singh X-Patchwork-Id: 56581 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 n9U8gg5t015627 for ; Fri, 30 Oct 2009 08:42:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756467AbZJ3Img (ORCPT ); Fri, 30 Oct 2009 04:42:36 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756431AbZJ3Img (ORCPT ); Fri, 30 Oct 2009 04:42:36 -0400 Received: from mail-bw0-f227.google.com ([209.85.218.227]:53316 "EHLO mail-bw0-f227.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756367AbZJ3Imf (ORCPT ); Fri, 30 Oct 2009 04:42:35 -0400 Received: by mail-bw0-f227.google.com with SMTP id 27so3265936bwz.21 for ; Fri, 30 Oct 2009 01:42:40 -0700 (PDT) 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:content-type; bh=UqOki7A1MnfRY/S4bOxW6AeA9kADNSkg5Lp6g207PFw=; b=pxI2R3joO4aHsqTn0Cv4f7J6V+4xNANcYCbtfQgMFb6ffgWJrLElSZdSpIlZg1bCeL EDNDBVJPSbv8HmpW29r9xbV+CNh19uJ+0Y/wxfpozf3xmgI5CBhUlWaAUXvin2kVmiMg 7cAL8905Nsp3VXyie1yoogmvTX0riMk8h3n0A= 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 :content-type; b=rgk0nJJcHOOUq8d/+BdwQLUdsMnTlHImRKQWqby6TUdsAUMVkhcr256KpB9pSVUsYw 4rq7k/KLa1lT4C+meKv8KLe9nDj8R/8JtUX5suv3QedkYDBffVJb+oUpX9RqySJNHA/m LMymgD/tRh1zDdV7hlwVxv0V09vk9lEipO0FU= MIME-Version: 1.0 Received: by 10.204.154.150 with SMTP id o22mr865075bkw.154.1256892160107; Fri, 30 Oct 2009 01:42:40 -0700 (PDT) In-Reply-To: References: From: Vimal Singh Date: Fri, 30 Oct 2009 14:12:20 +0530 Message-ID: Subject: Re: [PATCH 1/3] Fixing compilation warning for 'nand/omap2.c' To: 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 *buf, int len) 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); }