Sahih Bukhari Volume 2, Book 23, Hadith Number 410.
Narated By Abu Huraira : That Allah’s Apostle (p.b.u.h) said, “Whoever attends the funeral procession till he offers the funeral prayer for it, will get a reward equal to one Qirat, and whoever accompanies it till burial, will get a reward equal to two Qirats.” It was asked, “What are two Qirats?” He replied, “Like two huge mountains.”