Patch "bus: ti-sysc: Flush posted write on enable and disable" has been added to the 5.7-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    bus: ti-sysc: Flush posted write on enable and disable

to the 5.7-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     bus-ti-sysc-flush-posted-write-on-enable-and-disable.patch
and it can be found in the queue-5.7 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit d9a277047500117eb5f2f92e6f7e74a903703c18
Author: Tony Lindgren <tony@xxxxxxxxxxx>
Date:   Wed May 27 06:49:29 2020 -0700

    bus: ti-sysc: Flush posted write on enable and disable
    
    [ Upstream commit 5ce8aee81be6c8bc19051d7c7b0d3cbb7ac5fc3f ]
    
    Looks like we're missing flush of posted write after module enable and
    disable. I've seen occasional errors accessing various modules, and it
    is suspected that the lack of posted writes can also cause random reboots.
    
    The errors we can see are similar to the one below from spi for example:
    
    44000000.ocp:L3 Custom Error: MASTER MPU TARGET L4CFG (Read): Data Access
    in User mode during Functional access
    ...
    mcspi_wait_for_reg_bit
    omap2_mcspi_transfer_one
    spi_transfer_one_message
    ...
    
    We also want to also flush posted write for disable. The clkctrl clock
    disable happens after module disable, and we don't want to have the
    module potentially stay active while we're trying to disable the clock.
    
    Fixes: d59b60564cbf ("bus: ti-sysc: Add generic enable/disable functions")
    Signed-off-by: Tony Lindgren <tony@xxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/bus/ti-sysc.c b/drivers/bus/ti-sysc.c
index e5f5f48d69d2f..369c97c3e0c0b 100644
--- a/drivers/bus/ti-sysc.c
+++ b/drivers/bus/ti-sysc.c
@@ -991,6 +991,9 @@ static int sysc_enable_module(struct device *dev)
 		sysc_write_sysconfig(ddata, reg);
 	}
 
+	/* Flush posted write */
+	sysc_read(ddata, ddata->offsets[SYSC_SYSCONFIG]);
+
 	if (ddata->module_enable_quirk)
 		ddata->module_enable_quirk(ddata);
 
@@ -1071,6 +1074,9 @@ static int sysc_disable_module(struct device *dev)
 		reg |= 1 << regbits->autoidle_shift;
 	sysc_write_sysconfig(ddata, reg);
 
+	/* Flush posted write */
+	sysc_read(ddata, ddata->offsets[SYSC_SYSCONFIG]);
+
 	return 0;
 }
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux