The “Y” arrow would point towards the rear of the craft for “rotation 0” as I recall so the IST 8310 would require either Yaw 90 or Yaw 270, not sure which,if the LIS3MDL is mounted that way.
You could install the dev version of firmare and enable on-board compass learning for the FC to determine orientation and then flash back to stable after its complete.