The attack in Muqdadiyah, about 80km (50 miles) north-east of Baghdad, targeted the funeral of a Sunni fighter and son of a tribal leader.
Mudher al-Shallal al-Araki was killed in a roadside bombing near his family’s home the day before, police told AFP news agency.
Iraq has seen a sharp rise in violence in recent months.
The mourners were attacked in the graveyard where they had gathered for the burial.
AFP reports that Mr Araki was a member of The Awakening, or “Sahwa”, which is made up of thousands of Sunni tribesmen and former insurgents who switched sides to fight al-Qaeda with the backing of the US military.
No group immediately claimed responsibility for the attack.
Iraq is suffering from its worst wave of violence in at least five years.
The UN says 979 people – including 158 police and 127 military personnel – were killed in violent attacks in October. More than 6,500 civilians have died since January, the highest annual toll since 2008.
There has also been a spill-over of violence from the conflict in Syria, where jihadist rebels linked to the Islamic State of Iraq, a Sunni militant umbrella group that includes al-Qaeda, have risen to prominence.