Dr Xavier Mir and Dr Eugenio Jimeno performed surgery on Barbera's broken left shinbone and fibula in Barcelona on Sunday morning.
Barbera had sustained the injury in a training accident on Friday.
"The surgery had good results," said Dr Mir. "We are confident that Hector will be able to leave the hospital in 48 hours and can begin light physical activity in seven days.
"It is difficult to say how long the post-surgery rehabilitation will take. We need to evaluate the progress of the patient, but I think that we can reasonably think that he will able to run a race in four to six weeks, according to his feedback."
Barbera will therefore definitely miss MotoGP's next round at Laguna Seca next weekend. The series then takes a break until Indianapolis on the third weekend of August, with Brno a week later.
The incident came just after Barbera achieved his maiden MotoGP front row start at Mugello, outpacing the factory Ducatis. He said he was pleased with the outcome of the the surgery, but frustrated to lose momentum in his improving season.
"Doctor Mir and Doctor Jimeno have done a great job. I'm feeling quite good, still a dizzy from the anaesthesia, but it's normal," said Barbera.
"Obviously I'm disappointed about the incident. It happened in the worst period possible. I had a great feeling both with my bike and with my crew. In the last three races I was able to enjoy riding and was fighting with the factory riders to achieve the best result possible.
"I could have had other brilliant results in the next rounds in Laguna Seca and Indy, but it's life and now I have to think only about my injury and my rehabilitation."