In a skillet over medium heat, sauté onion in butter; blend in flour, mustard, salt and pepper. Gradually add milk, stirring constantly until thickened; mix in 1 1/2 cups cheese and stir until melted.
Remove from heat; add potatoes and toss to coat. Spoon into a greased 13"x9" baking pan; arrange ham and remaining cheese on top.
Bake, uncovered, at 350 degrees for 30 minutes, until hot and bubbly.