Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
[sfrench/cifs-2.6.git] / drivers / parisc / led.c
index 9a731c101d102ed11305372a6416b9b92ac3d76c..3df82fe9ce8cbf7acb80d7581709f6cdcbcb33f5 100644 (file)
@@ -66,8 +66,8 @@ static char lcd_text_default[32]  __read_mostly;
 
 
 static struct workqueue_struct *led_wq;
-static void led_work_func(void *);
-static DECLARE_WORK(led_task, led_work_func, NULL);
+static void led_work_func(struct work_struct *);
+static DECLARE_DELAYED_WORK(led_task, led_work_func);
 
 #if 0
 #define DPRINTK(x)     printk x
@@ -136,7 +136,7 @@ static int start_task(void)
 
        /* Create the work queue and queue the LED task */
        led_wq = create_singlethread_workqueue("led_wq");       
-       queue_work(led_wq, &led_task);
+       queue_delayed_work(led_wq, &led_task, 0);
 
        return 0;
 }
@@ -372,8 +372,6 @@ static __inline__ int led_get_net_activity(void)
                continue;
            if (LOOPBACK(in_dev->ifa_list->ifa_local))
                continue;
-           if (!dev->get_stats) 
-               continue;
            stats = dev->get_stats(dev);
            rx_total += stats->rx_packets;
            tx_total += stats->tx_packets;
@@ -441,7 +439,7 @@ static __inline__ int led_get_diskio_activity(void)
 
 #define LED_UPDATE_INTERVAL (1 + (HZ*19/1000))
 
-static void led_work_func (void *unused)
+static void led_work_func (struct work_struct *unused)
 {
        static unsigned long last_jiffies;
        static unsigned long count_HZ; /* counter in range 0..HZ */
@@ -588,7 +586,7 @@ int __init register_led_driver(int model, unsigned long cmd_reg, unsigned long d
 
        /* Ensure the work is queued */
        if (led_wq) {
-               queue_work(led_wq, &led_task);
+               queue_delayed_work(led_wq, &led_task, 0);
        }
 
        return 0;
@@ -629,7 +627,7 @@ void __init register_led_regions(void)
    ** avoid a race condition while writing the CMD/DATA register pair.
    **
  */
-int lcd_print( char *str )
+int lcd_print( const char *str )
 {
        int i;
 
@@ -658,7 +656,7 @@ int lcd_print( char *str )
        
        /* re-queue the work */
        if (led_wq) {
-               queue_work(led_wq, &led_task);
+               queue_delayed_work(led_wq, &led_task, 0);
        }
 
        return lcd_info.lcd_width;