My mare would do that when her stomach was bothering her. But it would only last for a day. I would check his teeth, see if one may be bothering him. Use a flashlight so you can see into the back part of his mouth, and you may want to check his gums also for foreign objects/possible abscessing.
Good luck
