Commit fc82975a authored by Srinivas Kandagatla's avatar Srinivas Kandagatla Committed by Greg Kroah-Hartman

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: default avatarSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 26d79b82
...@@ -31,7 +31,6 @@ struct nvmem_device { ...@@ -31,7 +31,6 @@ struct nvmem_device {
struct device dev; struct device dev;
int stride; int stride;
int word_size; int word_size;
int ncells;
int id; int id;
int users; int users;
size_t size; size_t size;
...@@ -389,7 +388,6 @@ int nvmem_add_cells(struct nvmem_device *nvmem, ...@@ -389,7 +388,6 @@ int nvmem_add_cells(struct nvmem_device *nvmem,
nvmem_cell_add(cells[i]); nvmem_cell_add(cells[i]);
} }
nvmem->ncells = ncells;
/* remove tmp array */ /* remove tmp array */
kfree(cells); kfree(cells);
......
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