]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
nvmem: Declare nvmem_cell_read() consistently
authorGuenter Roeck <linux@roeck-us.net>
Thu, 2 Jun 2016 11:05:12 +0000 (12:05 +0100)
committerSeth Forshee <seth.forshee@canonical.com>
Thu, 20 Oct 2016 13:06:56 +0000 (08:06 -0500)
commitf3a907ed1ef46ae0f121cc1612f41de5e434ac17
treeef9f663c8fa96ec8c316255eb3dfe69bb4922047
parent654f7d67474d2e6323692d08ba3708f8f35baa4f
nvmem: Declare nvmem_cell_read() consistently

BugLink: http://bugs.launchpad.net/bugs/1631468
commit a6c50912508d80164a5e607993b617be85a46d73 upstream.

nvmem_cell_read() is declared as void * if CONFIG_NVMEM is enabled, and
as char * otherwise. This can result in a build warning if CONFIG_NVMEM
is not enabled and a caller asigns the result to a type other than char *
without using a typecast. Use a consistent declaration to avoid the
problem.

Fixes: e2a5402ec7c6 ("nvmem: Add nvmem_device based consumer apis.")
Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
include/linux/nvmem-consumer.h