From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] sf: fix timebase data type in _wait_ready()
Date: Wed, 20 Apr 2016 23:49:01 -0600 [thread overview]
Message-ID: <571869CD.9090708@wwwdotorg.org> (raw)
In-Reply-To: <CAD6G_RQvVvk2peDDCc1sKmApoKX20rBOysnRgx-mqbGRGDTbVQ@mail.gmail.com>
On 04/06/2016 05:22 AM, Jagan Teki wrote:
> On 5 April 2016 at 05:31, Tom Rini <trini@konsulko.com> wrote:
>> On Mon, Apr 04, 2016 at 11:03:52AM -0600, Stephen Warren wrote:
>>
>>> From: Stephen Warren <swarren@nvidia.com>
>>>
>>> get_timer() returns an unsigned 64-bit value, but is currently assigned to
>>> a signed 32-bit variable. Due to sign extension and data truncation, this
>>> causes the timeout loop in spi_flash_cmd_wait_ready() to immediately (and
>>> incorrectly) fire for about 50% of all time values, based on whether bit
>>> 31 is set. In sandbox at least, this causes the test to pass or fail based
>>> on system uptime, as opposed to time since the U-Boot binary was started.
>>>
>>> Fixes: 4efad20a1751 ("sf: Update status reg check in spi_flash_cmd_wait_ready")
>>> Signed-off-by: Stephen Warren <swarren@nvidia.com>
>>
>> Reviewed-by: Tom Rini <trini@konsulko.com>
>
> Reviewed-by: Jagan Teki <jteki@openedev.com>
Jagan, are you going to apply this?
next prev parent reply other threads:[~2016-04-21 5:49 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-04 17:03 [U-Boot] [PATCH] sf: fix timebase data type in _wait_ready() Stephen Warren
2016-04-05 0:01 ` Tom Rini
2016-04-06 11:22 ` Jagan Teki
2016-04-12 15:43 ` Stephen Warren
2016-04-12 16:03 ` Tom Rini
2016-04-21 5:49 ` Stephen Warren [this message]
2016-04-25 16:44 ` Stephen Warren
2016-04-25 16:46 ` Tom Rini
2016-04-26 0:16 ` [U-Boot] " Tom Rini
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=571869CD.9090708@wwwdotorg.org \
--to=swarren@wwwdotorg.org \
--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