From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Subject: Re: [PATCH 2/2] net: fec_imx: fix timeout off by *1000 error
Date: Fri, 14 Dec 2018 16:29:02 +0100 [thread overview]
Message-ID: <ef23a991-be38-c018-3bf6-1940de7a3e6c@pengutronix.de> (raw)
In-Reply-To: <20181214152305.30412-2-a.fatoum@pengutronix.de>
Hello,
I didn't change read*_poll_timeout to take nanoseconds because it is copied
over from Linux.
On 14/12/18 16:23, Ahmad Fatoum wrote:
> read*_poll_timeout's final timeout parameter is in microseconds,
> but the supplied arguments in fec_imx.c were in nanoseconds,
> which might lead to barebox getting seemingly stuck in fec_halt
> (loops for a thousand seconds instead of one).
So, how about dropping the (U|M|)SECOND defines in include/clock.h and replace
them across the tree by the corresponding NSEC_PER_(U|M|)SEC?
I find them more readable and they would avoid such mistakes in future.
Cheers
Ahmad
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2018-12-14 15:29 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-14 15:23 [PATCH 1/2] include/linux/time.h: define USEC_PER_SEC and friends Ahmad Fatoum
2018-12-14 15:23 ` [PATCH 2/2] net: fec_imx: fix timeout off by *1000 error Ahmad Fatoum
2018-12-14 15:29 ` Ahmad Fatoum [this message]
2018-12-17 9:50 ` Sascha Hauer
2018-12-17 9:48 ` [PATCH 1/2] include/linux/time.h: define USEC_PER_SEC and friends Sascha Hauer
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=ef23a991-be38-c018-3bf6-1940de7a3e6c@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
/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