Exemple #1
0
void orangefs_kill_sb(struct super_block *sb)
{
	gossip_debug(GOSSIP_SUPER_DEBUG, "orangefs_kill_sb: called\n");

	/* provided sb cleanup */
	kill_anon_super(sb);

	/*
	 * issue the unmount to userspace to tell it to remove the
	 * dynamic mount info it has for this superblock
	 */
	 orangefs_unmount_sb(sb);

	/* remove the sb from our list of orangefs specific sb's */

	spin_lock(&orangefs_superblocks_lock);
	__list_del_entry(&ORANGEFS_SB(sb)->list);	/* not list_del_init */
	ORANGEFS_SB(sb)->list.prev = NULL;
	spin_unlock(&orangefs_superblocks_lock);

	/*
	 * make sure that ORANGEFS_DEV_REMOUNT_ALL loop that might've seen us
	 * gets completed before we free the dang thing.
	 */
	mutex_lock(&request_mutex);
	mutex_unlock(&request_mutex);

	/* free the orangefs superblock private data */
	kfree(ORANGEFS_SB(sb));
}
Exemple #2
0
void class_del_student(CLASS *cls, STUDENT *stu){
    __list_del_entry(&stu->node);
    student_free(stu);
    cls->stu_count--;
    event_trigger(cls->student_deled, NULL);
}