[LEDE-DEV] [PATCH] kernel: fix VDSO problem on MIPS

Hauke Mehrtens hauke at hauke-m.de
Mon Aug 28 06:13:49 PDT 2017


On 08/28/2017 02:08 PM, Rafał Miłecki wrote:
> On 11 August 2017 at 00:14, Hauke Mehrtens <hauke at hauke-m.de> wrote:
>> This fixes the VDSO problems on the Lantiq VR9 MIPS SoC.
>> The gettimeofday() sometimes returned old data because of a cache
>> aliasing problems on MIPS CPUs, to work around this problem VDSO
>> gettimeofday support was deactivated for MIPS in LEDE.
>> This problem made ping show very high times like a delay of 4289967.657
>> ms.
>>
>> 1.000.000 calls to clock_gettime(CLOCK_MONOTONIC, &tp); take 1 second
>> without VDSO support and 0.35 seconds with VDSO support on Lantiq VR9.
> 
> Any comments on this? It sounds exciting to have this fixed upstream.
> 
> It seems the old patch was added in commit 1185e645a773c ("kernel:
> disable MIPS VDSO by default until the cache issues have been
> resolved").
> 
> Felix?

Hi,

For me this looks more like a hack which James suggested here:
https://www.linux-mips.org/archives/linux-mips/2017-06/msg00659.html
But I am unable to improve this, this needs too much low level MIPS
knowledge.

This fixes the problem on the Lantiq SoC, I used a version where I could
reproduce this problem, added the patch and then it was gone.

Hauke



More information about the Lede-dev mailing list