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 get phase invalid clockrate #26

Closed
SolidHal opened this issue Aug 26, 2018 · 5 comments
Closed

mmc get phase invalid clockrate #26

SolidHal opened this issue Aug 26, 2018 · 5 comments
Labels
minor bug wontfix This will not be worked on

Comments

@SolidHal
Copy link
Owner

SolidHal commented Aug 26, 2018

Early in the boot kernel logs, these get thrown.

[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate
[    0.000000] rockchip_mmc_get_phase: invalid clk rate

I vaguely recall reading on the chrome os kernel somewhere that it is due to certain emmcs not liking the way speed tuning is handled, possibly in the commit logs for https://chromium.googlesource.com/chromiumos/third_party/kernel/+/chromeos-3.14/drivers/clk/rockchip/clk-mmc-phase.c

EDIT: non of the current untested patches fix this

@SolidHal
Copy link
Owner Author

The reason we don't see thin in the chromeos kernel is that the error isn't present in
chromeos-3.14/drivers/clk/rockchip/clk-mmc-phase.c

The error has a pretty good description as to why it was added:

	/*
	 * The below calculation is based on the output clock from
	 * MMC host to the card, which expects the phase clock inherits
	 * the clock rate from its parent, namely the output clock
	 * provider of MMC host. However, things may go wrong if
	 * (1) It is orphan.
	 * (2) It is assigned to the wrong parent.
	 *
	 * This check help debug the case (1), which seems to be the
	 * most likely problem we often face and which makes it difficult
	 * for people to debug unstable mmc tuning results.
	 */
	if (!rate) {
		pr_err("%s: invalid clk rate\n", __func__);
		return -EINVAL;
	}

TODO: Try adding the two rate checks to the chromeos kernel

@SolidHal SolidHal added the wontfix This will not be worked on label Sep 4, 2018
@SolidHal
Copy link
Owner Author

SolidHal commented Sep 4, 2018

These errors show up in the chromeos kernel when the checks are added, since the machine works fine despite them and they don't seem to cause problems for chromeos I'm going to ignore and close this issue for now.

@SolidHal SolidHal closed this as completed Sep 4, 2018
@SolidHal
Copy link
Owner Author

Reopening issue as these issues may be imapacting the other emmc related problems I'm. Submitted bug report.

@SolidHal SolidHal reopened this Oct 25, 2018
@SolidHal
Copy link
Owner Author

SolidHal commented Nov 7, 2018

according to some rockchip clock people this is likely a red herring and not indicative of a larger issue

@SolidHal
Copy link
Owner Author

this has been fixed in upstream, and will be included in 5.3. Backporting patches to 4.17.19, and eventually 4.19

SolidHal added a commit that referenced this issue May 22, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
minor bug wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

1 participant