* [PATCH] net: dns_resolver: convert time_t to time64_t
@ 2015-11-18 6:36 Aya Mahfouz
2015-11-18 20:20 ` David Miller
0 siblings, 1 reply; 5+ messages in thread
From: Aya Mahfouz @ 2015-11-18 6:36 UTC (permalink / raw)
To: David S. Miller, Arnd Bergmann, David Howells, linux-kernel,
netdev
Changes the definition of the pointer _expiry from time_t to
time64_t. This is to handle the Y2038 problem where time_t
will overflow in the year 2038. The change is safe because
the kernel subsystems that call dns_query pass NULL.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
---
Changelog:
v1: The changes were originally made by Arnd Bergmann in
relation to time_t. I've broken down a patch sent to me
into two independent patches.
include/linux/dns_resolver.h | 2 +-
net/dns_resolver/dns_query.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/dns_resolver.h b/include/linux/dns_resolver.h
index cc92268..6ac3cad 100644
--- a/include/linux/dns_resolver.h
+++ b/include/linux/dns_resolver.h
@@ -27,7 +27,7 @@
#ifdef __KERNEL__
extern int dns_query(const char *type, const char *name, size_t namelen,
- const char *options, char **_result, time_t *_expiry);
+ const char *options, char **_result, time64_t *_expiry);
#endif /* KERNEL */
diff --git a/net/dns_resolver/dns_query.c b/net/dns_resolver/dns_query.c
index 4677b6f..ecc28cf 100644
--- a/net/dns_resolver/dns_query.c
+++ b/net/dns_resolver/dns_query.c
@@ -67,7 +67,7 @@
* Returns the size of the result on success, -ve error code otherwise.
*/
int dns_query(const char *type, const char *name, size_t namelen,
- const char *options, char **_result, time_t *_expiry)
+ const char *options, char **_result, time64_t *_expiry)
{
struct key *rkey;
const struct user_key_payload *upayload;
--
2.4.3
--
Kind Regards,
Aya Saif El-yazal Mahfouz
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] net: dns_resolver: convert time_t to time64_t
2015-11-18 6:36 [PATCH] net: dns_resolver: convert time_t to time64_t Aya Mahfouz
@ 2015-11-18 20:20 ` David Miller
2015-11-18 21:08 ` Arnd Bergmann
2015-11-18 22:27 ` David Howells
0 siblings, 2 replies; 5+ messages in thread
From: David Miller @ 2015-11-18 20:20 UTC (permalink / raw)
To: mahfouz.saif.elyazal; +Cc: arnd, dhowells, linux-kernel, netdev
From: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
Date: Wed, 18 Nov 2015 08:36:44 +0200
> Changes the definition of the pointer _expiry from time_t to
> time64_t. This is to handle the Y2038 problem where time_t
> will overflow in the year 2038. The change is safe because
> the kernel subsystems that call dns_query pass NULL.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
> ---
> Changelog:
> v1: The changes were originally made by Arnd Bergmann in
> relation to time_t. I've broken down a patch sent to me
> into two independent patches.
Want me to apply this to 'net'?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] net: dns_resolver: convert time_t to time64_t
2015-11-18 20:20 ` David Miller
@ 2015-11-18 21:08 ` Arnd Bergmann
2015-11-18 21:30 ` David Miller
2015-11-18 22:27 ` David Howells
1 sibling, 1 reply; 5+ messages in thread
From: Arnd Bergmann @ 2015-11-18 21:08 UTC (permalink / raw)
To: David Miller; +Cc: mahfouz.saif.elyazal, dhowells, linux-kernel, netdev
On Wednesday 18 November 2015 15:20:25 David Miller wrote:
> From: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
> Date: Wed, 18 Nov 2015 08:36:44 +0200
>
> > Changes the definition of the pointer _expiry from time_t to
> > time64_t. This is to handle the Y2038 problem where time_t
> > will overflow in the year 2038. The change is safe because
> > the kernel subsystems that call dns_query pass NULL.
> >
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
> > ---
> > Changelog:
> > v1: The changes were originally made by Arnd Bergmann in
> > relation to time_t. I've broken down a patch sent to me
> > into two independent patches.
>
> Want me to apply this to 'net'?
Yes, I think that would be good. The original patch was touching
both the key and net subsystems, but this patch makes sense by itself
now, and it helps keep the other half isolated to the key code.
Arnd
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] net: dns_resolver: convert time_t to time64_t
2015-11-18 21:08 ` Arnd Bergmann
@ 2015-11-18 21:30 ` David Miller
0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2015-11-18 21:30 UTC (permalink / raw)
To: arnd; +Cc: mahfouz.saif.elyazal, dhowells, linux-kernel, netdev
From: Arnd Bergmann <arnd@arndb.de>
Date: Wed, 18 Nov 2015 22:08:54 +0100
> On Wednesday 18 November 2015 15:20:25 David Miller wrote:
>> From: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
>> Date: Wed, 18 Nov 2015 08:36:44 +0200
>>
>> > Changes the definition of the pointer _expiry from time_t to
>> > time64_t. This is to handle the Y2038 problem where time_t
>> > will overflow in the year 2038. The change is safe because
>> > the kernel subsystems that call dns_query pass NULL.
>> >
>> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>> > Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
>> > ---
>> > Changelog:
>> > v1: The changes were originally made by Arnd Bergmann in
>> > relation to time_t. I've broken down a patch sent to me
>> > into two independent patches.
>>
>> Want me to apply this to 'net'?
>
> Yes, I think that would be good. The original patch was touching
> both the key and net subsystems, but this patch makes sense by itself
> now, and it helps keep the other half isolated to the key code.
OK, it sounds like we can simply delete the argument if nobody in-tree
uses it.
But whatever... applied thanks.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] net: dns_resolver: convert time_t to time64_t
2015-11-18 20:20 ` David Miller
2015-11-18 21:08 ` Arnd Bergmann
@ 2015-11-18 22:27 ` David Howells
1 sibling, 0 replies; 5+ messages in thread
From: David Howells @ 2015-11-18 22:27 UTC (permalink / raw)
To: David Miller; +Cc: dhowells, mahfouz.saif.elyazal, arnd, linux-kernel, netdev
David Miller <davem@davemloft.net> wrote:
> From: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
> Date: Wed, 18 Nov 2015 08:36:44 +0200
>
> > Changes the definition of the pointer _expiry from time_t to
> > time64_t. This is to handle the Y2038 problem where time_t
> > will overflow in the year 2038. The change is safe because
> > the kernel subsystems that call dns_query pass NULL.
> >
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
> > ---
> > Changelog:
> > v1: The changes were originally made by Arnd Bergmann in
> > relation to time_t. I've broken down a patch sent to me
> > into two independent patches.
>
> Want me to apply this to 'net'?
Fine by me.
Acked-by: David Howells <dhowells@redhat.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-11-18 22:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-18 6:36 [PATCH] net: dns_resolver: convert time_t to time64_t Aya Mahfouz
2015-11-18 20:20 ` David Miller
2015-11-18 21:08 ` Arnd Bergmann
2015-11-18 21:30 ` David Miller
2015-11-18 22:27 ` David Howells
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).