cci: Use dsb to wait before reading status register
authorRoberto Vargas <[email protected]>
Mon, 13 Aug 2018 13:17:43 +0000 (14:17 +0100)
committerRoberto Vargas <[email protected]>
Mon, 13 Aug 2018 13:20:30 +0000 (14:20 +0100)
The CCI500 TRM explicitily requires completion of the write
operation before the read operation, and it is not guaranteed
by dmb but it is dsb.

Change-Id: Ieeaa0d1a4b8fcb87108dea9b6de03d9c8a150829
Signed-off-by: Roberto Vargas <[email protected]>
drivers/arm/cci/cci.c

index 71b65f42ce2abaab44d2eea1f1ed5b1049a7c1ab..a6ee77a50aed69391604aa570b0209d712b1bc56 100644 (file)
@@ -147,7 +147,7 @@ void cci_enable_snoop_dvm_reqs(unsigned int master_id)
         * Wait for the completion of the write to the Snoop Control Register
         * before testing the change_pending bit
         */
-       dmbish();
+       dsbish();
 
        /* Wait for the dust to settle down */
        while (mmio_read_32(cci_base + STATUS_REG) & CHANGE_PENDING_BIT)
@@ -174,7 +174,7 @@ void cci_disable_snoop_dvm_reqs(unsigned int master_id)
         * Wait for the completion of the write to the Snoop Control Register
         * before testing the change_pending bit
         */
-       dmbish();
+       dsbish();
 
        /* Wait for the dust to settle down */
        while (mmio_read_32(cci_base + STATUS_REG) & CHANGE_PENDING_BIT)