/** * iopen_go_callback - schedule the dcache entry for the inode to be deleted * @gl: the glock * * gl_spin lock is held while calling this */ static void iopen_go_callback(struct gfs2_glock *gl) { struct gfs2_inode *ip = (struct gfs2_inode *)gl->gl_object; if (gl->gl_demote_state == LM_ST_UNLOCKED && gl->gl_state == LM_ST_SHARED && ip) { gfs2_glock_hold(gl); if (queue_work(gfs2_delete_workqueue, &gl->gl_delete) == 0) gfs2_glock_put_nolock(gl); } }
/** * iopen_go_callback - schedule the dcache entry for the inode to be deleted * @gl: the glock * * gl_spin lock is held while calling this */ static void iopen_go_callback(struct gfs2_glock *gl) { struct gfs2_inode *ip = (struct gfs2_inode *)gl->gl_object; if (gl->gl_demote_state == LM_ST_UNLOCKED && gl->gl_state == LM_ST_SHARED && ip && test_bit(GIF_USER, &ip->i_flags)) { gfs2_glock_hold(gl); if (queue_delayed_work(gfs2_delete_workqueue, &gl->gl_delete, 0) == 0) gfs2_glock_put_nolock(gl); } }