From bd9e32efdd8f06063c9ee37dd6d0bebf535b86c1 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Mon, 15 May 2017 23:28:41 -0700 Subject: drivers/spi/spi_flash: Pass in spi_slave structure as const to probe functions Pointer to spi_slave structure can be passed in as const to spi flash probe functions since the probe functions do not need to modify the slave properties. BUG=b:38330715 Change-Id: I956ee777c62dbb811fd6ce2aeb6ae090e1892acd Signed-off-by: Furquan Shaikh Reviewed-on: https://review.coreboot.org/19707 Reviewed-by: Aaron Durbin Tested-by: build bot (Jenkins) --- src/drivers/spi/spi_flash_internal.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/drivers/spi/spi_flash_internal.h') diff --git a/src/drivers/spi/spi_flash_internal.h b/src/drivers/spi/spi_flash_internal.h index 55d3fa0c16..b42df59c7a 100644 --- a/src/drivers/spi/spi_flash_internal.h +++ b/src/drivers/spi/spi_flash_internal.h @@ -64,25 +64,25 @@ int spi_flash_cmd_erase(const struct spi_flash *flash, u32 offset, size_t len); int spi_flash_cmd_status(const struct spi_flash *flash, u8 *reg); /* Manufacturer-specific probe functions */ -int spi_flash_probe_spansion(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_spansion(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_amic(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_amic(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_atmel(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_atmel(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_eon(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_eon(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_macronix(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_macronix(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_sst(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_sst(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_stmicro(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_stmicro(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_winbond(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_winbond(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_gigadevice(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_gigadevice(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); -int spi_flash_probe_adesto(struct spi_slave *spi, u8 *idcode, +int spi_flash_probe_adesto(const struct spi_slave *spi, u8 *idcode, struct spi_flash *flash); #endif /* SPI_FLASH_INTERNAL_H */ -- cgit v1.2.3