All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@xilinx.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] common: Fix logic in fpga programming
Date: Fri, 16 Dec 2016 10:53:29 +0100	[thread overview]
Message-ID: <34887b83-74fa-43be-d536-33169bcf8058@xilinx.com> (raw)
In-Reply-To: <01a805b5-9603-dc1c-bbc4-c08fae0106c4@topic.nl>

On 16.12.2016 10:50, Mike Looijmans wrote:
> On 16-12-16 10:45, Michal Simek wrote:
>> Stop boot process if fpga programming fails.
>>
>> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
>> ---
>>
>>  common/image.c | 7 +++----
>>  1 file changed, 3 insertions(+), 4 deletions(-)
>>
>> diff --git a/common/image.c b/common/image.c
>> index bd07e86701a4..e3486e46a459 100644
>> --- a/common/image.c
>> +++ b/common/image.c
>> @@ -1375,11 +1375,10 @@ int boot_get_fpga(int argc, char * const
>> argv[], bootm_headers_t *images,
>>                          img_len, BIT_PARTIAL);
>>          }
>>
>> -        printf("   Programming %s bitstream... ", name);
>>          if (err)
>> -            printf("failed\n");
>> -        else
>> -            printf("OK\n");
>> +            return 1;
> 
> Wouldn't "return err;" or "return -EIO;" make sense here instead of a
> magic "1"?

Good idea. Will send v2

Thanks,
Michal

  reply	other threads:[~2016-12-16  9:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-16  9:45 [U-Boot] [PATCH] common: Fix logic in fpga programming Michal Simek
2016-12-16  9:50 ` Mike Looijmans
2016-12-16  9:53   ` Michal Simek [this message]
2016-12-20 17:30 ` Wolfgang Denk
2016-12-20 18:01   ` Michal Simek
2016-12-20 23:19     ` Wolfgang Denk
2016-12-21  7:03       ` Michal Simek

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=34887b83-74fa-43be-d536-33169bcf8058@xilinx.com \
    --to=michal.simek@xilinx.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.