Carter upsets O'Sullivan to reach second round at snooker worlds