From: "Slark Xiao" <slark_xiao@163.com>
To: "Manivannan Sadhasivam" <mani@kernel.org>,
"mhi@lists.linux.dev" <mhi@lists.linux.dev>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-msm@vger.kernel.org" <linux-arm-msm@vger.kernel.org>
Subject: Concern about commit bus: mhi: host: pci_generic: Read SUBSYSTEM_VENDOR_ID for VF's to check status
Date: Wed, 27 May 2026 16:28:57 +0800 (CST) [thread overview]
Message-ID: <19ff4298.70b5.19e688d15e8.Coremail.slark_xiao@163.com> (raw)
Hi Mani,
I got a problem recently about the health_check function. It's disabled in my Thinkpad X1 Gen14.
After checking, this feature was disbaled because the commit bus: mhi: host: pci_generic: Read SUBSYSTEM_VENDOR_ID for VF's to check status.
This commit only allows the device that the value "pdev->is_physfn" is true to enable health check.
But I don't know why my PC and WWAN device would get a false result. Test result as below:
[ 3.920101] mhi-pci-generic 0000:08:00.0: MHI PCI device found: foxconn-t99w696
[ 3.920113] mhi-pci-generic 0000:08:00.0: ##debug## mhi_cntrl_config is assign
[ 3.920114] mhi-pci-generic 0000:08:00.0: ##debug## mhi_pci_claim ..
[ 3.920127] mhi-pci-generic 0000:08:00.0: enabling device (0000 -> 0002)
[ 3.920179] mhi-pci-generic 0000:08:00.0: ##debug## mhi_pci_get_irqs ..
[ 3.930223] mhi-pci-generic 0000:08:00.0: ##debug## mhi_register_controller ..
[ 3.935268] mhi-pci-generic 0000:08:00.0: ##debug## mhi_prepare_for_power_up ..
[ 3.935373] mhi-pci-generic 0000:08:00.0: ##debug## mhi_sync_power_up ..
[ 3.935375] mhi mhi0: Requested to power ON
[ 3.935388] mhi mhi0: Power on setup success
[ 3.971342] mhi-pci-generic 0000:08:00.0: pdev->is_physfn is 0
[ 3.971346] mhi-pci-generic 0000:08:00.0: pdev->is_virtfn is 0
For my situation, both pdev->is_virtfn and pdev->is_physfn are false.
And I also checked the requirement for pdev->is_physf, seems it will only be 1 if the device has SR-IOV capbility and the function is recognized as a PF. If your device is just
a regular PCIe function or the kernel does not recognize the SR-IOV capability, it will be 0.
So for mhi_pci_generic side, I suggest that we should modify it by using "!pdev->is_virtfn" instead of "pdev->is_physfn".
Thanks
next reply other threads:[~2026-05-27 8:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-27 8:28 Slark Xiao [this message]
[not found] <2441e0c7.6edc.19e6887e64f.Coremail.slark_xiao@163.com>
2026-05-27 8:43 ` Manivannan Sadhasivam
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=19ff4298.70b5.19e688d15e8.Coremail.slark_xiao@163.com \
--to=slark_xiao@163.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mani@kernel.org \
--cc=mhi@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®