Commit 526740b4 authored by Kalle Valo's avatar Kalle Valo

Merge mhi-ath11k-immutable into ath-next

This is an immutable branch from mhi tree for handling an API change in MHI
subsystem and minimise conflicts between ath and mhi trees.
parents 11af6de4 2ca7e30d
...@@ -758,7 +758,6 @@ static int parse_ch_cfg(struct mhi_controller *mhi_cntrl, ...@@ -758,7 +758,6 @@ static int parse_ch_cfg(struct mhi_controller *mhi_cntrl,
mhi_chan->offload_ch = ch_cfg->offload_channel; mhi_chan->offload_ch = ch_cfg->offload_channel;
mhi_chan->db_cfg.reset_req = ch_cfg->doorbell_mode_switch; mhi_chan->db_cfg.reset_req = ch_cfg->doorbell_mode_switch;
mhi_chan->pre_alloc = ch_cfg->auto_queue; mhi_chan->pre_alloc = ch_cfg->auto_queue;
mhi_chan->auto_start = ch_cfg->auto_start;
/* /*
* If MHI host allocates buffers, then the channel direction * If MHI host allocates buffers, then the channel direction
...@@ -1160,11 +1159,6 @@ static int mhi_driver_probe(struct device *dev) ...@@ -1160,11 +1159,6 @@ static int mhi_driver_probe(struct device *dev)
goto exit_probe; goto exit_probe;
ul_chan->xfer_cb = mhi_drv->ul_xfer_cb; ul_chan->xfer_cb = mhi_drv->ul_xfer_cb;
if (ul_chan->auto_start) {
ret = mhi_prepare_channel(mhi_cntrl, ul_chan);
if (ret)
goto exit_probe;
}
} }
ret = -EINVAL; ret = -EINVAL;
...@@ -1198,9 +1192,6 @@ static int mhi_driver_probe(struct device *dev) ...@@ -1198,9 +1192,6 @@ static int mhi_driver_probe(struct device *dev)
if (ret) if (ret)
goto exit_probe; goto exit_probe;
if (dl_chan && dl_chan->auto_start)
mhi_prepare_channel(mhi_cntrl, dl_chan);
mhi_device_put(mhi_dev); mhi_device_put(mhi_dev);
return ret; return ret;
......
...@@ -563,7 +563,6 @@ struct mhi_chan { ...@@ -563,7 +563,6 @@ struct mhi_chan {
bool configured; bool configured;
bool offload_ch; bool offload_ch;
bool pre_alloc; bool pre_alloc;
bool auto_start;
bool wake_capable; bool wake_capable;
}; };
......
...@@ -24,7 +24,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = { ...@@ -24,7 +24,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = {
.offload_channel = false, .offload_channel = false,
.doorbell_mode_switch = false, .doorbell_mode_switch = false,
.auto_queue = false, .auto_queue = false,
.auto_start = false,
}, },
{ {
.num = 1, .num = 1,
...@@ -39,7 +38,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = { ...@@ -39,7 +38,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = {
.offload_channel = false, .offload_channel = false,
.doorbell_mode_switch = false, .doorbell_mode_switch = false,
.auto_queue = false, .auto_queue = false,
.auto_start = false,
}, },
{ {
.num = 20, .num = 20,
...@@ -54,7 +52,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = { ...@@ -54,7 +52,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = {
.offload_channel = false, .offload_channel = false,
.doorbell_mode_switch = false, .doorbell_mode_switch = false,
.auto_queue = false, .auto_queue = false,
.auto_start = true,
}, },
{ {
.num = 21, .num = 21,
...@@ -69,7 +66,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = { ...@@ -69,7 +66,6 @@ static struct mhi_channel_config ath11k_mhi_channels[] = {
.offload_channel = false, .offload_channel = false,
.doorbell_mode_switch = false, .doorbell_mode_switch = false,
.auto_queue = true, .auto_queue = true,
.auto_start = true,
}, },
}; };
......
...@@ -214,7 +214,6 @@ enum mhi_db_brst_mode { ...@@ -214,7 +214,6 @@ enum mhi_db_brst_mode {
* @offload_channel: The client manages the channel completely * @offload_channel: The client manages the channel completely
* @doorbell_mode_switch: Channel switches to doorbell mode on M0 transition * @doorbell_mode_switch: Channel switches to doorbell mode on M0 transition
* @auto_queue: Framework will automatically queue buffers for DL traffic * @auto_queue: Framework will automatically queue buffers for DL traffic
* @auto_start: Automatically start (open) this channel
* @wake-capable: Channel capable of waking up the system * @wake-capable: Channel capable of waking up the system
*/ */
struct mhi_channel_config { struct mhi_channel_config {
...@@ -232,7 +231,6 @@ struct mhi_channel_config { ...@@ -232,7 +231,6 @@ struct mhi_channel_config {
bool offload_channel; bool offload_channel;
bool doorbell_mode_switch; bool doorbell_mode_switch;
bool auto_queue; bool auto_queue;
bool auto_start;
bool wake_capable; bool wake_capable;
}; };
......
...@@ -76,6 +76,11 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev, ...@@ -76,6 +76,11 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev,
struct qrtr_mhi_dev *qdev; struct qrtr_mhi_dev *qdev;
int rc; int rc;
/* start channels */
rc = mhi_prepare_for_transfer(mhi_dev);
if (rc)
return rc;
qdev = devm_kzalloc(&mhi_dev->dev, sizeof(*qdev), GFP_KERNEL); qdev = devm_kzalloc(&mhi_dev->dev, sizeof(*qdev), GFP_KERNEL);
if (!qdev) if (!qdev)
return -ENOMEM; return -ENOMEM;
...@@ -99,6 +104,7 @@ static void qcom_mhi_qrtr_remove(struct mhi_device *mhi_dev) ...@@ -99,6 +104,7 @@ static void qcom_mhi_qrtr_remove(struct mhi_device *mhi_dev)
struct qrtr_mhi_dev *qdev = dev_get_drvdata(&mhi_dev->dev); struct qrtr_mhi_dev *qdev = dev_get_drvdata(&mhi_dev->dev);
qrtr_endpoint_unregister(&qdev->ep); qrtr_endpoint_unregister(&qdev->ep);
mhi_unprepare_from_transfer(mhi_dev);
dev_set_drvdata(&mhi_dev->dev, NULL); dev_set_drvdata(&mhi_dev->dev, NULL);
} }
......
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