Gypsum provides calcium ions necessary to replace harmful exchangeable sodium ions in sodic soils, improving soil structure and permeability.