Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a77dba7e authored by Wim Van Sebroeck's avatar Wim Van Sebroeck
Browse files

[WATCHDOG] Some more general cleanup



Clean-up the watchdog drivers so that checkpatch.pl get's happy...

Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
parent 0a7e6582
Loading
Loading
Loading
Loading
+11 −4
Original line number Diff line number Diff line
@@ -322,7 +322,8 @@ static int wdt_notify_sys(struct notifier_block *this,
		 * watchdog on reboot with no heartbeat
		 */
		wdt_change(WDT_ENABLE);
		printk(KERN_INFO PFX "Watchdog timer is now enabled with no heartbeat - should reboot in ~1 second.\n");
		printk(KERN_INFO PFX "Watchdog timer is now enabled "
			"with no heartbeat - should reboot in ~1 second.\n");
	}
	return NOTIFY_DONE;
}
@@ -374,12 +375,17 @@ static int __init alim7101_wdt_init(void)
	pci_dev_put(ali1543_south);
	if ((tmp & 0x1e) == 0x00) {
		if (!use_gpio) {
			printk(KERN_INFO PFX "Detected old alim7101 revision 'a1d'.  If this is a cobalt board, set the 'use_gpio' module parameter.\n");
			printk(KERN_INFO PFX
				"Detected old alim7101 revision 'a1d'.  "
				"If this is a cobalt board, set the 'use_gpio' "
				"module parameter.\n");
			goto err_out;
		}
		nowayout = 1;
	} else if ((tmp & 0x1e) != 0x12 && (tmp & 0x1e) != 0x00) {
		printk(KERN_INFO PFX "ALi 1543 South-Bridge does not have the correct revision number (???1001?) - WDT not set\n");
		printk(KERN_INFO PFX
			"ALi 1543 South-Bridge does not have the correct "
			"revision number (???1001?) - WDT not set\n");
		goto err_out;
	}

@@ -409,7 +415,8 @@ static int __init alim7101_wdt_init(void)
	if (nowayout)
		__module_get(THIS_MODULE);

	printk(KERN_INFO PFX "WDT driver for ALi M7101 initialised. timeout=%d sec (nowayout=%d)\n",
	printk(KERN_INFO PFX "WDT driver for ALi M7101 initialised. "
					"timeout=%d sec (nowayout=%d)\n",
		timeout, nowayout);
	return 0;

+2 −1
Original line number Diff line number Diff line
@@ -268,7 +268,8 @@ static int __init at91_wdt_init(void)
	   if not reset to the default */
	if (at91_wdt_settimeout(wdt_time)) {
		at91_wdt_settimeout(WDT_DEFAULT_TIME);
		pr_info("at91_wdt: wdt_time value must be 1 <= wdt_time <= 256, using %d\n", wdt_time);
		pr_info("at91_wdt: wdt_time value must be 1 <= wdt_time <= 256"
						", using %d\n", wdt_time);
	}

	return platform_driver_register(&at91wdt_driver);
+10 −4
Original line number Diff line number Diff line
@@ -27,10 +27,15 @@
#include <linux/uaccess.h>
#include <asm/blackfin.h>

#define stamp(fmt, args...) pr_debug("%s:%i: " fmt "\n", __func__, __LINE__, ## args)
#define stamp(fmt, args...) \
	pr_debug("%s:%i: " fmt "\n", __func__, __LINE__, ## args)
#define stampit() stamp("here i am")
#define pr_devinit(fmt, args...) ({ static const __devinitconst char __fmt[] = fmt; printk(__fmt, ## args); })
#define pr_init(fmt, args...) ({ static const __initconst char __fmt[] = fmt; printk(__fmt, ## args); })
#define pr_devinit(fmt, args...) \
	({ static const __devinitconst char __fmt[] = fmt; \
	printk(__fmt, ## args); })
#define pr_init(fmt, args...) \
	({ static const __initconst char __fmt[] = fmt; \
	printk(__fmt, ## args); })

#define WATCHDOG_NAME "bfin-wdt"
#define PFX WATCHDOG_NAME ": "
@@ -476,7 +481,8 @@ static int __init bfin_wdt_init(void)
		return ret;
	}

	bfin_wdt_device = platform_device_register_simple(WATCHDOG_NAME, -1, NULL, 0);
	bfin_wdt_device = platform_device_register_simple(WATCHDOG_NAME,
								-1, NULL, 0);
	if (IS_ERR(bfin_wdt_device)) {
		pr_init(KERN_ERR PFX "unable to register device\n");
		platform_driver_unregister(&bfin_wdt_driver);
+3 −3
Original line number Diff line number Diff line
@@ -154,9 +154,9 @@ static struct cpwd *cpwd_device;

static struct timer_list cpwd_timer;

static int wd0_timeout = 0;
static int wd1_timeout = 0;
static int wd2_timeout = 0;
static int wd0_timeout;
static int wd1_timeout;
static int wd2_timeout;

module_param(wd0_timeout, int, 0);
MODULE_PARM_DESC(wd0_timeout, "Default watchdog0 timeout in 1/10secs");
+2 −2
Original line number Diff line number Diff line
@@ -293,8 +293,8 @@ static int __init ks8695_wdt_init(void)
	   if not reset to the default */
	if (ks8695_wdt_settimeout(wdt_time)) {
		ks8695_wdt_settimeout(WDT_DEFAULT_TIME);
		pr_info("ks8695_wdt: wdt_time value must be 1 <= wdt_time <= %i, using %d\n",
							wdt_time, WDT_MAX_TIME);
		pr_info("ks8695_wdt: wdt_time value must be 1 <= wdt_time <= %i"
					", using %d\n", wdt_time, WDT_MAX_TIME);
	}
	return platform_driver_register(&ks8695wdt_driver);
}
Loading