In my area we have no magnesium deficiency but a large magnesium mine and plenty of salinity and wicked high pH (at least where I've had testing done to find out why everything is yellow and dying).
https://extension.usu.edu/htm/...
Some of my garden friends add iron--we have no shortage of that either but the plants have a hard time with uptake at the high pH so it helps a lot. For me, the miracle cure has been tons of organic matter.