ARC: Fix detection of dual-issue enabled
authorAlexey Brodkin <Alexey.Brodkin@synopsys.com>
Thu, 23 Nov 2017 10:21:55 +0000 (13:21 +0300)
committerVineet Gupta <vgupta@synopsys.com>
Wed, 29 Nov 2017 02:12:07 +0000 (18:12 -0800)
As per PRM bit #0 ("D") in EXEC_CTRL enables dual-issue if set to 0,
otherwise if set to 1 all instructions are executed one at a time,
i.e. dual-issue is disabled.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
arch/arc/kernel/setup.c

index 7ef7d9a..9d27331 100644 (file)
@@ -199,7 +199,7 @@ static void read_arc_build_cfg_regs(void)
                        unsigned int exec_ctrl;
 
                        READ_BCR(AUX_EXEC_CTRL, exec_ctrl);
-                       cpu->extn.dual_enb = exec_ctrl & 1;
+                       cpu->extn.dual_enb = !(exec_ctrl & 1);
 
                        /* dual issue always present for this core */
                        cpu->extn.dual = 1;