So to raise corner M up 120 dirt, then you need to get all corners 40 up, + 40 more for the middle ones + 40 for M = 25 * 40 + 9 * 40 + 40 = 1400 dirt (35 cart loads).
PS: I've assumed that the dirt will flow diagonally as well, but not verified it.
===Example: Vires LandBridge===