Temperature does not scale weirdly in your case, everything works correctly. What you write is a misconception that causes the same countless threads and questions.
Processor works similarly as GPU boost nowadays. The processor clocks itself to achieve maximum performance under given circumstances, one of these circumstances is temperature called in BIOS as Platform thermal throttle limit, which is set to 90C, which means that as soon as temperature reaches this limit processor built in overclocking will not proceed further.
This value was set by AMD as 90C is a perfectly safe working value, there is an additional milestone and this is 95C at which the processor starts real throttling.
Your processor cannot damage itself around 90C, it wants to run as fast as possible within its operating limits. If you like cooler temperatures, you can add cooling or change Platform thermal throttle limit in BIOS to e.g. 80C, so CPU will stop increasing its performance around this temp.
There is nothing to fix or repair, because the processor is working correctly.