On Thu, Jan 13, 2022 at 02:17:18PM +0100, Jan Beulich wrote: > Except in the "clocksource=tsc" case we can replace the indirect calls > involved in accessing the platform timers by direct ones, as they get > established once and never changed. To also cover the "tsc" case, invoke > what read_tsc() resolves to directly. In turn read_tsc() then becomes > unreachable and hence can move to .init.*. > > Signed-off-by: Jan Beulich <jbeul...@suse.com>
Reviewed-by: Roger Pau Monné <roger....@citrix.com> > --- > TBD: Instead of adding __init to read_tsc() we could also ditch the > function altogether, using a dedicated (non-canonical) pointer > constant instead for the .read_counter initializer and the two > comparisons done on plt_src.read_counter. I was going to suggest adding an ASSERT_UNREACHABLE, but not sure it makes much sense if the function is init only. I would be fine with using a non-canonical pointer. Thanks, Roger.