[PATCH linux v2 3/3] mtd: spi-nor: aspeed: fix DMA access on AST2500

Joel Stanley joel at jms.id.au
Fri Jan 13 19:34:42 AEDT 2017


On Wed, Jan 11, 2017 at 9:55 AM, Robert Lippert <roblip at gmail.com> wrote:
> AST2500 has additional bits in the dma_addr field.  Its easier
> to just write the full address into the register as the hardware
> will handle the masking properly.
>
> Signed-off-by: Robert Lippert <rlippert at google.com>

Applied to dev-4.7 as db7536c39879.

Cheers,

> ---
>
> Changes in v2:
> - Cleanups suggested by Cedric.
>
>  drivers/mtd/spi-nor/aspeed-smc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/spi-nor/aspeed-smc.c b/drivers/mtd/spi-nor/aspeed-smc.c
> index 3c8e897048c6..cd8a43238660 100644
> --- a/drivers/mtd/spi-nor/aspeed-smc.c
> +++ b/drivers/mtd/spi-nor/aspeed-smc.c
> @@ -349,7 +349,7 @@ static int aspeed_smc_dma_wait(struct aspeed_smc_chip *chip)
>  }
>
>  #define DMA_LENGTH(x) (((x) - 4) & ~0xFE000003)
> -#define DMA_ADDR(x) ((x) & ~0xE0000003)
> +#define DMA_ADDR(x) ((x) & ~0x00000003)
>
>  static inline void aspeed_smc_chip_configure(struct aspeed_smc_chip *chip,
>                                              u32 ctl)
> --
> 2.11.0.390.gc69c2f50cf-goog
>
> _______________________________________________
> openbmc mailing list
> openbmc at lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/openbmc


More information about the openbmc mailing list