The EU is introducing an energy label for phones, together with mandatory requirements for phones sold in the EU;

- 5 years of software updates (AFTER they stop selling the device in the EU)

- providing important hardware parts (during sale and for 7 years after), including free software (if needed), to every repair shop, within 5-10 business days

- batteries have to make 800 charging cycles and still be above 80% original capacity

And on top of that, phones and tablets need this energy label (which also includes a fall damage durability and repairability score), and abide by the above requirements, from 20 June 2025.

(https://energy-efficient-products.ec.europa.eu/product-list/smartphones-and-tablets_en)

Smartphones and Tablets

Product Energy Efficiency - Smartphones and Tablets. The 2023 regulations cover smartphones, feature phones, cordless phones and slate tablets. They do not apply to tablet computers, to products with flexible main display (roll-up), and to smartphones for high security communication. Energy labelling is foreseen only for smartphones and slate tablets.

Energy Efficient Products
@ShadowJonathan could go a bit further (mostly by also requiring OEMs to provide all required resources to enable the development of 3rd party OSes for their phones, as well as users to run these 3rd party OSes), but it’s undeniably a step in the right direction