@@ -520,13 +520,11 @@ static void buf_lo_after_commit(struct gfs2_sbd *sdp, struct gfs2_trans *tr)
520520static void buf_lo_before_scan (struct gfs2_jdesc * jd ,
521521 struct gfs2_log_header_host * head , int pass )
522522{
523- struct gfs2_sbd * sdp = GFS2_SB (jd -> jd_inode );
524-
525523 if (pass != 0 )
526524 return ;
527525
528- sdp -> sd_found_blocks = 0 ;
529- sdp -> sd_replayed_blocks = 0 ;
526+ jd -> jd_found_blocks = 0 ;
527+ jd -> jd_replayed_blocks = 0 ;
530528}
531529
532530static int buf_lo_scan_elements (struct gfs2_jdesc * jd , unsigned int start ,
@@ -549,9 +547,9 @@ static int buf_lo_scan_elements(struct gfs2_jdesc *jd, unsigned int start,
549547 for (; blks ; gfs2_replay_incr_blk (sdp , & start ), blks -- ) {
550548 blkno = be64_to_cpu (* ptr ++ );
551549
552- sdp -> sd_found_blocks ++ ;
550+ jd -> jd_found_blocks ++ ;
553551
554- if (gfs2_revoke_check (sdp , blkno , start ))
552+ if (gfs2_revoke_check (jd , blkno , start ))
555553 continue ;
556554
557555 error = gfs2_replay_read_block (jd , start , & bh_log );
@@ -572,7 +570,7 @@ static int buf_lo_scan_elements(struct gfs2_jdesc *jd, unsigned int start,
572570 if (error )
573571 break ;
574572
575- sdp -> sd_replayed_blocks ++ ;
573+ jd -> jd_replayed_blocks ++ ;
576574 }
577575
578576 return error ;
@@ -615,7 +613,7 @@ static void buf_lo_after_scan(struct gfs2_jdesc *jd, int error, int pass)
615613 gfs2_meta_sync (ip -> i_gl );
616614
617615 fs_info (sdp , "jid=%u: Replayed %u of %u blocks\n" ,
618- jd -> jd_jid , sdp -> sd_replayed_blocks , sdp -> sd_found_blocks );
616+ jd -> jd_jid , jd -> jd_replayed_blocks , jd -> jd_found_blocks );
619617}
620618
621619static void revoke_lo_before_commit (struct gfs2_sbd * sdp , struct gfs2_trans * tr )
@@ -677,13 +675,11 @@ static void revoke_lo_after_commit(struct gfs2_sbd *sdp, struct gfs2_trans *tr)
677675static void revoke_lo_before_scan (struct gfs2_jdesc * jd ,
678676 struct gfs2_log_header_host * head , int pass )
679677{
680- struct gfs2_sbd * sdp = GFS2_SB (jd -> jd_inode );
681-
682678 if (pass != 0 )
683679 return ;
684680
685- sdp -> sd_found_revokes = 0 ;
686- sdp -> sd_replay_tail = head -> lh_tail ;
681+ jd -> jd_found_revokes = 0 ;
682+ jd -> jd_replay_tail = head -> lh_tail ;
687683}
688684
689685static int revoke_lo_scan_elements (struct gfs2_jdesc * jd , unsigned int start ,
@@ -715,13 +711,13 @@ static int revoke_lo_scan_elements(struct gfs2_jdesc *jd, unsigned int start,
715711 while (offset + sizeof (u64 ) <= sdp -> sd_sb .sb_bsize ) {
716712 blkno = be64_to_cpu (* (__be64 * )(bh -> b_data + offset ));
717713
718- error = gfs2_revoke_add (sdp , blkno , start );
714+ error = gfs2_revoke_add (jd , blkno , start );
719715 if (error < 0 ) {
720716 brelse (bh );
721717 return error ;
722718 }
723719 else if (error )
724- sdp -> sd_found_revokes ++ ;
720+ jd -> jd_found_revokes ++ ;
725721
726722 if (!-- revokes )
727723 break ;
@@ -741,16 +737,16 @@ static void revoke_lo_after_scan(struct gfs2_jdesc *jd, int error, int pass)
741737 struct gfs2_sbd * sdp = GFS2_SB (jd -> jd_inode );
742738
743739 if (error ) {
744- gfs2_revoke_clean (sdp );
740+ gfs2_revoke_clean (jd );
745741 return ;
746742 }
747743 if (pass != 1 )
748744 return ;
749745
750746 fs_info (sdp , "jid=%u: Found %u revoke tags\n" ,
751- jd -> jd_jid , sdp -> sd_found_revokes );
747+ jd -> jd_jid , jd -> jd_found_revokes );
752748
753- gfs2_revoke_clean (sdp );
749+ gfs2_revoke_clean (jd );
754750}
755751
756752/**
@@ -789,9 +785,9 @@ static int databuf_lo_scan_elements(struct gfs2_jdesc *jd, unsigned int start,
789785 blkno = be64_to_cpu (* ptr ++ );
790786 esc = be64_to_cpu (* ptr ++ );
791787
792- sdp -> sd_found_blocks ++ ;
788+ jd -> jd_found_blocks ++ ;
793789
794- if (gfs2_revoke_check (sdp , blkno , start ))
790+ if (gfs2_revoke_check (jd , blkno , start ))
795791 continue ;
796792
797793 error = gfs2_replay_read_block (jd , start , & bh_log );
@@ -811,7 +807,7 @@ static int databuf_lo_scan_elements(struct gfs2_jdesc *jd, unsigned int start,
811807 brelse (bh_log );
812808 brelse (bh_ip );
813809
814- sdp -> sd_replayed_blocks ++ ;
810+ jd -> jd_replayed_blocks ++ ;
815811 }
816812
817813 return error ;
@@ -835,7 +831,7 @@ static void databuf_lo_after_scan(struct gfs2_jdesc *jd, int error, int pass)
835831 gfs2_meta_sync (ip -> i_gl );
836832
837833 fs_info (sdp , "jid=%u: Replayed %u of %u data blocks\n" ,
838- jd -> jd_jid , sdp -> sd_replayed_blocks , sdp -> sd_found_blocks );
834+ jd -> jd_jid , jd -> jd_replayed_blocks , jd -> jd_found_blocks );
839835}
840836
841837static void databuf_lo_after_commit (struct gfs2_sbd * sdp , struct gfs2_trans * tr )
0 commit comments