No particular mental effort beyond that needed to abstain from committing suicide due to the extreme monotony of a treadmill run.
That said, the treadmill can be a fine tool for training. It allows you to totally ignore weather conditions, and actually for speed workouts it can have the advantage of forcing you to stay on pace. A common rule of thumb is that a 1% incline on the treadmill compensates for the lack of wind resistance.
I can't stand the damn things myself, but there are runners, including some guys I know personally, who train exclusively using the treadmill and still do well in races up to marathon distance (I've never heard of any ultramarathoners who train exclusively on the treadmill).