Re: [PATCH v5 1/2] sched/clock: interface to allow timestamps early in boot
From: Thomas Gleixner
Date: Mon Aug 28 2017 - 11:15:37 EST
On Mon, 28 Aug 2017, Pasha Tatashin wrote:
> > > +/*
> > > + * Called once during to boot to initialize boot time.
> > > + */
> > > +void read_boot_clock64(struct timespec64 *ts)
> >
> > And because its called only once, it does not need to be marked __init()
> > and must be kept around forever, right?
>
> This is because every other architecture implements read_boot_clock64()
> without __init: arm, s390. Beside, the original weak stub does not have __init
> macro. So, I can certainly try to add it for x86, but I am not sure what is
> the behavior once __init section is gone, but weak implementation stays.
And what about fixing that everywhere?
Just because something is wrong, it does not mean that it needs to be
proliferated.
Thanks,
tglx