nvmem: core: remove unused nvmem_device ncells member

nvmem ncells can be over written by calling nvmem_add_cells()
multiple times. I see there is no real point of maintaining count
of cells when we have a list of cell.

Remove this to avoid any confusion!

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Srinivas Kandagatla 2018-06-26 12:36:40 +01:00 committed by Greg Kroah-Hartman
parent 26d79b820b
commit fc82975aea
1 changed files with 0 additions and 2 deletions

View File

@ -31,7 +31,6 @@ struct nvmem_device {
struct device dev;
int stride;
int word_size;
int ncells;
int id;
int users;
size_t size;
@ -389,7 +388,6 @@ int nvmem_add_cells(struct nvmem_device *nvmem,
nvmem_cell_add(cells[i]);
}
nvmem->ncells = ncells;
/* remove tmp array */
kfree(cells);