All perfect praise be to Allah, The Lord of the worlds. I testify that there is none worthy of worship except Allah and that Muhammad is His slave and Messenger.
There is no contradiction between the obligation of seeking permission and what some scholars said regarding the permissibility of entering without permission for the one who hears musical instruments, because the intention of entering without permission is in order to remove the evil.
This is because whoever exposes the evil which he is committing has violated the concealment of his sin, and there is no sacredness that remains in his regard, so it is permitted to enter upon him in order to change this evil provided that the evil is apparent and provided that changing the evil does not lead to a greater evil.
The author of Al-Bayaan said, “Al-Mas‘oodi said in Al-Ibaanah, ‘If it is known that there is alcohol in a house, or that there is a mandolin, or if it is known that alcohol is being drunk or that the mandolin is being played... then one may attack the owner of the house and spill the wine and disconnect the mandolin and prevent him from drinking alcohol and playing the mandolin.’”
Also, I’aanat-at-Taalibeen reads:
“You should also know that it is not obligatory on anyone to look for a hidden evil so that he would forbid it when he sees it; rather, this is prohibited, as Allah says (what means): {...and do not spy...} [Quran 49:12]; and the Prophet said, ‘The person who seeks out the faults of his Muslim brother, Allah Almighty will seek out his faults…’ Rather, what is obligatory is to enjoin good when you see people in the act of not doing that good, and the same thing applies to forbidding evil; so you should know this. Indeed, we have seen many people who make mistakes in this regard.”
Also, the evil that one must forbid even without permission is the one that will be missed if it is not forbidden on time, such as when a person wants to kill someone else or wants to commit Zina (fornication) with a woman; in such cases, it is obligatory to intervene to remove the evil; but in other cases, it is not obligatory.
I’aanat-at-Taalibeen also reads, “His saying, ‘If one is hidden with an evil’ means that he intends to commit an evil that cannot be undone once it is done, such as killing and Zina. This cannot be amended after it occurs, contrary to what may be amended, such as something that is taken by force or theft, then in this case, one is not obliged to intervene, as it is possible to get what has been taken by force after it has been taken, and it is possible to get back what is stolen after it has been stolen.”
In light of the above, the confusion is removed from you and you have come to know that these rulings are in conformity with the sound mind and the interest of the people, so there is no reason at all to dislike them in the first place.
Allah knows best.