linux/drivers/fsi
Joel Stanley 4134cb9165 fsi: aspeed: Emit fewer barriers in opb operations
When setting up a read or write to the OPB memory space, we must perform
five or six AHB writes. The ordering of these up until the trigger write
does not matter, so use writel_relaxed.

The generated code goes from (Debian GCC 10.2.1-6):

        mov     r8, r3
        mcr     15, 0, sl, cr7, cr10, {4}
        str     sl, [r6, #20]
        mcr     15, 0, sl, cr7, cr10, {4}
        str     r3, [r6, #24]
        mcr     15, 0, sl, cr7, cr10, {4}
        str     r1, [r6, #28]
        mcr     15, 0, sl, cr7, cr10, {4}
        str     r2, [r6, #32]
        mcr     15, 0, sl, cr7, cr10, {4}
        mov     r1, #1
        str     r1, [r6, #64]   ; 0x40
        mcr     15, 0, sl, cr7, cr10, {4}
        str     r1, [r6, #4]

to this:

        str     r3, [r7, #20]
        str     r2, [r7, #24]
        str     r1, [r7, #28]
        str     r3, [r7, #64]
        mov     r8, #0
        mcr     15, 0, r8, cr7, cr10, {4}
        str     r3, [r7, #4]

Signed-off-by: Joel Stanley <joel@jms.id.au>
Acked-by: Jeremy Kerr <jk@ozlabs.org>
Reviewed-by: Eddie James <eajames@linux.ibm.com>
Tested-by: Eddie James <eajames@linux.ibm.com>
Link: https://lore.kernel.org/r/20210223041737.171274-1-joel@jms.id.au
Signed-off-by: Joel Stanley <joel@jms.id.au>
2021-06-04 14:18:17 +09:30
..
cf-fsi-fw.h fsi: cf-fsi-fw: Use the correct style for SPDX License Identifier 2019-06-19 19:35:51 +02:00
fsi-core.c fsi: core: Fix return of error values on failures 2021-06-04 14:11:48 +09:30
fsi-master-aspeed.c fsi: aspeed: Emit fewer barriers in opb operations 2021-06-04 14:18:17 +09:30
fsi-master-ast-cf.c fsi: Add missing MODULE_DEVICE_TABLE 2021-06-04 14:10:45 +09:30
fsi-master-gpio.c fsi: Add missing MODULE_DEVICE_TABLE 2021-06-04 14:10:45 +09:30
fsi-master-hub.c fsi: master: Constify hub_master_ids 2020-09-10 12:22:50 +09:30
fsi-master.h fsi: master: Add boolean parameter to link_enable function 2020-09-10 12:22:47 +09:30
fsi-occ.c fsi: Add missing MODULE_DEVICE_TABLE 2021-06-04 14:10:45 +09:30
fsi-sbefifo.c fsi: sbefifo: Constify sbefifo_ids 2020-09-10 12:22:50 +09:30
fsi-scom.c fsi: scom: Constify scom_ids 2020-09-10 12:22:51 +09:30
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile fsi: Add ast2600 master driver 2019-11-08 11:28:20 +01:00