Mg(s) as it is at the bottom of the cycle
No, it is not because it is at "the bottom of the cycle", standard states are defined: https://en.wikipedia.org/wiki/Standard_state
But yes, Mg(s) is the standard state. So, if the Mg(s) is a standard state, and the formation enthalpy is formation from standard state, which process - D or F - is the formation of MgX2
Once you assign correctly enthalpy of the formation of MgX2
(s) to one of the processes in the cycle it will be obvious what is left to calculate - and it should be also obvious how to calculate it.