And other-centeredness creates oneness. All three synoptic gospels record this event, but John does not. The Father gave his glory to the Son because he loved him before the foundation of the world. The Father dwells with the Son because he loves him. The fact that he loved him before the foundation of the world speaks of the depth of his love.
Glory is given because of love.
This has been given to us because Jesus loves us. This love is seen even more clearly in the next two verses. Here the Father is addressed as righteous in the context of our knowing God. It is God's righteousness, given to us through faith in Christ, that enables us to know God. But Jesus' relationship with the Father, and our recognition of that relationship, means there is hope for the world.