Re: memcpy() crash on x86-64 (reproducible)

From: Paulius Zaleckas
Date: Tue Mar 20 2012 - 12:17:52 EST


On Mon, Mar 19, 2012 at 11:42 AM, Paulius Zaleckas
<paulius.zaleckas@xxxxxxxxx> wrote:
> When dumping registers with 'ethtool -d <interface>' my PC freezes
> (99% reproducible).
> Only hard reset helps. My network card uses r8169 driver.
> It uses memcpy_fromio() to copy PCI space registers to buffer.
> If I change it to simple for(...) cycle with readl() it does NOT crash
> and works as expected.
>
> This happens with my work PC and the same happens on my colleagues
> identical PC with CPU:
> Intel(R) Core(TM) i7-2700K CPU @ 3.50GHz
>
> However this crash does not happen on my home PC with AMD Phenom CPU.
> It also has realtek network card and uses the same r8169 driver.
>
> I know how to compile :) and I am willing to help find and fix this bug.

I have tried different versions of memcpy available in kernel:
__memcpy() - crashes
memcpy_c() - crashes
memcpy_c_e() - works as expected
__inline_memcpy() - works as expected

About crash: actually PC freezes for ~20s, then unfreezes, but
responds very slowly and after ~1min freezes completely.
One time I was able to see dmesg output and there was
backtrace about some process stuck for too long and then
it switched to some different timing source because hpet was
unstable.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/