The neuter noun लिङगम् (liṅgam) is a common term used in Śaiva tantric literature for an icon as a substrate of worship. Most commonly, liṅga is used to designate an icon of Śiva, the Śivaliṅga.
A number of doctrinal etymologies (nirvacanas) can be cited to explain the esoteric significance of this term: Kauṇḍinya on Pāśupatasūtra 1.6: līyanāl liṅganāc ca liṅgam. Mālinīvijayottara 18.3ab: yajed ādhyātmikaṃ liṅgaṃ yatra līnaṃ carācaram. Kaulajñānanirṇaya 3.10cd: tena liṅgaṃ tu vikhyātaṃ yatra līnaṃ carācaram. Mālinīślokavārttika 2.61cd: yatra viśvam idaṃ līnaṃ yadantaḥsthaṃ ca gamyate.
What these do not directly address is the phallic symbolism of the Śivaliṅga.
A very useful article by Hélène Brunner titled The Sexual Aspect of the linga Cult According to the Saiddhantika Scriptures (in: Studies in Hinduism II, Miscellanea to the Phenomenon of Tantras (BKGA 28 ), ed. G. Oberhammer, Wien 1998), addresses the wide-ranging denial of this simply observable fact. She puts forward a number of explanations why this so obvious fact should be so widely ignored or denied, noting that a uniform perception, irrespective of place and time, is of course hardly to be expected, so a more detailed investigation is called for.
A particularly clear statement by a learned author writing in Kashmir sheds light on what the medieval Kashmirian perception may have been. Since Brunner was not aware of this passage in her article I adduce it below. Significantly the statement does not occur in a Śaiva work but in a textbook on rhetorics, the Kāvyālaṅkārasūtravṛtti of Vāmana 2.1.19.
The passage concerns the use of words which in origin denote objects which ought to be “unmentionable” (asabhya) in polite discourse but are considered sufficiently ʻʻveiledʼʼ (saṃvīta/saṃvṛta) to be acceptable. The prime example of this kind of thing is the Śivaliṅga:
saṃvītasya hi lokena na doṣānveṣaṇaṃ kṣamam |
śivaliṅgasya saṃsthāne kasyāsabhyatvabhāvanā ||