The diagnosis that exists, and the sentence inside it that matters
There is no diagnosis called pornography addiction. Not in ICD-11 and not in DSM-5. If somebody has told you that you have one, they have told you about a label that circulates rather than about a diagnosis.
What does exist in ICD-11 is compulsive sexual behaviour disorder, code 6C72. It asks for a persistent failure to control intense, repetitive sexual impulses, resulting in repeated behaviour, over an extended period taken as six months or more, causing real distress or real damage to your life.
And there is one sentence inside those criteria that a Muslim reading this needs to have in front of them. It says that distress arising entirely from moral judgements and disapproval about sexual impulses, urges or behaviours is not sufficient to meet the requirement. That is not a commentary on the criteria. It is in the criteria.
In plain words, religious distress on its own, however severe it is, is explicitly not this disorder. The people who wrote the criteria put that sentence there deliberately, and they put it there for you.