Bulugh al-Maram 569
Abu Hurairah (RAA) narrated that the Messenger of Allah (ﷺ) said:
"Whoever accompanies the funeral (the dead body) until he performs the funeral prayer will have a reward equal to (one Qirat), and whoever accompanies the burial procession, will be doubly awarded (two Qirat).” They then asked, ‘What is meant by the two Qirat?’ He replied (ﷺ) “Like two huge mountains.” Agreed upon. Muslim added the statement, ‘until it is buried.’
وَعَنْهُ قَالَ: قَالَ رَسُولُ اَللَّهِ ‏- صلى الله عليه وسلم ‏-{ "مَنْ شَهِدَ اَلْجِنَازَةَ حَتَّى يُصَلَّى عَلَيْهَا فَلَهُ قِيرَاطٌ, وَمَنْ شَهِدَهَا حَتَّى تُدْفَنَ فَلَهُ قِيرَاطَانِ".‏ قِيلَ: وَمَا اَلْقِيرَاطَانِ? قَالَ: "مِثْلُ اَلْجَبَلَيْنِ اَلْعَظِيمَيْنِ" }  مُتَّفَقٌ عَلَيْهِ  1‏ .‏ 
وَلِمُسْلِمٍ: { حَتَّى تُوضَعَ فِي اَللَّحْدِ } 2‏ .‏‏1 ‏- صحيح.‏ رواه البخاري (3/196/فتح)‏، ومسلم (945)‏ (52)‏.‏
‏2 ‏- صحيح.‏ وهذه الرواية في مسلم (2/653)‏.‏