ANSWER:
If there is no intention for seeking Barakah or the likes from the deceased, Yes, you say salam by reciting the prescribed dua when visiting graves.
Among the du’aa’s that may be recited are:
“Assalaamu ‘alaykum ahl al-diyaar min al-mu’mineen wa’l-Muslimeen, in sha Allaah bikum laahiqoon, as’al Allaaha lana wa lakum al-‘aafiyah (peace be upon you O people of the dwellings, believers and Muslims, In sha Allaah we will join you, I ask Allaah to keep us and you safe and sound).”