rem: if (isr_contents & 	ReceiveError ) {  ; }
add: WRITE_16( IMR , ReceiveOk | ReceiveError | TransmitOk | TransmitError | ReceiveOverflow | ReceiveUnderflow | ReceiveFIFOOverrun | TimeOut | SystemError );
context: rtl8139_interrupt( void *cookie ){	rtl8139_properties_t *data = (rtl8139_properties_t *)cookie;	uint8 temp8;	uint16 isr_contents;	uint16 isr_write = 0;	uint32 txstatus;	int32 retval = B_UNHANDLED_INTERRUPT; 	cpu_status status;		status = lock();		isr_contents = READ_16( ISR );	dprintf( "NIELX INTERRUPT: %u \n" , isr_contents );	if( isr_contents & ReceiveOk )	{		dprintf( "rtl8139_nielx interrupt ReceiveOk\n" );		release_sem_etc( data->input_wait , 1 , B_DO_NOT_RESCHEDULE );		// First, disable all interrupts until the read hook is finished. It will re-enable them.		WRITE_16( IMR , 0 );		retval = B_INVOKE_SCHEDULER;	}		if (isr_contents & 	ReceiveError )	{		//Do something		;	}		if (isr_contents & TransmitOk )	{		// Check each status descriptor		for (temp8 = 0 ; temp8 < 4 ; temp8++)		{			// If a register isn't used, continue next run			if ( data->transmitstatus[temp8] != 1 )				continue;			txstatus = READ_32( TSD0 + temp8 * sizeof( int32 ) );			dprintf( "run: %u txstatus: %lu Register: %lx\n" , temp8 , txstatus , TSD0 + temp8 * sizeof( int32 ) );						if ( ( txstatus & TOK ) )			{				//this one is the one!				dprintf( "NIELX INTERRUPT: TXOK, clearing register %u\n" , temp8 );				data->transmitstatus[temp8] = 0; //That's all there is to it				data->writes--;				//update next transmitid				continue;			}		}		isr_write |= TransmitOk;		retval = B_HANDLED_INTERRUPT;	}		if( isr_contents & TransmitError )	{		//		;	}		if( isr_contents & ReceiveOverflow )	{		// Discard all the current packages to be processed -- newos driver		WRITE_16( CAPR , ( READ_16( CBR ) + 16 ) % 0x1000 );		isr_write |= ReceiveOverflow;		retval = B_HANDLED_INTERRUPT;	}		if( isr_contents & ReceiveUnderflow )	{		// Most probably a link change -> TODO CHECK!		isr_write |= ReceiveUnderflow;		dprintf( "rtl8139_nielx interrupt(): BMCR: 0x%x BMSR: 0x%x\n" ,			READ_16( BMCR ) ,			READ_16( BMSR ) );		retval = B_HANDLED_INTERRUPT;	}		if ( isr_contents & ReceiveFIFOOverrun )	{		//		;	}		if ( isr_contents & TimeOut )	{		//		;	}		if ( isr_contents & SystemError )	{		//		;	}		WRITE_16( ISR , isr_write );	unlock( status );		return retval;	}