Roger Federer says he hurt his knee while preparing a bath for his twin daughters, forcing him to have surgery for the first time in his career.

Speaking Thursday on the eve of his first match since the Feb. 3 operation, Federer said he turned and heard a click in his left knee.

"It was a very simple movement, probably a movement I've done a million times in my life," he said. "I didn't think much of it when it did happen."

Soon his knee was swollen, and a few days later he had arthroscopic surgery to repair torn cartilage. He's scheduled to return Friday against longtime rival Juan Martin del Potro at the Miami Open.

The 34-year-old Swiss has been a model of durability throughout his career. He's playing Key Biscayne for the 16th time, although he did skip the tournament last year for scheduling reasons.

Speedy recovery

Federer made a late decision to enter the event this month, surprised and pleased by his speedy recovery. He was on crutches for 12 days and has trained without restrictions for the past nine days.

"Expectations are really low, which is nice for a change — just see where I am," the 17-time Grand Slam champion said. "I'm just really pleased I'm back. I didn't expect myself to be back here, to be quite honest, after the surgery."

Federer, who is seeded third, had a first-round bye. Winners in the second round included No. 3 Agnieszka Radwanska, No. 7 Petra Kvitova, American qualifier Tim Smyczek and tour veteran Denis Istomin, who won for the first time this year in eight matches by beating 19-year-old Borna Coric 4-6, 7-5, 7-5.

Federer's layoff came during an eventful stretch for his sport, with Maria Sharapova's career in jeopardy following a failed a doping test, and renewed debate about equal prize money for men and women. Federer offered his thoughts on each subject and said he was "completely surprised" by Sharapova's suspension.

Federer said he doesn't believe tennis has a doping problem but would like to see more consistency in testing.

"I've been in Dubai now for 10 years there and been tested once," he said. "That's not OK for me. I get tested more in Switzerland because the guy from Switzerland lives in my village. He comes and sees me the day after my surgery, and one week later."

As for equal prize money, Federer said he's all for it.

"I'm happy that tennis has produced some of the greatest female athletes in the world," he said. "Equal prize money is a good thing."

The first marquee match at Key Biscayne will be on the men's side, with Federer facing another Grand Slam champion mounting a comeback from an injury. Del Potro returned to the tour in February after an 11-month layoff, during which he twice had surgery on his left wrist.

"His injury was much, much greater," Federer said. "That's why I'm really pleased for him that he was able to find a way back onto the tour."

Federer is 15-5 against del Potro, including 5-1 in Grand Slam tournaments. That one loss came in the 2009 U.S. Open final for del Potro's lone major title.