When a possessed person's soul is taken over by the demons of Satan, his conscious mind would reject all positive emotions and desires, and approve only the negative emotions and desires of his heart to conform with the will of Satan.
As the conscious mind continues to allow negative emotions and desires to be put into effect, the further away from God would be the possessed person, until he is utterly destroyed by Satan, or experiences an epiphany that pulls him from the brink of hell.
As long as the demon-possessed person continues to do the will of Satan, he cannot love God with all his heart and become a child of God (John 8:42-47). More than this, the Holy Spirit will not dwell in him because he cannot understand the things that come from the Holy Spirit (1st Corinthians 2:14).
On the other hand, if the demon-possessed person turns away from Satan by hearing, reading, speaking and practicing the gospel, the Holy Spirit will return and indwell him and regenerate his soul.
The demons of Satan would be chased out and God will instruct the Holy Spirit to reveal to the regenerated soul the things that come from the Spirit. On receiving the divine revelation, the regenerated soul will transmit it to the cleansed person's conscious mind.
The revelation from the regenerated soul will appear in the cleansed person's conscious mind as divine wisdom to help it distinguish between right and wrong, with the result that the conscious mind will be empowered by the Holy Spirit to reject all negative emotions and desires of the heart and approve only positive ones.
As the conscious mind continues to reject all negative emotions and desires sent to it, the heart will learn which emotions and desires the conscious mind will approve, and accordingly send only positive emotions and desires for approval and implementation.
This interaction between the conscious mind and the heart would allow only positive emotions and desires to be put into effect by the body, until a day will arrive when the heart would be transformed to the extent that it is able to initiate the rejection of negative emotions and desires on its own.
When the regenerated person's heart can reject negative emotions and desires on its own, he could then truthfully say he loves God with all his heart, and be justified to called himself a child of God.