Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mmc: Add quirk to disable DDR50 tuning #213

Draft
wants to merge 3 commits into
base: nilrt/master/6.6
Choose a base branch
from

Conversation

erickshepherdNI
Copy link
Contributor

@erickshepherdNI erickshepherdNI commented Mar 12, 2025

Adds the MMC_QUIRK_NO_UHS_DDR50_TUNING quirk and updates
mmc_execute_tuning() to return 0 if that quirk is set. This fixes an
issue on certain Swissbit SD cards that do not support DDR50 tuning
where tuning requests caused I/O errors to be thrown.

WI#2805437

Testing

Built the kernel and confirmed that the SD card attempts to tune but is stopped by the new change. No I/O errors were thrown.

Copy link
Contributor

@chaitu236 chaitu236 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes lgtm. But please add WI# to PR description and rebase to latest nilrt/master/6.6.

Btw, did you end up testing on other controllers? What were the findings?

@erickshepherdNI erickshepherdNI force-pushed the ershephe/tuning-quirk-fix branch 2 times, most recently from cbcc07b to a7f92a6 Compare March 12, 2025 20:09
@erickshepherdNI
Copy link
Contributor Author

Changes lgtm. But please add WI# to PR description and rebase to latest nilrt/master/6.6.

Btw, did you end up testing on other controllers? What were the findings?

I updated the PR description and rebased the changes. as far as other testing, I was not able to reproduce the issue on a 9034 with the same Swissbit card. I'd be curious to test on more hardware configurations but this change should be ok since the card doesn't support tuning anyway.

@chaitu236
Copy link
Contributor

Changes lgtm. But please add WI# to PR description and rebase to latest nilrt/master/6.6.
Btw, did you end up testing on other controllers? What were the findings?

I updated the PR description and rebased the changes. as far as other testing, I was not able to reproduce the issue on a 9034 with the same Swissbit card. I'd be curious to test on more hardware configurations but this change should be ok since the card doesn't support tuning anyway.

I see. Did we get the info about it's tuning support from it's manual/manufacturer?

@erickshepherdNI
Copy link
Contributor Author

Changes lgtm. But please add WI# to PR description and rebase to latest nilrt/master/6.6.
Btw, did you end up testing on other controllers? What were the findings?

I updated the PR description and rebased the changes. as far as other testing, I was not able to reproduce the issue on a 9034 with the same Swissbit card. I'd be curious to test on more hardware configurations but this change should be ok since the card doesn't support tuning anyway.

I see. Did we get the info about it's tuning support from it's manual/manufacturer?

I dug up the exact card model and spec sheet when I started working on this and confirmed that the card was built to the 3.0 SD spec that does not support DDR50 tuning. I can find the documentation again and attach it to the work item. It would probably be good to have for future reference.

Copy link
Contributor

@gratian gratian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Just a nitpick on the comment being too general to be useful.

Also looks like check-patch flagged an indentation warning (see the 'Checks' tab in the PR).

@erickshepherdNI erickshepherdNI force-pushed the ershephe/tuning-quirk-fix branch from a7f92a6 to 91b2a63 Compare March 13, 2025 04:06
Adds the MMC_QUIRK_NO_UHS_DDR50_TUNING quirk and updates
mmc_execute_tuning() to return 0 if that quirk is set. This fixes an
issue on certain Swissbit SD cards that do not support DDR50 tuning
where tuning requests caused I/O errors to be thrown.

Signed-off-by: Erick Shepherd <[email protected]>
@erickshepherdNI erickshepherdNI force-pushed the ershephe/tuning-quirk-fix branch from 91b2a63 to a36e3c7 Compare March 13, 2025 04:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants