From 74ac2ceb7f01095f2ce53577d0f336c8b503da03 Mon Sep 17 00:00:00 2001 From: Siddartha Mohanadoss Date: Mon, 28 Oct 2019 14:55:07 -0700 Subject: [PATCH] msm: mhi_dev: Update release function in MHI After MHI device receives a reset command the internal state machine suspends all activity on the channel and processes the device reset. Clients are notified on the channel close. Existing close function checks if there are pending data to be read but since the device is in the process of cleaning the transfer buffers and the channels are suspended this check is not required. commit msm: mhi_dev: Update release function in MHI (6772e50d7b8fc). Change-Id: Iafc5249762b1468ee2cca4ac141522ce0356d403 Signed-off-by: Siddartha Mohanadoss Signed-off-by: Manoharan Vijaya Raghavan --- net/qrtr/mhi_dev.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/net/qrtr/mhi_dev.c b/net/qrtr/mhi_dev.c index cb138d5653a5..0c45f9ade275 100644 --- a/net/qrtr/mhi_dev.c +++ b/net/qrtr/mhi_dev.c @@ -160,15 +160,9 @@ static int qrtr_mhi_dev_open_channels(struct qrtr_mhi_dev_ep *qep) static void qrtr_mhi_dev_close_channels(struct qrtr_mhi_dev_ep *qep) { - int rc; - rc = mhi_dev_close_channel(qep->in); - if (rc < 0) - dev_err(qep->dev, "failed to close in channel %d\n", rc); - - rc = mhi_dev_close_channel(qep->out); - if (rc < 0) - dev_err(qep->dev, "failed to close out channel %d\n", rc); + mhi_dev_close_channel(qep->in); + mhi_dev_close_channel(qep->out); } static void qrtr_mhi_dev_state_cb(struct mhi_dev_client_cb_data *cb_data)