From: Kishore Batta <kishore.batta@oss.qualcomm.com>
To: Manivannan Sadhasivam <mani@kernel.org>
Cc: Jonathan Corbet <corbet@lwn.net>,
Shuah Khan <skhan@linuxfoundation.org>,
Jeff Hugo <jeff.hugo@oss.qualcomm.com>,
Carl Vanderlip <carl.vanderlip@oss.qualcomm.com>,
Oded Gabbay <ogabbay@kernel.org>,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
mhi@lists.linux.dev
Subject: Re: [PATCH v6 7/7] bus: mhi: Expose DDR training data via controller sysfs
Date: Thu, 8 Oct 2026 11:42:15 +0530 [thread overview]
Message-ID: <7127ab66-7413-4f54-837d-b773b75026e9@oss.qualcomm.com> (raw)
In-Reply-To: <wkuia7mvgcwtemuib4abzjffrceekzheuyksqdzrykusxzvgxe@77ggixknltoc>
On 7/13/2026 10:38 PM, Manivannan Sadhasivam wrote:
> On Mon, Jul 13, 2026 at 01:00:27PM +0530, Kishore Batta wrote:
>> On 7/9/2026 12:27 PM, Manivannan Sadhasivam wrote:
>>> On Wed, Jul 01, 2026 at 04:07:41PM +0530, Kishore Batta wrote:
>>>> DDR training data captured during Sahara command mode needs to be
>>>> accessible to userspace so it can be persisted and reused on subsequent
>>>> boots. Currently, the training data is stored internally in the driver
>>>> but has no external visibility once the Sahara channel is torn down.
>>>>
>>>> Expose the captured DDR training data via a read-only binary sysfs
>>>> attribute on the MHI controller device:
>>>>
>>>> /sys/bus/mhi/devices/<mhi_cntrl>/ddr_training_data
>>>>
>>>> The sysfs read callback serves data directly from controller scoped storage
>>>> and protects access with the controller training data lock. The attribute
>>>> lifetime is tied to the controller device via devres, allowing the data to
>>>> remain readable after Sahara channel teardown and ensuring automatic
>>>> cleanup when controller device is removed.
>>>>
>>> If this training data is RO, then what is the use of exposing it to userspace?
>>>
>>> - Mani
>> The userspace component will read this from sysfs and save it to a file
>> named mdmddr_0x<serial_no>.mbn.
>>
> You need to mention the exact file name for the read data.
>
> - Mani
The exact filename used by userspace is mdmddr0x<serial_no>.mbn. For
example, for a device with serial number 0x12345678, userspace saves the
data as mdmddr_0x12345678.mbn. The file is stored in the corresponding
Sahara firmware directory. On the next boot, the driver first requests
this serial number specific file and falls back to the default DDR
training image if it is unavailable.
next prev parent reply other threads:[~2026-10-08 6:12 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-01 10:37 [PATCH v6 0/7] Qualcomm Sahara protocol enhancements Kishore Batta
2026-07-01 10:37 ` [PATCH v6 1/7] Add documentation for Sahara protocol Kishore Batta
2026-07-08 4:46 ` Randy Dunlap
2026-07-13 7:20 ` Kishore Batta
2026-10-08 6:10 ` Kishore Batta
2026-07-01 10:37 ` [PATCH v6 2/7] bus: mhi: Move Sahara protocol driver under MHI host client drivers Kishore Batta
2026-07-01 10:37 ` [PATCH v6 3/7] bus: mhi: Centralize Sahara firmware image table selection at probe time Kishore Batta
2026-07-01 10:37 ` [PATCH v6 4/7] bus: mhi: Add QDU100 Sahara variant and firmware fallback Kishore Batta
2026-07-09 6:19 ` Manivannan Sadhasivam
2026-07-13 7:25 ` Kishore Batta
2026-07-13 17:11 ` Manivannan Sadhasivam
2026-10-08 6:11 ` Kishore Batta
2026-07-13 14:16 ` Kishore Batta
2026-07-13 16:19 ` Manivannan Sadhasivam
2026-10-08 6:11 ` Kishore Batta
2026-07-01 10:37 ` [PATCH v6 5/7] bus: mhi: Load DDR training data using device serial number Kishore Batta
2026-07-09 6:21 ` Manivannan Sadhasivam
2026-07-13 7:27 ` Kishore Batta
2026-10-08 6:11 ` Kishore Batta
2026-07-01 10:37 ` [PATCH v6 6/7] bus: mhi: Capture DDR training data via command mode Kishore Batta
2026-07-01 10:37 ` [PATCH v6 7/7] bus: mhi: Expose DDR training data via controller sysfs Kishore Batta
2026-07-09 6:57 ` Manivannan Sadhasivam
2026-07-13 7:30 ` Kishore Batta
2026-07-13 17:08 ` Manivannan Sadhasivam
2026-10-08 6:12 ` Kishore Batta [this message]
2026-10-08 6:12 ` Kishore Batta
2026-07-22 12:22 ` Manivannan Sadhasivam
2026-10-08 6:11 ` Kishore Batta
2026-10-11 13:55 ` 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=7127ab66-7413-4f54-837d-b773b75026e9@oss.qualcomm.com \
--to=kishore.batta@oss.qualcomm.com \
--cc=carl.vanderlip@oss.qualcomm.com \
--cc=corbet@lwn.net \
--cc=dri-devel@lists.freedesktop.org \
--cc=jeff.hugo@oss.qualcomm.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mani@kernel.org \
--cc=mhi@lists.linux.dev \
--cc=ogabbay@kernel.org \
--cc=skhan@linuxfoundation.org \
/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®