disable_tsc(prev_p, next_p);  
struct task_struct *__switch_to(struct task_struct *prev_p, struct task_struct *next_p){	struct thread_struct *prev = &prev_p->thread,				 *next = &next_p->thread;	int cpu = smp_processor_id();  	struct tss_struct *tss = &per_cpu(init_tss, cpu);	unlazy_fpu(prev_p);	/*	 * Reload esp0, LDT and the page table pointer:	 */	tss->rsp0 = next->rsp0;	/* 	 * Switch DS and ES.	 * This won't pick up thread selector changes, but I guess that is ok.	 */	asm volatile("mov %%es,%0" : "=m" (prev->es));	if (unlikely(next->es | prev->es))		loadsegment(es, next->es); 		asm volatile ("mov %%ds,%0" : "=m" (prev->ds));	if (unlikely(next->ds | prev->ds))		loadsegment(ds, next->ds);	load_TLS(next, cpu);	/* 	 * Switch FS and GS.	 */	{ 		unsigned fsindex;		asm volatile("movl %%fs,%0" : "=r" (fsindex)); 		/* segment register != 0 always requires a reload. 		   also reload when it has changed. 		   when prev process used 64bit base always reload		   to avoid an information leak. */		if (unlikely(fsindex | next->fsindex | prev->fs)) {			loadsegment(fs, next->fsindex);			/* check if the user used a selector != 0	                 * if yes clear 64bit base, since overloaded base                         * is always mapped to the Null selector                         */			if (fsindex)			prev->fs = 0;						}		/* when next process has a 64bit base use it */		if (next->fs) 			wrmsrl(MSR_FS_BASE, next->fs); 		prev->fsindex = fsindex;	}	{ 		unsigned gsindex;		asm volatile("movl %%gs,%0" : "=r" (gsindex)); 		if (unlikely(gsindex | next->gsindex | prev->gs)) {			load_gs_index(next->gsindex);			if (gsindex)			prev->gs = 0;						}		if (next->gs)			wrmsrl(MSR_KERNEL_GS_BASE, next->gs); 		prev->gsindex = gsindex;	}	/* 	 * Switch the PDA context.	 */	prev->userrsp = read_pda(oldrsp); 	write_pda(oldrsp, next->userrsp); 	write_pda(pcurrent, next_p); 	write_pda(kernelstack, (unsigned long)next_p->thread_info + THREAD_SIZE - PDA_STACKOFFSET);	/*	 * Now maybe reload the debug registers	 */	if (unlikely(next->debugreg7)) {		loaddebug(next, 0);		loaddebug(next, 1);		loaddebug(next, 2);		loaddebug(next, 3);		/* no 4 and 5 */		loaddebug(next, 6);		loaddebug(next, 7);	}	/* 	 * Handle the IO bitmap 	 */ 	if (unlikely(prev->io_bitmap_ptr || next->io_bitmap_ptr)) {		if (next->io_bitmap_ptr)			/*			 * Copy the relevant range of the IO bitmap.			 * Normally this is 128 bytes or less: 			 */			memcpy(tss->io_bitmap, next->io_bitmap_ptr,				max(prev->io_bitmap_max, next->io_bitmap_max));		else {			/*			 * Clear any possible leftover bits:			 */			memset(tss->io_bitmap, 0xff, prev->io_bitmap_max);		}	}	disable_tsc(prev_p, next_p);	return prev_p;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/083044e63b4d10ebf9afb231bc0d34aec72169b4/process.c/buggy/arch/x86_64/kernel/process.c