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
mediatek: mt7623: fix thermal zone #9778
Conversation
Both active and passive trip points are desirable to have. Simply dropping them is not an option. Instead, we should swap the order (ie. first active == fan, then passive == throttling) and maybe raise the trip-point temperatures a little if needed. |
Followed your comment, @dangowrt , and swapped both active and passive trip points Also raised 10oC on the active trip point and 30oC on the passive trip point. Tested on UniElec U7623-02 eMMC (512M RAM) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please squash the 3 commits into a single one (eg. using git rebase -i origin/master
and then using the fixup
or squash
commands in the editor) and also write a meaningful commit message including Signed-off-by line (also in the commit for openwrt.git, not just the in the patch file you are adding).
The commit title should start with mediatek: mt7623: ...
.
Sorry for bothering and thanks for the guidance, @dangowrt . I believe I successfully made the changes requested. |
Hi guys, I apologize for not following this more closely, I had recent eye surgery which prevents me from spending too much time at a screen.
I think you are falling into the same trap I originally did. I assumed that since active and passive trip points existed and were named as such that they were doing what they are supposed to do. I thought reversing them would help. This is not the case. What I failed to do is look at what those trip points were actually tripping. The three trip points link to three cooling maps, map0, map1, and map2. All those cooling maps are 100% identical. This means that despite the name "passive", "active" and "hot", these trip points are doing the same thing by triggering identical cooling maps. Therefore two of the three maps are doing exactly nothing. Having them in is just fooling people into thinking they are there "for a reason". Until and unless the three cooling maps are changed to actually do something different from each other, the best course of action is to simply delete two of the trip points and delete two of the cooling maps, and have the remaining trip point trip at a reasonable temperature. |
Unless there is an active cooling device like a fan then active and passive are both gonna just end up throttling and that's it. |
@robimarko Both, the U7623 and the BPi-R2 do have a connector for a PWM-driven fan, so active cooling could be setup and make sense on those devices. |
That's a different thing then, those trip points need to be much higher though |
Where does the U7623 even have a fan connector? And on the R2, has anyone ever got the fan PWM to work? In any case, there is certainly no way of activating a fan that is common to both the U7623 and the BPI-R2. I don't believe the appropriate place to have .dts entries for U7623/BPI-R2 fans is in their common platform .dtsi. If it were appropriate to have all three trip points in the .dtsi, it still wouldn't be appropriate to have them all tied to identical cooling maps. I still suggest the appropriate course of action is to remove two of the trip points and their associated (identical) cooling maps from the .dtsi, and if we get the PWM's working with fans, incorporate what we need into the individual device .dts's |
@VA1DER Ok, agreed, let's just remove the lowest trip point for now and have new first trippoint at 77 deg C called |
Unless I got something wrong, the current push should provide that. |
|
I will, eventually, get this right, with the rebases.... Sorry for the noise. Does this look good now? |
Hello. Just checking if any more changes are required. Thanks |
Should this be the right one? Should I change the github name to match what I signed off? |
Change your local name is enough. Look in your ~/.gitconfig |
Pushed with the right .gitconfig, now? Sorry for causing all this issue. squashing the commits are being harder than I could figure, hence the force push. |
Imho commit title is too long, usally should take max 75 chars like all lines. You could change it like the title of this issue "mediatek: mt7623: Thermal zone fix" And put your current title down in the description with linebreaks after max 75 chars. |
Sorry for the long delay on this. Following @frank-w suggestion, changed the commit messages. |
@anonimou0 yes if in doubt just post the full patch on pastebin and post the link here... anyway you should not modify the output from git format-patch |
I pushed with the output of git format-patch already |
@anonimou0 REALLY NICE! now just /target/linux/refresh push the final version and we are good to go ! |
@Ansuel there is no /target/linux/refresh file and make target/linux/refresh and make target/linux/update both fail without a recipe |
what do you mean without a recipe? |
My bad. I was running the wrong command. Should I finally push just the patch file or all of them?
|
@anonimou0 only the relevant patch pls |
Done? Maybe? |
target/linux/mediatek/patches-5.15/193-dts-mt7623-thermal_zone_fix.patch
Outdated
Show resolved
Hide resolved
Raising the temperatures for passive and active trips. @VA1DER proposed at issue 9396 to remove passive trip. This commit relates to his suggestion. Without this patch. the CPU will be throttled all the way down to 98MHz if the temperature rises even a degree above the trip point, and it was further discovered that if the internal temperature of the device is above the first trip point temperature when it boots then it will start in a throttled state and even $ echo disabled > /sys/class/thermal/thermal_zone0/mode will have no effect. The patch increases the passive trip point and active cooling map. The throttling temperature will then be at 77°C and 82°C, which is still a low enough temperature for ARM devices to not be in the real danger zone, and gives some operational headroom. Signed-off-by: Bruno Umuarama <anonimou_eu@hotmail.com>
@anonimou0 it was a long journey but we manage to make it. Thanks for following instructions and not getting annoyed by me ahahah. |
As discussed on #9396 , using @VA1DER patch posted there and the tests done, I'm trying to create this pull request.
Text from @VA1DER:
The CPU will be throttled all the way down to 98MHz if the temperature rises even a degree above the trip point, and I have further discovered that if the internal temperature of the device is above the first trip point temperature when it boots,
The patch deletes the first two trip points and cooling maps. The throttling temperature will then be at 87°C, which is still a low enough temperature for ARM devices to not be in the real danger zone, and gives some operational headroom.