The life time of a computers usability has a direct impact on the planetary environment. Most of the carbon emissions that a computer produces in its lifetime is from the manufacturing of the machine itself. For most computers its electricity use even when powered by coal power is only minor compared with the initial release for its construction.
In a 2011 report from Arizona University (https://www.sciencedirect.com/science/article/pii/S0959652611000801?via%3Dihub) estimates that a single laptop will produce about 227-270Kg of carbon merely to be produced. If using a coal based power source, the machine would need to use 290 KiloWatt hours of energy to merely break even with its production emissions(https://carbonpositivelife.com/co2-per-kwh-of-electricity/). In most cases a high end laptop battery would need to be fully charged and discharged approximately 2,500 times to use this kind of power level which is far beyond the lifetime of most batteries available today. For mobile phones it would take even longer. This is unless you purchase a new battery, if the manufacturer allows it. If using a renewable energy source then the power usage is not a major impact but it does not negate the initial emissions outlay. Ever piece of hardware produced will have an impact on the planet.
Mobile phones suffer from the same issues (https://www.fastcodesign.com/90165365/smartphones-are-wrecking-the-planet-faster-than-anyone-expected). It is better to use a phone for 10 years than it is to replace it when made obsolete.
When you use a proprietary computer systems then you may not have a choice in this matter. These systems can lock you out of functionality or system updates at the whim of the developers, typically this is done so that you are forced to buy a newer model machine. Not only does this restrict your freedom to use your computer as you wish but it also restricts forces you to purchase items needlessly.
This is known as Planned (Forced) Obsolescence. When a piece of hardware is rendered useless before its hardware has broken from use. Machines such as the Apple iPad and iPhones are known to have the updates restricted on older phones despite there being no physical reason for these restrictions. It doesn't just impact the iThings, it impacts almost all computer hardware sold today.
With an entirely free software powered machine then you remain in control of your hardware. You buy a new system when you wish not when the manufacturer forces. As such we can use our computers for longer than what is typically offered by non-free systems. If a machine becomes unsupported by the developers, with free software others can pickup the development role and keep it working far beyond the original intention. By merely changing the software, we can have a real impact on the physical world. By reusing a piece of hardware rather than buying new, then we keep one more machines out of the rubbish tip and working for us today.
Computers only make up a small part of the carbon emissions problem but as a whole we need to minimise these issues wherever possible. Just because there are bigger problems does not mean we can ignore our immediate solutions that we personally change today. The lesser of two evils is still evil. Because of this we need to use what machines we have today for a long time so that we do not end up producing more emissions and waste than necessary.