Jesus asks three times, not because he doesn't hear him answer, or doesn't quite believe what he's being told, but because Peter denied Jesus three times. Jesus gave Peter a chance at redemption. Three denials earlier, and now three assertions of his love.
Peter probably felt pretty far past forgiveness when he first realized that he had denied his Lord just as Jesus had predicted. But Jesus gave him the opportunity to make up for it.
I find this very comforting. We stumble and fall along the way, but Jesus is always there, ready to forgive and to give us another chance.