mtd: spi-nor: Constify data to write to the Status Register

Constify the data to write to the Status Register.

Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
This commit is contained in:
Tudor Ambarus 2019-10-26 13:34:00 +03:00
parent 4b3745361c
commit cc86f3e705
No known key found for this signature in database
GPG Key ID: 4B554F47A58D14E9
1 changed files with 2 additions and 2 deletions

View File

@ -787,7 +787,7 @@ static int spi_nor_wait_till_ready(struct spi_nor *nor)
* second byte will be written to the configuration register.
* Return negative if error occurred.
*/
static int spi_nor_write_sr_cr(struct spi_nor *nor, u8 *sr_cr)
static int spi_nor_write_sr_cr(struct spi_nor *nor, const u8 *sr_cr)
{
int ret;
@ -837,7 +837,7 @@ static int spi_nor_write_sr_and_check(struct spi_nor *nor, u8 status_new,
return ((nor->bouncebuf[0] & mask) != (status_new & mask)) ? -EIO : 0;
}
static int spi_nor_write_sr2(struct spi_nor *nor, u8 *sr2)
static int spi_nor_write_sr2(struct spi_nor *nor, const u8 *sr2)
{
if (nor->spimem) {
struct spi_mem_op op =