As stated the minimum class to upgrade is L. So L, B, and Y are upgradable with miles. Economy to PE is 10K miles and PE to Upper is 20K miles. An upgradeable PE is W or S class only.
Also, you can upgrade for a special day of departure price if there is space available on your day of departure. It can range from GBP179 to GBP249 depending on the route and season.