forked from Bananymous/banan-os
				
			
			update main #1
			
				
			
		
		
		
	| 
						 | 
				
			
			@ -1,3 +1,4 @@
 | 
			
		|||
#pragma once
 | 
			
		||||
 | 
			
		||||
#define ALWAYS_INLINE inline __attribute__((always_inline))
 | 
			
		||||
#define ALWAYS_INLINE inline __attribute__((always_inline))
 | 
			
		||||
#define NEVER_INLINE __attribute__((noinline))
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -11,14 +11,16 @@ namespace Kernel
 | 
			
		|||
	class Interruptable
 | 
			
		||||
	{
 | 
			
		||||
	public:
 | 
			
		||||
		Interruptable() = default;
 | 
			
		||||
 | 
			
		||||
		void set_irq(int irq);
 | 
			
		||||
		void enable_interrupt();
 | 
			
		||||
		void disable_interrupt();
 | 
			
		||||
 | 
			
		||||
		virtual void handle_irq() = 0;
 | 
			
		||||
 | 
			
		||||
	protected:
 | 
			
		||||
		Interruptable() = default;
 | 
			
		||||
		~Interruptable() {}
 | 
			
		||||
 | 
			
		||||
	private:
 | 
			
		||||
		int m_irq { -1 };
 | 
			
		||||
	};
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue