Commit ad44088f authored by Jes Sorensen's avatar Jes Sorensen Committed by Greg Kroah-Hartman

staging: unisys: visorchannel_write(): Use memcpy_toio() directly

Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarBenjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d24c3f07
......@@ -216,10 +216,15 @@ visorchannel_write(struct visorchannel *channel, ulong offset,
{
size_t size = sizeof(struct channel_header);
if (offset + nbytes > channel->memregion.nbytes)
return -EIO;
if (!offset && nbytes >= size)
memcpy(&channel->chan_hdr, local, size);
return visor_memregion_write(&channel->memregion,
offset, local, nbytes);
memcpy_toio(channel->memregion.mapped + offset, local, nbytes);
return 0;
}
EXPORT_SYMBOL_GPL(visorchannel_write);
......
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