The Dallas-bound bus was heading east from Los Angeles when the crash occurred near Tonopah shortly before 2 a.m. Thursday.
The bus crossed the highway median, but came to a stop before entering westbound traffic when other passengers restrained the man who had been pummeling the driver, Arizona Department of Public Safety said.
The bus remained upright and none of the 24 people taken to hospitals had life-threatening injuries, the DPS said.
The driver "did a good job of maintaining control" before the bus came to a stop in the median, where there were numerous rocks and bushes, Harquahala Fire District Chief Dan Caudle told KPHO-TV (http://bit.ly/1eF5XJL).
Caudle said the man "basically went berserk in the bus and grabbed control of vehicle."
"The passengers descended on him," DPS spokesman Bart Graves told The Associated Press.
Graves said the attacker reportedly was hallucinating and indicated he wanted to get off the bus. The man was taken to a hospital for a drug-induced condition, Graves said.
The passengers' injuries included a broken sternum suffered by one of the passengers who helped restrain the attacker, said Officer Carrick Cook, another DPS spokesman.
Passengers said it was terrifying.
"I thought we were all gonna die," Chrissy Sanchez told KTVK-TV (http://bit.ly/KMTBVH). "I woke up to this commotion. I remember hearing screaming ... I realized we were not on the road anymore."
The alleged attacker and a female companion got off the bus when it stopped and ran off into the desert, but he was arrested when they returned 30 minutes later, the DPS said.
Maquel Donyel Morris, 25, of Los Angeles will be booked into jail on suspicion of numerous counts of endangerment, assault and aggravated assault, the DPS said.
Greyhound spokeswoman Alexandra Pedrini said the bus was carrying 41 passengers, plus the driver.
A relief bus was sent to the accident scene to take the nearly 20 uninjured passengers to Phoenix so they could continue to their final destinations, she said.
Westbound lanes of I-10 were closed for 30 minutes so helicopters could land.
Copyright 2014 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.