浏览代码

MIPS: Warn if vector register partitioning is implemented

No current systems implementing MSA include support for vector register
partitioning which makes it somewhat difficult to implement support for
it in the kernel. Thus for the moment the kernel includes no such
support. However if the kernel were to be run on a system which
implemented register partitioning then it would not function correctly,
mishandling MSA disabled exceptions. Print a warning if run on a system
with vector register partitioning implemented to indicate this problem
should it occur.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/6494/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Paul Burton 11 年之前
父节点
当前提交
a8ad136789
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      arch/mips/kernel/cpu-probe.c

+ 4 - 1
arch/mips/kernel/cpu-probe.c

@@ -1195,8 +1195,11 @@ void cpu_probe(void)
 	else
 	else
 		c->srsets = 1;
 		c->srsets = 1;
 
 
-	if (cpu_has_msa)
+	if (cpu_has_msa) {
 		c->msa_id = cpu_get_msa_id();
 		c->msa_id = cpu_get_msa_id();
+		WARN(c->msa_id & MSA_IR_WRPF,
+		     "Vector register partitioning unimplemented!");
+	}
 
 
 	cpu_probe_vmbits(c);
 	cpu_probe_vmbits(c);