All of lore.kernel.org
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 3/3] [OneNAND] Flex-OneNAND boundary settings
Date: Mon, 9 Nov 2009 14:02:22 -0600	[thread overview]
Message-ID: <20091109200222.GA11164@loki.buserror.net> (raw)
In-Reply-To: <DB01E78930CF4B429517162B35FE1322@sisodomain.com>

On Fri, Nov 06, 2009 at 05:17:44PM +0530, Amul Kumar Saha wrote:
> -			printk("Bad blocks %d at 0x%x\n",
> -			       (u32)(ofs >> this->erase_shift), (u32)ofs);
> +			printk("Bad blocks %lu at 0x%x\n",
> +			       (u32)onenand_block(this, ofs), (u32)ofs);

cmd_onenand.c: In function ?onenand_block_read?:
cmd_onenand.c:103: warning: format ?%lu? expects type ?long unsigned int?,
but argument 2 has type ?unsigned int?

If you must pass a u32 to printf, use "%u" or "%x" -- but it makes little
sense to explicitly cast from int to something that doesn't have a standard
printf format string.

How about this?

+			printk("Bad block %d at 0x%llx\n",
+			       onenand_block(this, ofs), ofs);

Likewise throughout the rest of the file.

-Scott

  reply	other threads:[~2009-11-09 20:02 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-24  6:13 [U-Boot] [PATCH 3/3] [OneNAND] Flex-OneNAND boundary settings Amul Kumar Saha
2009-11-04  5:09 ` Amul Kumar Saha
2009-11-05 23:08   ` Scott Wood
2009-11-06 11:43     ` Amul Kumar Saha
2009-11-06 11:47       ` Amul Kumar Saha
2009-11-09 20:02         ` Scott Wood [this message]
2009-11-11  5:56           ` Amul Kumar Saha
2009-11-11  5:57           ` Amul Kumar Saha
2009-11-16 22:56             ` Wolfgang Denk
2009-11-19 11:14               ` Amul Kumar Saha

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091109200222.GA11164@loki.buserror.net \
    --to=scottwood@freescale.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.