All of lore.kernel.org
 help / color / mirror / Atom feed
From: Markus Brunner <super.firetwister@googlemail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] fix taihu soft spi_read
Date: Wed, 5 Mar 2008 21:38:12 +0100	[thread overview]
Message-ID: <200803052138.12861.super.firetwister@gmail.com> (raw)

The taihu board used gpio_read_out_bit which reads the output register and not 
the pin state.

Signed-off-by: Markus Brunner <super.firetwister@gmail.com>
---

The function gpio_read_out_bit didn't exist in u-boot <= 1.3.1 so every usage 
of gpio_read_out_bit deserves a closer look.

diff --git a/board/amcc/taihu/taihu.c b/board/amcc/taihu/taihu.c
index ea83671..eedde59 100644
--- a/board/amcc/taihu/taihu.c
+++ b/board/amcc/taihu/taihu.c
@@ -162,7 +162,7 @@ void spi_sda(int bit)

 unsigned char spi_read(void)
 {
-       return (unsigned char)gpio_read_out_bit(SPI_DIN_GPIO15);
+       return (unsigned char)gpio_read_in_bit(SPI_DIN_GPIO15);
 }

 void taihu_spi_chipsel(int cs)

             reply	other threads:[~2008-03-05 20:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-05 20:38 Markus Brunner [this message]
2008-03-07  8:21 ` [U-Boot-Users] [PATCH] fix taihu soft spi_read Stefan Roese

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=200803052138.12861.super.firetwister@gmail.com \
    --to=super.firetwister@googlemail.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.