public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Wolfgang Denk <wd@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH][v2] driver/ifc:Change accessor function to take care of endianness
Date: Sat, 18 Jan 2014 09:24:52 +0100	[thread overview]
Message-ID: <20140118082452.BC291380481@gemini.denx.de> (raw)
In-Reply-To: <1390028310-30861-1-git-send-email-prabhakar@freescale.com>

Dear Prabhakar Kushwaha,

In message <1390028310-30861-1-git-send-email-prabhakar@freescale.com> you wrote:
> IFC registers can be of type Little Endian or big Endian depending upon
> Freescale SoC. Here SoC defines the register type of IFC IP.

As is, you are only adding dead code, as there is no place anywhere in
the mainline code that defines CONFIG_SYS_FSL_IFC_LE


>  	/* Program ROW0/COL0 */
> -	out_be32(&ifc->ifc_nand.row0, page_addr);
> -	out_be32(&ifc->ifc_nand.col0, (oob ? IFC_NAND_COL_MS : 0) | column);
> +	ifc_out32(&ifc->ifc_nand.row0, page_addr);
> +	ifc_out32(&ifc->ifc_nand.col0, (oob ? IFC_NAND_COL_MS : 0) | column);

I seriously dislike the idea of introducing special I/O accessors for
a single device driver.  If more drivers would follow that example, we
will soon have a serious mess.



If would probably be useful to understand what you are trying to do if
we could see where you actually need this, so we can then try and
figure out a better implementation.

In the current form this should not be added to mainline.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"The whole world is about three drinks behind."     - Humphrey Bogart

  reply	other threads:[~2014-01-18  8:24 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-18  6:58 [U-Boot] [PATCH][v2] driver/ifc:Change accessor function to take care of endianness Prabhakar Kushwaha
2014-01-18  8:24 ` Wolfgang Denk [this message]
2014-01-20 22:51   ` Scott Wood
2014-01-21  5:42     ` Wolfgang Denk
2014-01-21  6:34       ` Wolfgang Denk
2014-01-21  6:49         ` York Sun
2014-01-21  9:14           ` Wolfgang Denk
2014-01-21 17:29             ` Scott Wood
2014-01-21 17:34               ` York Sun
2014-01-24 17:57                 ` York Sun
2014-01-21  6:51         ` Prabhakar Kushwaha
2014-02-03 20:28 ` York Sun
2014-02-03 21:35   ` Scott Wood
2014-02-03 21:36     ` York Sun

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=20140118082452.BC291380481@gemini.denx.de \
    --to=wd@denx.de \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox