Index: kernel-patches/drivers/net/ns7520_eth.c
===================================================================
***************
*** 3,9 ****
   *  Copyright 2003 by FS Forth-Systeme GmbH.
   *  All rights reserved.
   *
!  *  $Id: ns7520_eth.c,v 1.3 2005-12-07 15:32:52 bwesterm Exp $
   *  @Author: Markus Pietrek
   *  @Descr: The ethernet driver for the NS7520. It is partly based on
   *          the netarm_eth.c and snull.c and some hints (of yet
--- 3,9 ----
   *  Copyright 2003 by FS Forth-Systeme GmbH.
   *  All rights reserved.
   *
!  *  $Id: ns7520_eth.c,v 1.4 2006-11-30 10:51:31 bwesterm Exp $
   *  @Author: Markus Pietrek
   *  @Descr: The ethernet driver for the NS7520. It is partly based on
   *          the netarm_eth.c and snull.c and some hints (of yet
***************
*** 135,140 ****
--- 135,143 ----
                                           // information 10/100 half/full auto
  	                                 // 0xff is empty
  	unsigned int unLastRxDmaDescIndex; // last dma desc index used
+ #ifdef CONFIG_FS_MODULE_DIGI_ME
+ 	struct tasklet_struct led_tasklet;
+ #endif
  };
  
  /* ConnectME led timer */
***************
*** 142,147 ****
--- 145,151 ----
  struct timer_list led_timer;
  static void ns7520_led_timer_timedout(unsigned long);
  static void ns7520_MEled_on_off(void);
+ static void ns7520_led_tasklet(unsigned long d);
  #define ETH_ACTIVITY_TTL_MS	20
  #define ETH_ACTIVITY_TTL	(((ETH_ACTIVITY_TTL_MS * HZ)/1000) + 1)
  #endif
***************
*** 334,339 ****
--- 338,348 ----
  #endif // CONFIG_FS_EEPROM_MAC
  	memcpy( pDev->dev_addr, aucMACAddr, ETH_ALEN );
  
+ #ifdef CONFIG_FS_MODULE_DIGI_ME
+ 	init_timer(&led_timer);
+ 	led_timer.function = ns7520_led_timer_timedout;
+ 	tasklet_init(&pPriv->led_tasklet, ns7520_led_tasklet, (unsigned long)pPriv);
+ #endif
  
  	ns7520_irqs_disable();
  	ns7520_dma_disable( 3 );
***************
*** 450,455 ****
--- 459,468 ----
  	    pPriv->pTxSkb = NULL;
  	}
  	
+ #ifdef CONFIG_FS_MODULE_DIGI_ME
+ 	tasklet_disable(&pPriv->led_tasklet);
+ #endif
+ 
  	kfree( pPriv );
  
  
***************
*** 599,606 ****
  		/* Timer not running */
  		/* flash the green led on DIGI ConnectME to on */
  		*get_gen_reg_addr(NETARM_GEN_PORTC) &= 0xFFFFFFBF;
- 		init_timer(&led_timer);
- 		led_timer.function = ns7520_led_timer_timedout;
  		led_timer.expires = jiffies + ETH_ACTIVITY_TTL;
  		add_timer(&led_timer);
  	} else {
--- 612,617 ----
***************
*** 608,613 ****
--- 619,635 ----
  		mod_timer(&led_timer, jiffies + ETH_ACTIVITY_TTL);
  	}
  }
+ 
+ 
+ /***********************************************************************
+  * @Function: ns7520_led_tasklet
+  * @Return:
+  * @Descr:
+  ***********************************************************************/
+ static void ns7520_led_tasklet(unsigned long d)
+ {
+ 	ns7520_MEled_on_off();
+ }
  #endif
  
  /***********************************************************************
***************
*** 634,640 ****
  	spin_lock( &pPriv->lock );
  
  #ifdef CONFIG_FS_MODULE_DIGI_ME
! 	ns7520_MEled_on_off();
  #endif	
  	// now handle hardware request
  
--- 656,663 ----
  	spin_lock( &pPriv->lock );
  
  #ifdef CONFIG_FS_MODULE_DIGI_ME
! 	if (pPriv->led_tasklet.func != 0)
! 		tasklet_schedule(&pPriv->led_tasklet);
  #endif	
  	// now handle hardware request
  
***************
*** 784,790 ****
  	spin_lock( &pPriv->lock );
  
  #ifdef CONFIG_FS_MODULE_DIGI_ME
! 	ns7520_MEled_on_off();
  #endif	
  
  	// now handle hardware request
--- 807,814 ----
  	spin_lock( &pPriv->lock );
  
  #ifdef CONFIG_FS_MODULE_DIGI_ME
! 	if (pPriv->led_tasklet.func != 0)
! 		tasklet_schedule(&pPriv->led_tasklet);
  #endif	
  
  	// now handle hardware request
