staging: unisys: visorbus: remove return values for write_vbus functions

This patch removes the return values from the write_vbus_* channel
functions. Nobody was checking the return values and the value stored
into the vbus info is not critical to the functioning of the device.

Signed-off-by: Erik Arfvidson <erik.arfvidson@unisys.com>
Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <Timothy.Sell@unisys.com>
Acked-By: Neil Horman <nhorman@tuxdriver.com>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Erik Arfvidson 2016-06-10 21:47:59 -04:00 коммит произвёл Greg Kroah-Hartman
Родитель ec7e0a189b
Коммит ff13cf37fa
1 изменённых файлов: 18 добавлений и 15 удалений

Просмотреть файл

@ -866,9 +866,12 @@ get_vbus_header_info(struct visorchannel *chan,
/* Write the contents of <info> to the struct /* Write the contents of <info> to the struct
* spar_vbus_channel_protocol.chp_info. * spar_vbus_channel_protocol.chp_info.
*
* Returns void since this is debug information and not needed for
* device functionality.
*/ */
static int static void
write_vbus_chp_info(struct visorchannel *chan, write_vbus_chp_info(struct visorchannel *chan,
struct spar_vbus_headerinfo *hdr_info, struct spar_vbus_headerinfo *hdr_info,
struct ultra_vbus_deviceinfo *info) struct ultra_vbus_deviceinfo *info)
@ -876,18 +879,19 @@ write_vbus_chp_info(struct visorchannel *chan,
int off = sizeof(struct channel_header) + hdr_info->chp_info_offset; int off = sizeof(struct channel_header) + hdr_info->chp_info_offset;
if (hdr_info->chp_info_offset == 0) if (hdr_info->chp_info_offset == 0)
return -EFAULT; return;
if (visorchannel_write(chan, off, info, sizeof(*info)) < 0) visorchannel_write(chan, off, info, sizeof(*info));
return -EFAULT;
return 0;
} }
/* Write the contents of <info> to the struct /* Write the contents of <info> to the struct
* spar_vbus_channel_protocol.bus_info. * spar_vbus_channel_protocol.bus_info.
*
* Returns void since this is debug information and not needed for
* device functionality.
*/ */
static int static void
write_vbus_bus_info(struct visorchannel *chan, write_vbus_bus_info(struct visorchannel *chan,
struct spar_vbus_headerinfo *hdr_info, struct spar_vbus_headerinfo *hdr_info,
struct ultra_vbus_deviceinfo *info) struct ultra_vbus_deviceinfo *info)
@ -895,17 +899,18 @@ write_vbus_bus_info(struct visorchannel *chan,
int off = sizeof(struct channel_header) + hdr_info->bus_info_offset; int off = sizeof(struct channel_header) + hdr_info->bus_info_offset;
if (hdr_info->bus_info_offset == 0) if (hdr_info->bus_info_offset == 0)
return -EFAULT; return;
if (visorchannel_write(chan, off, info, sizeof(*info)) < 0) visorchannel_write(chan, off, info, sizeof(*info));
return -EFAULT;
return 0;
} }
/* Write the contents of <info> to the /* Write the contents of <info> to the
* struct spar_vbus_channel_protocol.dev_info[<devix>]. * struct spar_vbus_channel_protocol.dev_info[<devix>].
*
* Returns void since this is debug information and not needed for
* device functionality.
*/ */
static int static void
write_vbus_dev_info(struct visorchannel *chan, write_vbus_dev_info(struct visorchannel *chan,
struct spar_vbus_headerinfo *hdr_info, struct spar_vbus_headerinfo *hdr_info,
struct ultra_vbus_deviceinfo *info, int devix) struct ultra_vbus_deviceinfo *info, int devix)
@ -915,11 +920,9 @@ write_vbus_dev_info(struct visorchannel *chan,
(hdr_info->device_info_struct_bytes * devix); (hdr_info->device_info_struct_bytes * devix);
if (hdr_info->dev_info_offset == 0) if (hdr_info->dev_info_offset == 0)
return -EFAULT; return;
if (visorchannel_write(chan, off, info, sizeof(*info)) < 0) visorchannel_write(chan, off, info, sizeof(*info));
return -EFAULT;
return 0;
} }
/* For a child device just created on a client bus, fill in /* For a child device just created on a client bus, fill in