A tonsillectomy was a medical procedure in which a patient's tonsils were removed.
Leonard McCoy had undergone this procedure sometime in the past, but his tonsils grew back as a side effect of the Omicron spores. (TOS: "This Side of Paradise")
Some used this term as a metaphor for flirtatious kissing. In the holographic novel Photons Be Free, B'Elanna Torres, playing the EMH, accused Marseilles of getting her out of sickbay just so he could give her patient a tonsillectomy. (VOY: "Author, Author")