From: Arnd Bergmann <arnd@arndb.de>
To: outreachy-kernel@googlegroups.com
Cc: Deepa Dinamani <deepa.kernel@gmail.com>, y2038@lists.linaro.org
Subject: Re: [Outreachy kernel] Re: [Y2038] [PATCH] staging: ft1000: replace timeval with ktime_t
Date: Sat, 17 Oct 2015 00:57:45 +0200 [thread overview]
Message-ID: <9822706.yKCeF9F5MV@wuerfel> (raw)
In-Reply-To: <CABeXuvrTDkfM=2umfNcoyATN866zWQ2ed-VspCyn-xC846e1nw@mail.gmail.com>
On Friday 16 October 2015 15:53:04 Deepa Dinamani wrote:
> Forgot to do reply-all earlier.
>
> Resending.
>
> I considered using the ktime_get_seconds() earlier.
> However, I'm not convinced that the driver actually needs time in seconds.
> It would be hard to guess given that I'm not actually running this on a
> platform.
> So I used ktime_get() instead so that when the driver gets cleaned up
> later, it can be updated to use correct time granularity.
>
> Given that sometimes they could end up calculating time from epoch seems to
> hint that there is more cleanup required on the driver.
>
> Do you think this is reasonable?
>
The driver only uses the time in one place, which is the ioctl function
returning the connection time in seconds, and this is a debugging
interface.
From this, we know that there is little value in using a more accurate
time representation. Your approach gives us better rounding, but it
won't really matter as the connection time for a wireless connection
is not interesting in the low seconds anyway.
Regarding future cleanups, you should not introduce features just
because you think they might be used later: Code is easy to change,
so if someone needs the higher resolution, they can change it then.
In this case, it's particularly unlikely to change, as the only
user is in an ioctl. Making a change to that interface would break
existing binaries, so we don't want that.
A more likely cleanup would be the removal of the debug interface,
replacing it with something completely different.
Arnd
next prev parent reply other threads:[~2015-10-16 22:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-15 0:43 [PATCH] staging: ft1000: replace timeval with ktime_t Deepa Dinamani
2015-10-16 22:14 ` [Y2038] " Arnd Bergmann
2015-10-16 22:53 ` [Outreachy kernel] " Deepa Dinamani
2015-10-16 22:57 ` Arnd Bergmann [this message]
2015-10-16 23:30 ` [Y2038] [Outreachy kernel] " Arnd Bergmann
2015-10-17 0:32 ` Deepa Dinamani
2015-10-17 5:55 ` Greg KH
2015-10-17 11:29 ` Arnd Bergmann
2015-10-17 18:23 ` Deepa Dinamani
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=9822706.yKCeF9F5MV@wuerfel \
--to=arnd@arndb.de \
--cc=deepa.kernel@gmail.com \
--cc=outreachy-kernel@googlegroups.com \
--cc=y2038@lists.linaro.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 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.