In a much-discussed passage of the Kāraṇḍavyūhasūtra it is taught that Avalokiteśvara produced Maheśvara from his forehead. Maheśvara is introduced as a representative of the degenerative Kali age. In this connection, the Kāraṇḍavyūha quotes a doctrinal verse about the worship of the liṅga, which for a long time has been mistakenly attributed to ‘the Skandapurāṇa’, but whose source can now be identified in the Śivadharmaśāstra. After a comparative discussion of this verse in both texts, the article considers the possible broader implications of this quotation, in particular in relation to the question of the origin of the six-syllabled mantra oṃ maṇipadme hūṃ and its Śaiva counterpart oṃ namaḥ śivāya. The article concludes with some observations on distinctive features that characterise Śaiva versus Vaiṣṇava interactions with Buddhism.