This problem is because of the erupting wisdom tooth. Some times there is not enough space for the wisdom tooth to erupt in the oral cavity or the angulation of the wisdom tooth is not right. We say that the wisdom tooth is impacted. In such situation there is pain and swelling in that area. You have to go to the dentist
and find out whether the wisdom tooth is impacted and if it is so then you have to go for the extraction of the wisdom tooth.In the mean time,do hourly rinses with warm saline water for relief.