ipq5018: block_drvr const declared only on HAVE_BLOCK_DEVICE

1. Modified to the declare block_drvr struct and const variable
only on HAVE_BLOCK_DEVICE config enabled.
2. Removed unused const training_block_128

Signed-off-by: Karthick Shanmugham <kartshan@codeaurora.org>
Change-Id: Icfe05aec82a124429443aadf735767366b168d6b
This commit is contained in:
Karthick Shanmugham 2020-10-07 12:56:47 +05:30
parent ac3c252cf1
commit b6d6a4aa72
2 changed files with 3 additions and 14 deletions

View file

@ -20,6 +20,9 @@
#define PRINTF(fmt,args...)
#endif
DECLARE_GLOBAL_DATA_PTR;
#ifdef HAVE_BLOCK_DEVICE
struct block_drvr {
char *name;
block_dev_desc_t* (*get_dev)(int dev);
@ -55,9 +58,6 @@ static const struct block_drvr block_drvr[] = {
{ },
};
DECLARE_GLOBAL_DATA_PTR;
#ifdef HAVE_BLOCK_DEVICE
static block_dev_desc_t *get_dev_hwpart(const char *ifname, int dev, int hwpart)
{
const struct block_drvr *drvr = block_drvr;

View file

@ -128,17 +128,6 @@ static const unsigned int training_block_64[] = {
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
};
static const unsigned int training_block_128[] = {
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F, 0x0F0F0F0F,
};
#define TRAINING_PART_OFFSET 0x3c00000
#define MAXIMUM_ALLOCATED_TRAINING_BLOCK 4
#define TOTAL_NUM_PHASE 7