Skip to content

Commit bf30a75

Browse files
SlarkXiaoMani-Sadhasivam
authored andcommitted
bus: mhi: host: Add support for Foxconn SDX72 modems
Add support for Foxconn SDX72 based modems, T99W515 and DW5934E. Existing SDX55 channel/event configs are reused with the custom ready_timeout_ms value to workaround firmware issue. Signed-off-by: Slark Xiao <[email protected]> Reviewed-by: Manivannan Sadhasivam <[email protected]> Link: https://lore.kernel.org/r/[email protected] [mani: reworded subject and description] Signed-off-by: Manivannan Sadhasivam <[email protected]>
1 parent f08d4bd commit bf30a75

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

drivers/bus/mhi/host/pci_generic.c

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -399,6 +399,8 @@ static const struct mhi_channel_config mhi_foxconn_sdx55_channels[] = {
399399
MHI_CHANNEL_CONFIG_DL(13, "MBIM", 32, 0),
400400
MHI_CHANNEL_CONFIG_UL(32, "DUN", 32, 0),
401401
MHI_CHANNEL_CONFIG_DL(33, "DUN", 32, 0),
402+
MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
403+
MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
402404
MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0_MBIM", 128, 2),
403405
MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0_MBIM", 128, 3),
404406
};
@@ -419,6 +421,16 @@ static const struct mhi_controller_config modem_foxconn_sdx55_config = {
419421
.event_cfg = mhi_foxconn_sdx55_events,
420422
};
421423

424+
static const struct mhi_controller_config modem_foxconn_sdx72_config = {
425+
.max_channels = 128,
426+
.timeout_ms = 20000,
427+
.ready_timeout_ms = 50000,
428+
.num_channels = ARRAY_SIZE(mhi_foxconn_sdx55_channels),
429+
.ch_cfg = mhi_foxconn_sdx55_channels,
430+
.num_events = ARRAY_SIZE(mhi_foxconn_sdx55_events),
431+
.event_cfg = mhi_foxconn_sdx55_events,
432+
};
433+
422434
static const struct mhi_pci_dev_info mhi_foxconn_sdx55_info = {
423435
.name = "foxconn-sdx55",
424436
.fw = "qcom/sdx55m/sbl1.mbn",
@@ -488,6 +500,28 @@ static const struct mhi_pci_dev_info mhi_foxconn_dw5932e_info = {
488500
.sideband_wake = false,
489501
};
490502

503+
static const struct mhi_pci_dev_info mhi_foxconn_t99w515_info = {
504+
.name = "foxconn-t99w515",
505+
.edl = "fox/sdx72m/edl.mbn",
506+
.edl_trigger = true,
507+
.config = &modem_foxconn_sdx72_config,
508+
.bar_num = MHI_PCI_DEFAULT_BAR_NUM,
509+
.dma_data_width = 32,
510+
.mru_default = 32768,
511+
.sideband_wake = false,
512+
};
513+
514+
static const struct mhi_pci_dev_info mhi_foxconn_dw5934e_info = {
515+
.name = "foxconn-dw5934e",
516+
.edl = "fox/sdx72m/edl.mbn",
517+
.edl_trigger = true,
518+
.config = &modem_foxconn_sdx72_config,
519+
.bar_num = MHI_PCI_DEFAULT_BAR_NUM,
520+
.dma_data_width = 32,
521+
.mru_default = 32768,
522+
.sideband_wake = false,
523+
};
524+
491525
static const struct mhi_channel_config mhi_mv3x_channels[] = {
492526
MHI_CHANNEL_CONFIG_UL(0, "LOOPBACK", 64, 0),
493527
MHI_CHANNEL_CONFIG_DL(1, "LOOPBACK", 64, 0),
@@ -720,6 +754,15 @@ static const struct pci_device_id mhi_pci_id_table[] = {
720754
/* DW5932e (sdx62), Non-eSIM */
721755
{ PCI_DEVICE(PCI_VENDOR_ID_FOXCONN, 0xe0f9),
722756
.driver_data = (kernel_ulong_t) &mhi_foxconn_dw5932e_info },
757+
/* T99W515 (sdx72) */
758+
{ PCI_DEVICE(PCI_VENDOR_ID_FOXCONN, 0xe118),
759+
.driver_data = (kernel_ulong_t) &mhi_foxconn_t99w515_info },
760+
/* DW5934e(sdx72), With eSIM */
761+
{ PCI_DEVICE(PCI_VENDOR_ID_FOXCONN, 0xe11d),
762+
.driver_data = (kernel_ulong_t) &mhi_foxconn_dw5934e_info },
763+
/* DW5934e(sdx72), Non-eSIM */
764+
{ PCI_DEVICE(PCI_VENDOR_ID_FOXCONN, 0xe11e),
765+
.driver_data = (kernel_ulong_t) &mhi_foxconn_dw5934e_info },
723766
/* MV31-W (Cinterion) */
724767
{ PCI_DEVICE(PCI_VENDOR_ID_THALES, 0x00b3),
725768
.driver_data = (kernel_ulong_t) &mhi_mv31_info },

0 commit comments

Comments
 (0)