mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-04 20:19:47 +08:00
gfs2: Move gfs2_log_pointers_init
Move gfs2_log_pointers_init to recovery.c: there is no need for inlining this function. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
This commit is contained in:
parent
91793971f3
commit
703a4af356
@ -44,17 +44,6 @@ __releases(&sdp->sd_log_lock)
|
|||||||
spin_unlock(&sdp->sd_log_lock);
|
spin_unlock(&sdp->sd_log_lock);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void gfs2_log_pointers_init(struct gfs2_sbd *sdp,
|
|
||||||
unsigned int value)
|
|
||||||
{
|
|
||||||
if (++value == sdp->sd_jdesc->jd_blocks) {
|
|
||||||
value = 0;
|
|
||||||
}
|
|
||||||
sdp->sd_log_tail = value;
|
|
||||||
sdp->sd_log_flush_tail = value;
|
|
||||||
sdp->sd_log_head = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void gfs2_ordered_add_inode(struct gfs2_inode *ip)
|
static inline void gfs2_ordered_add_inode(struct gfs2_inode *ip)
|
||||||
{
|
{
|
||||||
struct gfs2_sbd *sdp = GFS2_SB(&ip->i_inode);
|
struct gfs2_sbd *sdp = GFS2_SB(&ip->i_inode);
|
||||||
|
@ -581,3 +581,12 @@ int gfs2_recover_journal(struct gfs2_jdesc *jd, bool wait)
|
|||||||
return wait ? jd->jd_recover_error : 0;
|
return wait ? jd->jd_recover_error : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gfs2_log_pointers_init(struct gfs2_sbd *sdp, unsigned int value)
|
||||||
|
{
|
||||||
|
if (++value == sdp->sd_jdesc->jd_blocks) {
|
||||||
|
value = 0;
|
||||||
|
}
|
||||||
|
sdp->sd_log_tail = value;
|
||||||
|
sdp->sd_log_flush_tail = value;
|
||||||
|
sdp->sd_log_head = value;
|
||||||
|
}
|
||||||
|
@ -29,6 +29,7 @@ void gfs2_recover_func(struct work_struct *work);
|
|||||||
int __get_log_header(struct gfs2_sbd *sdp,
|
int __get_log_header(struct gfs2_sbd *sdp,
|
||||||
const struct gfs2_log_header *lh, unsigned int blkno,
|
const struct gfs2_log_header *lh, unsigned int blkno,
|
||||||
struct gfs2_log_header_host *head);
|
struct gfs2_log_header_host *head);
|
||||||
|
void gfs2_log_pointers_init(struct gfs2_sbd *sdp, unsigned int value);
|
||||||
|
|
||||||
#endif /* __RECOVERY_DOT_H__ */
|
#endif /* __RECOVERY_DOT_H__ */
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user