bus: mhi: host: Allow configuration of bidrectional channels

Certain offload channels such as ones for satellite driver
usecases are required to be configured as bidrectional channels.
Allow it to ensure devices are created for them and the channels
are probed.

Added __attribute__((__fallthrough__)) statements to suppress
compiler error.

Change-Id: I782e3e933765099e8ee9eb1670cce321a3dffd8b
Signed-off-by: Bhaumik Bhatt <quic_bbhatt@quicinc.com>
Signed-off-by: Lazarus Motha <quic_lmotha@quicinc.com>
This commit is contained in:
Bhaumik Bhatt 2021-12-23 14:02:47 -08:00 committed by Gerrit - the friendly Code Review server
parent 48799e0f4d
commit 90fc13e213

View File

@ -380,6 +380,12 @@ void mhi_create_devices(struct mhi_controller *mhi_cntrl)
mhi_dev->ul_chan_id = mhi_chan->chan;
mhi_dev->ul_event_id = mhi_chan->er_index;
break;
case DMA_NONE:
__attribute__((__fallthrough__));
case DMA_BIDIRECTIONAL:
mhi_dev->ul_chan_id = mhi_chan->chan;
mhi_dev->ul_event_id = mhi_chan->er_index;
__attribute__((__fallthrough__));
case DMA_FROM_DEVICE:
/* We use dl_chan as offload channels */
mhi_dev->dl_chan = mhi_chan;