Cheek biting

I have a habit I didn’t know that I actually did till now, I’ve been biting the inside of my cheek and it basically look like this >> but on the other side there like a whole in my mouth and I can’t eat, talk, or open my mouth bc I’m in so much pain.

Has this happen to anyone before? And are there ways to stop this