summaryrefslogtreecommitdiff
path: root/drivers/misc/mei/amthif.c
diff options
context:
space:
mode:
authorAlexander Usyskin <alexander.usyskin@intel.com>2015-05-04 06:43:58 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-05-24 18:13:48 (GMT)
commit9e23936279ad339bb1eeb73d298d95b4d986459e (patch)
treeb6954da1cccb18c4b1a798e3ab7650bfcbde9d34 /drivers/misc/mei/amthif.c
parenteeabfcf5a92ae3316b23f2da6a2bb5ba60a1b072 (diff)
downloadlinux-9e23936279ad339bb1eeb73d298d95b4d986459e.tar.xz
mei: drop iamthif_mtu from device structure
We can receive mtu with one call now, no need to store it. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/amthif.c')
-rw-r--r--drivers/misc/mei/amthif.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/misc/mei/amthif.c b/drivers/misc/mei/amthif.c
index 3c69616..1e42781 100644
--- a/drivers/misc/mei/amthif.c
+++ b/drivers/misc/mei/amthif.c
@@ -72,12 +72,6 @@ int mei_amthif_host_init(struct mei_device *dev, struct mei_me_client *me_cl)
mei_cl_init(cl, dev);
- /* Assign iamthif_mtu to the value received from ME */
-
- dev->iamthif_mtu = me_cl->props.max_msg_length;
- dev_dbg(dev->dev, "IAMTHIF_MTU = %d\n", dev->iamthif_mtu);
-
-
ret = mei_cl_link(cl, MEI_IAMTHIF_HOST_CLIENT_ID);
if (ret < 0) {
dev_err(dev->dev, "amthif: failed cl_link %d\n", ret);
@@ -239,7 +233,6 @@ static int mei_amthif_read_start(struct mei_cl *cl, struct file *file)
{
struct mei_device *dev = cl->dev;
struct mei_cl_cb *cb;
- size_t length = dev->iamthif_mtu;
int rets;
cb = mei_io_cb_init(cl, MEI_FOP_READ, file);
@@ -248,7 +241,7 @@ static int mei_amthif_read_start(struct mei_cl *cl, struct file *file)
goto err;
}
- rets = mei_io_cb_alloc_buf(cb, length);
+ rets = mei_io_cb_alloc_buf(cb, mei_cl_mtu(cl));
if (rets)
goto err;