From patchwork Tue Jan 3 02:13:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?RHVrZSBYaW4o6L6b5a6J5paHKQ==?= X-Patchwork-Id: 13087109 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1AB70C3DA7A for ; Tue, 3 Jan 2023 02:29:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232024AbjACC34 (ORCPT ); Mon, 2 Jan 2023 21:29:56 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36698 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231634AbjACC3z (ORCPT ); Mon, 2 Jan 2023 21:29:55 -0500 Received: from m12.mail.163.com (m12.mail.163.com [123.126.96.234]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 8F0CDB7FA; Mon, 2 Jan 2023 18:29:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version: Content-Type; bh=wHR6WJBFmvZX+Tk029gO+FLBAgU+NQvxJY0m7yagDHs=; b=hLiiyXuleX6A07t+njwXNu2F/5RCMIb0+tGVd8HNjo/x60z15/efJISC332hiO po0UkB/gIy8kwCh32ajY87XBtjJFxQQYBCPm0VI28GGop8BeHQnfZJUQj+Rxcm1D aNl8rXW9PjnX5I7F5I8igHgQbXkKUyUYxWAB5yg9PIp88= Received: from ubuntu.localdomain (unknown [112.31.70.25]) by smtp18 (Coremail) with SMTP id JNxpCgB3a9tDj7NjgsSsDw--.53470S2; Tue, 03 Jan 2023 10:13:27 +0800 (CST) From: =?utf-8?b?RHVrZSBYaW4o6L6b5a6J5paHKQ==?= To: mani@kernel.org, slark_xiao@163.com Cc: loic.poulain@linaro.org, gregkh@linuxfoundation.org, dnlplm@gmail.com, yonglin.tan@outlook.com, fabio.porcedda@gmail.com, mhi@lists.linux.dev, linux-arm-msm@vger.kernel.org, inux-kernel@vger.kernel.org, jerry.meng@quectel.com, duke.xin@quectel.com, =?utf-8?b?RHVrZSBYaW4o6L6b?= =?utf-8?b?5a6J5paHKQ==?= Subject: [PATCH] bus: mhi: host: pci_generic: Add support for Quectel RM520N-GL modem Date: Mon, 2 Jan 2023 18:13:13 -0800 Message-Id: <20230103021313.124714-1-duke_xinanwen@163.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CM-TRANSID: JNxpCgB3a9tDj7NjgsSsDw--.53470S2 X-Coremail-Antispam: 1Uf129KBjvJXoW7tF1DtryfWr1kuw48KFy8Zrb_yoW8AFyrpF 4YvrWIvF4ktFW5ta97A34DGFn5uwsxury7KFnrG34IgF4qyayYqryv9F12vF4a9a95XF13 tFyrJr9xK3WqyFUanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x0pEZ2adUUUUU= X-Originating-IP: [112.31.70.25] X-CM-SenderInfo: 5gxnvsp0lqt0xzhqqiywtou0bp/1tbiVwfre1etpm7sNwAAsp Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The project is based on Qualcomm's sdx6x chips for laptop,so the mhi interface definition and enumeration align with previous Quectel sdx24 configuration Signed-off-by: Duke Xin(辛安文) --- drivers/bus/mhi/host/pci_generic.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/bus/mhi/host/pci_generic.c b/drivers/bus/mhi/host/pci_generic.c index f39657f71483..e1d697839535 100644 --- a/drivers/bus/mhi/host/pci_generic.c +++ b/drivers/bus/mhi/host/pci_generic.c @@ -335,6 +335,16 @@ static const struct mhi_pci_dev_info mhi_quectel_em1xx_info = { .sideband_wake = true, }; +static const struct mhi_pci_dev_info mhi_quectel_rm5xx_info = { + .name = "quectel-rm5xx", + .edl = "qcom/prog_firehose_sdx6x.elf", + .config = &modem_quectel_em1xx_config, + .bar_num = MHI_PCI_DEFAULT_BAR_NUM, + .dma_data_width = 32, + .mru_default = 32768, + .sideband_wake = true, +}; + static const struct mhi_channel_config mhi_foxconn_sdx55_channels[] = { MHI_CHANNEL_CONFIG_UL(0, "LOOPBACK", 32, 0), MHI_CHANNEL_CONFIG_DL(1, "LOOPBACK", 32, 0), @@ -569,6 +579,8 @@ static const struct pci_device_id mhi_pci_id_table[] = { .driver_data = (kernel_ulong_t) &mhi_quectel_em1xx_info }, { PCI_DEVICE(PCI_VENDOR_ID_QUECTEL, 0x2001), /* EM120R-GL for FCCL (sdx24) */ .driver_data = (kernel_ulong_t) &mhi_quectel_em1xx_info }, + { PCI_DEVICE(PCI_VENDOR_ID_QUECTEL, 0x1004), /* RM520N-GL (sdx6x) */ + .driver_data = (kernel_ulong_t) &mhi_quectel_rm5xx_info }, /* T99W175 (sdx55), Both for eSIM and Non-eSIM */ { PCI_DEVICE(PCI_VENDOR_ID_FOXCONN, 0xe0ab), .driver_data = (kernel_ulong_t) &mhi_foxconn_sdx55_info },