[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK8P3a1fsC+05i-i77g2aR3bkzprnhbhROLkMPcy=UFfsV3GMw@mail.gmail.com>
Date: Tue, 12 Nov 2019 21:08:17 +0100
From: Arnd Bergmann <arnd@...db.de>
To: Takashi Iwai <tiwai@...e.de>
Cc: ALSA Development Mailing List <alsa-devel@...a-project.org>,
Takashi Iwai <tiwai@...e.com>,
Baolin Wang <baolin.wang7@...il.com>,
y2038 Mailman List <y2038@...ts.linaro.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Jaroslav Kysela <perex@...ex.cz>,
Mark Brown <broonie@...nel.org>,
Baolin Wang <baolin.wang@...aro.org>
Subject: Re: [PATCH v6 2/8] ALSA: Avoid using timespec for struct snd_timer_status
On Tue, Nov 12, 2019 at 4:42 PM Takashi Iwai <tiwai@...e.de> wrote:
> > @@ -761,6 +761,7 @@ struct snd_timer_params {
> > unsigned char reserved[60]; /* reserved */
> > };
> >
> > +#ifndef __KERNEL__
> > struct snd_timer_status {
> > struct timespec tstamp; /* Timestamp - last update */
> > unsigned int resolution; /* current period resolution in ns */
>
> Do we need this ifndef? Is it for stopping the reference of struct
> snd_timer_status from the kernel code but only 32 and 64 variants?
Well spotted, this is indeed a very recent change I did to the patch.
The idea here is to hide any use of 'time_t', 'timespec' and 'timeval'
from kernel compilation. These types are now defined in an incompatible
way by libc, so we have to remove them from the kernel's uapi headers.
I would prefer to remove them completely from the kernel (rather than
moving them from uapi to internal headers) to make it harder to write
y2038-incompatible code, and with the 90 patches I sent this week,
all users are gone from the kernel (this series was the last part).
Interestingly, hiding snd_timer_status from the drivers /also/ caught
a but in a file when I had missed a reference that needed to be converted
to snd_timer_status64.
Arnd
Powered by blists - more mailing lists