In other words, how much do you trust your company's senior executives and human resource managers? If they're any good, they know about your bad boss and are working on an exit strategy. All you need to do is keep your head down and wait patiently. This process always takes longer than everyone wants, so you'll have to fight the completely human urge to form a cabal with your coworkers to bitch about the situation. Complaining will only drain and distract you. Instead, focus on the work and keep a positive attitude. That will hold you in good stead with the higher-ups when your boss (finally) moves on.
It's a different situation entirely if your company appears to tolerate destructive behaviors. Too many companies turn a blind eye to difficult managers as long as they're delivering the numbers. A friend of mine was an analyst at an investment firm where the manager of her 60-person department routinely screamed at people for “incompetence.” Even though his rages were widely known, the CEO of the company often singled him out for praise on his financial results. It was clear he wasn't going anywhere but up.
If that sounds familiar, it's time for a serious career evaluation.