Voltage regulator must be equipped with upper current resistance to work, otherwise once the input voltage exceeds the voltage regulator value, the current will increase indefinitely and burn. The voltage regulator circuit equipped with the upper current resistance can calculate the maximum input voltage, requiring the difference between the input voltage and the voltage regulator value of 5.1V ΔU, which can not exceed the maximum current Im of the regulator tube when added to the current limiting resistance R. Delta U=R*Im.
For example, the maximum current of the regulator is 200mA, with 100ω current limiting resistance, pressure difference ΔU=100*0.2=2V, input voltage U=5.1V 2V =7.1V. Beyond that, the regulator will burn out.