Another idea would be to use a low drop linear regulator for 5 volt and use the cheap switch mode ones to lower the 24 volts down to 6-7 volts. That way power losses on the low drop would be minimal and still you will have good quality noise free 5v line.

Ioannis