Usher's ex-wife Tameka Raymond just lost in the former couple's bitter custody battle -- TMZ has learned, a judge has awarded Usher primary custody of their two sons.
It's a shocking development -- considering both sides were trying to strip each other of custody. Tameka felt the singer was an absentee father who was too absorbed in his career to be a good dad. She also accused him of using drugs in front of the kids.
Usher argued Tameka was inattentive and irresponsible.
The ruling marks the end of an emotional custody trial -- involving wild accusations and name-calling ... Usher even broke down at one point on the witness stand.
But today, we're told a judge sided with the singer -- awarding Usher primary custody of the ex-couple's two sons, which means the children will be spending the majority of the time with their father.
Tameka still retains some custodial rights -- but the extent to which Tameka will be able to see her kids is unclear.