TMJ relief??

I most likely need to have surgery, but for the time being what are some exercises I can do at home that can keep my jaw from locking up? It pops horribly every time I open my mouth and makes a crunching noise. I can't eat chewy foods like steak and gum is completely out of the question. I need some relief!