Re: [PATCH] TX49 MFC0 bug workaround

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Ralf Baechle wrote:

Workaround: mask EXL bit of the result or place a nop before mfc0.

[...]

@@ -55,8 +56,13 @@ __asm__ (
	"	di							\n"
#else
	"	mfc0	$1,$12						\n"
+#if TX49XX_MFC0_WAR && defined(MODULE)
+	"	ori	$1,3						\n"
+	"	xori	$1,3						\n"
+#else
	"	ori	$1,1						\n"
	"	xori	$1,1						\n"
+#endif
	"	.set	noreorder					\n"
	"	mtc0	$1,$12						\n"
#endif

Hmm, wouldn't that "nop" alternative be simpler?

Simpler maybe - but this variant has zero runtime overhead.

And.. how do you imagine placing a NOP (which surely just moves MFC0 down so that it's a 1st insn. on the next page). What if it'll move it to the errata prone address from a safe one instead?

WBR, Sergei


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux