public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Bruce Adler <bruce.adler@ccpu.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] fix for "fpga load" on spartan3 in slave parallel mode
Date: Sat, 30 Jun 2007 06:01:29 -0700	[thread overview]
Message-ID: <46865429.6030905@ccpu.com> (raw)


The while loop exits too soon if the "busy" function is a dummy function
which always returns false.

diff -pur a/common/spartan3.c b/common/spartan3.c
--- a/common/spartan3.c 2007-06-30 05:15:22.000000000 -0700
+++ b/common/spartan3.c 2007-06-30 05:17:30.000000000 -0700
@@ -176,7 +176,7 @@ static int Spartan3_sp_load (Xilinx_desc
                                 "read data:\t0x%p\n"
                                 "write data:\t0x%p\n"
                                 "busy:\t0x%p\n"
-                               "abort:\t0x%p\n",
+                               "abort:\t0x%p\n"
                                 "post:\t0x%p\n\n",
                                 __FUNCTION__, &fn, fn, fn->pre, fn->pgm, fn->init, fn->err,
                                 fn->clk, fn->cs, fn->wr, fn->rdata, fn->wdata, fn->busy,
@@ -213,7 +213,7 @@ static int Spartan3_sp_load (Xilinx_desc
                                 (*fn->abort) (cookie);  /* abort the burn */
                                 return FPGA_FAIL;
                         }
-               } while ((*fn->init) (cookie) && (*fn->busy) (cookie));
+               } while ((*fn->init) (cookie) || (*fn->busy) (cookie));

                 (*fn->wr) (TRUE, TRUE, cookie); /* Assert write, commit */
                 (*fn->cs) (TRUE, TRUE, cookie); /* Assert chip select, commit */

             reply	other threads:[~2007-06-30 13:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-30 13:01 Bruce Adler [this message]
2007-07-01 13:02 ` [U-Boot-Users] [PATCH] fix for "fpga load" on spartan3 in slave parallel mode Grant Likely

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=46865429.6030905@ccpu.com \
    --to=bruce.adler@ccpu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox