Commit 39cd206c authored by Rafał Miłecki's avatar Rafał Miłecki Committed by John W. Linville

ssb: use const for serial flash hardware table

Signed-off-by: default avatarRafał Miłecki <zajec5@gmail.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 972da7ec
...@@ -16,7 +16,7 @@ struct ssb_sflash_tbl_e { ...@@ -16,7 +16,7 @@ struct ssb_sflash_tbl_e {
u16 numblocks; u16 numblocks;
}; };
static struct ssb_sflash_tbl_e ssb_sflash_st_tbl[] = { static const struct ssb_sflash_tbl_e ssb_sflash_st_tbl[] = {
{ "M25P20", 0x11, 0x10000, 4, }, { "M25P20", 0x11, 0x10000, 4, },
{ "M25P40", 0x12, 0x10000, 8, }, { "M25P40", 0x12, 0x10000, 8, },
...@@ -27,7 +27,7 @@ static struct ssb_sflash_tbl_e ssb_sflash_st_tbl[] = { ...@@ -27,7 +27,7 @@ static struct ssb_sflash_tbl_e ssb_sflash_st_tbl[] = {
{ 0 }, { 0 },
}; };
static struct ssb_sflash_tbl_e ssb_sflash_sst_tbl[] = { static const struct ssb_sflash_tbl_e ssb_sflash_sst_tbl[] = {
{ "SST25WF512", 1, 0x1000, 16, }, { "SST25WF512", 1, 0x1000, 16, },
{ "SST25VF512", 0x48, 0x1000, 16, }, { "SST25VF512", 0x48, 0x1000, 16, },
{ "SST25WF010", 2, 0x1000, 32, }, { "SST25WF010", 2, 0x1000, 32, },
...@@ -45,7 +45,7 @@ static struct ssb_sflash_tbl_e ssb_sflash_sst_tbl[] = { ...@@ -45,7 +45,7 @@ static struct ssb_sflash_tbl_e ssb_sflash_sst_tbl[] = {
{ 0 }, { 0 },
}; };
static struct ssb_sflash_tbl_e ssb_sflash_at_tbl[] = { static const struct ssb_sflash_tbl_e ssb_sflash_at_tbl[] = {
{ "AT45DB011", 0xc, 256, 512, }, { "AT45DB011", 0xc, 256, 512, },
{ "AT45DB021", 0x14, 256, 1024, }, { "AT45DB021", 0x14, 256, 1024, },
{ "AT45DB041", 0x1c, 256, 2048, }, { "AT45DB041", 0x1c, 256, 2048, },
...@@ -73,7 +73,7 @@ static void ssb_sflash_cmd(struct ssb_chipcommon *cc, u32 opcode) ...@@ -73,7 +73,7 @@ static void ssb_sflash_cmd(struct ssb_chipcommon *cc, u32 opcode)
/* Initialize serial flash access */ /* Initialize serial flash access */
int ssb_sflash_init(struct ssb_chipcommon *cc) int ssb_sflash_init(struct ssb_chipcommon *cc)
{ {
struct ssb_sflash_tbl_e *e; const struct ssb_sflash_tbl_e *e;
u32 id, id2; u32 id, id2;
switch (cc->capabilities & SSB_CHIPCO_CAP_FLASHT) { switch (cc->capabilities & SSB_CHIPCO_CAP_FLASHT) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment