fix: set_idt_entry_value: bit shift
This commit is contained in:
		@ -15,12 +15,12 @@ static void set_idt_entry_value(uint16_t *target, uint32_t offset,
 | 
			
		||||
	target[3] = (offset >> 16) & 0xFFFF;
 | 
			
		||||
 | 
			
		||||
	// Encode the presence
 | 
			
		||||
	target[1] |= 1 << 16;
 | 
			
		||||
	target[1] |= 1 << 15;
 | 
			
		||||
 | 
			
		||||
	// Encode the CPU Privilege Levels
 | 
			
		||||
	target[1] = (0b11 << 14) & dpl;
 | 
			
		||||
	target[1] = (0b11 << 13) & dpl;
 | 
			
		||||
 | 
			
		||||
	target[1] &= ~(1 << 13);
 | 
			
		||||
	target[1] &= ~(1 << 12);
 | 
			
		||||
 | 
			
		||||
	// Encode Gate Type
 | 
			
		||||
	target[1] |= gate_type & 0x0F00;
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user