X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Fflash%2Fnor%2Fnon_cfi.c;h=72f11e55382a6f73b72016659f6e206c333fc53a;hb=03f46e368830c7293f83186658268a6cd4557b20;hp=9735bdbe930318724b74a78858a9999af3ba9036;hpb=08d4411b59dd8bd0e7d8009003b71d23acbf6eee;p=openocd.git diff --git a/src/flash/nor/non_cfi.c b/src/flash/nor/non_cfi.c index 9735bdbe93..72f11e5538 100644 --- a/src/flash/nor/non_cfi.c +++ b/src/flash/nor/non_cfi.c @@ -33,7 +33,7 @@ #define ERASE_REGION(num, size) (((size/256) << 16) | (num-1)) /* non-CFI compatible flashes */ -static struct non_cfi non_cfi_flashes[] = { +static const struct non_cfi non_cfi_flashes[] = { { .mfr = CFI_MFR_SST, .id = 0xd4, @@ -472,7 +472,7 @@ void cfi_fixup_non_cfi(struct flash_bank *bank) { unsigned int mask; struct cfi_flash_bank *cfi_info = bank->driver_priv; - struct non_cfi *non_cfi = non_cfi_flashes; + const struct non_cfi *non_cfi = non_cfi_flashes; if (cfi_info->x16_as_x8) mask = 0xFF;