···463463 module will be called pc87413_wdt.464464465465 Most people will say N.466466-466466+467467config 60XX_WDT468468 tristate "SBC-60XX Watchdog Timer"469469 depends on X86
···126126 if (!nowayout) {127127 size_t i;128128 /* note: just in case someone wrote the magic character129129- * five months ago... */129129+ five months ago... */130130 expect_close = 0;131131 /* scan to see whether or not we got the132132 magic character */
+9-8
drivers/watchdog/advantechwdt.c
···4747#define WATCHDOG_NAME "Advantech WDT"4848#define WATCHDOG_TIMEOUT 60 /* 60 sec default timeout */49495050-static struct platform_device *advwdt_platform_device; /* the watchdog platform device */5050+/* the watchdog platform device */5151+static struct platform_device *advwdt_platform_device;5152static unsigned long advwdt_is_open;5253static char adv_expect_close;5354···121120122121 for (i = 0; i != count; i++) {123122 char c;124124- if (get_user(c, buf+i))123123+ if (get_user(c, buf + i))125124 return -EFAULT;126125 if (c == 'V')127126 adv_expect_close = 42;···200199 return nonseekable_open(inode, file);201200}202201203203-static int204204-advwdt_close(struct inode *inode, struct file *file)202202+static int advwdt_close(struct inode *inode, struct file *file)205203{206204 if (adv_expect_close == 42) {207205 advwdt_disable();···288288static int __devexit advwdt_remove(struct platform_device *dev)289289{290290 misc_deregister(&advwdt_miscdev);291291- release_region(wdt_start,1);292292- if(wdt_stop != wdt_start)293293- release_region(wdt_stop,1);291291+ release_region(wdt_start, 1);292292+ if (wdt_stop != wdt_start)293293+ release_region(wdt_stop, 1);294294295295 return 0;296296}···315315{316316 int err;317317318318- printk(KERN_INFO "WDT driver for Advantech single board computer initialising.\n");318318+ printk(KERN_INFO319319+ "WDT driver for Advantech single board computer initialising.\n");319320320321 err = platform_driver_register(&advwdt_driver);321322 if (err)
+1-1
drivers/watchdog/alim1535_wdt.c
···153153 the magic character */154154 for (i = 0; i != len; i++) {155155 char c;156156- if (get_user(c, data+i))156156+ if (get_user(c, data + i))157157 return -EFAULT;158158 if (c == 'V')159159 ali_expect_release = 42;
+2-2
drivers/watchdog/alim7101_wdt.c
···125125126126static void wdt_change(int writeval)127127{128128- char tmp;128128+ char tmp;129129130130 pci_read_config_byte(alim7101_pmu, ALI_7101_WDT, &tmp);131131 if (writeval == WDT_ENABLE) {···198198 /* now scan */199199 for (ofs = 0; ofs != count; ofs++) {200200 char c;201201- if (get_user(c, buf+ofs))201201+ if (get_user(c, buf + ofs))202202 return -EFAULT;203203 if (c == 'V')204204 wdt_expect_close = 42;
+2-2
drivers/watchdog/ar7_wdt.c
···213213}214214215215static struct notifier_block ar7_wdt_notifier = {216216- .notifier_call = ar7_wdt_notify_sys216216+ .notifier_call = ar7_wdt_notify_sys,217217};218218219219static ssize_t ar7_wdt_write(struct file *file, const char *data,···230230 expect_close = 0;231231 for (i = 0; i < len; ++i) {232232 char c;233233- if (get_user(c, data+i))233233+ if (get_user(c, data + i))234234 return -EFAULT;235235 if (c == 'V')236236 expect_close = 1;
+1-1
drivers/watchdog/at32ap700x_wdt.c
···283283 */284284 for (i = 0; i != len; i++) {285285 char c;286286- if (get_user(c, data+i))286286+ if (get_user(c, data + i))287287 return -EFAULT;288288 if (c == 'V')289289 expect_release = 42;
+3-5
drivers/watchdog/eurotechwdt.c
···210210211211 for (i = 0; i != count; i++) {212212 char c;213213- if (get_user(c, buf+i))213213+ if (get_user(c, buf + i))214214 return -EFAULT;215215 if (c == 'V')216216 eur_expect_close = 42;···360360static int eurwdt_notify_sys(struct notifier_block *this, unsigned long code,361361 void *unused)362362{363363- if (code == SYS_DOWN || code == SYS_HALT) {364364- /* Turn the card off */365365- eurwdt_disable_timer();366366- }363363+ if (code == SYS_DOWN || code == SYS_HALT)364364+ eurwdt_disable_timer(); /* Turn the card off */367365368366 return NOTIFY_DONE;369367}
···405405 dmi_walk(dmi_find_cru);406406407407 /* if cru_rom_addr has been set then we found a CRU service */408408- return ((cru_rom_addr != NULL)? 0: -ENODEV);408408+ return ((cru_rom_addr != NULL) ? 0: -ENODEV);409409}410410411411/* ------------------------------------------------------------------------- */···533533 /* scan to see whether or not we got the magic char. */534534 for (i = 0; i != len; i++) {535535 char c;536536- if (get_user(c, data+i))536536+ if (get_user(c, data + i))537537 return -EFAULT;538538 if (c == 'V')539539 expect_release = 42;
+17-17
drivers/watchdog/i6300esb.c
···99 * as published by the Free Software Foundation; either version1010 * 2 of the License, or (at your option) any later version.1111 *1212- * based on i810-tco.c which is in turn based on softdog.c1212+ * based on i810-tco.c which is in turn based on softdog.c1313 *1414- * The timer is implemented in the following I/O controller hubs:1515- * (See the intel documentation on http://developer.intel.com.)1616- * 6300ESB chip : document number 300641-0031414+ * The timer is implemented in the following I/O controller hubs:1515+ * (See the intel documentation on http://developer.intel.com.)1616+ * 6300ESB chip : document number 300641-0031717 *1818 * 2004YYZZ Ross Biro1919 * Initial version 0.012020 * 2004YYZZ Ross Biro2121- * Version 0.022121+ * Version 0.022222 * 20050210 David Härdeman <david@2gen.com>2323- * Ported driver to kernel 2.62323+ * Ported driver to kernel 2.62424 */25252626/*···108108 * reload register. After this the appropriate registers can be written109109 * to once before they need to be unlocked again.110110 */111111-static inline void esb_unlock_registers(void) {111111+static inline void esb_unlock_registers(void)112112+{112113 writeb(ESB_UNLOCK1, ESB_RELOAD_REG);113114 writeb(ESB_UNLOCK2, ESB_RELOAD_REG);114115}···170169171170 /* Write timer 2 */172171 esb_unlock_registers();173173- writel(val, ESB_TIMER2_REG);172172+ writel(val, ESB_TIMER2_REG);174173175174 /* Reload */176175 esb_unlock_registers();···197196}198197199198/*200200- * /dev/watchdog handling199199+ * /dev/watchdog handling201200 */202201203202static int esb_open(struct inode *inode, struct file *file)···243242 /* scan to see whether or not we got the magic character */244243 for (i = 0; i != len; i++) {245244 char c;246246- if (get_user(c, data+i))245245+ if (get_user(c, data + i))247246 return -EFAULT;248247 if (c == 'V')249248 esb_expect_close = 42;···263262 void __user *argp = (void __user *)arg;264263 int __user *p = argp;265264 static struct watchdog_info ident = {266266- .options = WDIOF_SETTIMEOUT |265265+ .options = WDIOF_SETTIMEOUT |267266 WDIOF_KEEPALIVEPING |268267 WDIOF_MAGICCLOSE,269269- .firmware_version = 0,270270- .identity = ESB_MODULE_NAME,268268+ .firmware_version = 0,269269+ .identity = ESB_MODULE_NAME,271270 };272271273272 switch (cmd) {···325324static int esb_notify_sys(struct notifier_block *this,326325 unsigned long code, void *unused)327326{328328- if (code == SYS_DOWN || code == SYS_HALT) {329329- /* Turn the WDT off */330330- esb_timer_stop();331331- }327327+ if (code == SYS_DOWN || code == SYS_HALT)328328+ esb_timer_stop(); /* Turn the WDT off */329329+332330 return NOTIFY_DONE;333331}334332
+5-5
drivers/watchdog/iTCO_vendor_support.c
···1818 */19192020/* Module and version information */2121-#define DRV_NAME "iTCO_vendor_support"2222-#define DRV_VERSION "1.01"2323-#define DRV_RELDATE "11-Nov-2006"2121+#define DRV_NAME "iTCO_vendor_support"2222+#define DRV_VERSION "1.01"2323+#define DRV_RELDATE "11-Nov-2006"2424#define PFX DRV_NAME ": "25252626/* Includes */···37373838/* iTCO defines */3939#define SMI_EN acpibase + 0x30 /* SMI Control and Enable Register */4040-#define TCOBASE acpibase + 0x60 /* TCO base address */4141-#define TCO1_STS TCOBASE + 0x04 /* TCO1 Status Register */4040+#define TCOBASE acpibase + 0x60 /* TCO base address */4141+#define TCO1_STS TCOBASE + 0x04 /* TCO1 Status Register */42424343/* List of vendor support modes */4444/* SuperMicro Pentium 3 Era 370SSE+-OEM1/P3TSSE */
+5-5
drivers/watchdog/iTCO_wdt.c
···5555 */56565757/* Module and version information */5858-#define DRV_NAME "iTCO_wdt"5959-#define DRV_VERSION "1.03"6060-#define DRV_RELDATE "30-Apr-2008"5858+#define DRV_NAME "iTCO_wdt"5959+#define DRV_VERSION "1.03"6060+#define DRV_RELDATE "30-Apr-2008"6161#define PFX DRV_NAME ": "62626363/* Includes */···107107 TCO_ICH9, /* ICH9 */108108 TCO_ICH9R, /* ICH9R */109109 TCO_ICH9DH, /* ICH9DH */110110- TCO_ICH9DO, /* ICH9DO */110110+ TCO_ICH9DO, /* ICH9DO */111111 TCO_631XESB, /* 631xESB/632xESB */112112};113113···497497 magic character */498498 for (i = 0; i != len; i++) {499499 char c;500500- if (get_user(c, data+i))500500+ if (get_user(c, data + i))501501 return -EFAULT;502502 if (c == 'V')503503 expect_release = 42;
···241241 with an open */242242 ret = misc_register(&iop_wdt_miscdev);243243 if (ret == 0)244244- printk("iop watchdog timer: timeout %lu sec\n",244244+ printk(KERN_INFO "iop watchdog timer: timeout %lu sec\n",245245 iop_watchdog_timeout());246246247247 return ret;
+1-1
drivers/watchdog/it8712f_wdt.c
···221221 expect_close = 0;222222 for (i = 0; i < len; ++i) {223223 char c;224224- if (get_user(c, data+i))224224+ if (get_user(c, data + i))225225 return -EFAULT;226226 if (c == 'V')227227 expect_close = 42;
···9696#define CMD_GET_CLEAR_RESET_COUNT 0x8497979898/* Watchdog's Dip Switch heartbeat values */9999-static const int heartbeat_tbl [] = {9999+static const int heartbeat_tbl[] = {100100 5, /* OFF-OFF-OFF = 5 Sec */101101 10, /* OFF-OFF-ON = 10 Sec */102102 30, /* OFF-ON-OFF = 30 Sec */···219219 int option_switches;220220221221 got_fw_rev = send_command(CMD_GET_FIRMWARE_VERSION, &fw_rev_major, &fw_rev_minor);222222- if (got_fw_rev) {222222+ if (got_fw_rev)223223 sprintf(fw_ver_str, "%u.%02u", fw_rev_major, fw_rev_minor);224224- } else {224224+ else225225 sprintf(fw_ver_str, "<card no answer>");226226- }227226228227 /* Get switch settings */229228 option_switches = pcipcwd_get_option_switches();···329330{330331 int control_status;331332332332- *status=0;333333+ *status = 0;333334 control_status = inb_p(pcipcwd_private.io_addr + 1);334335 if (control_status & WD_PCI_WTRP)335336 *status |= WDIOF_CARDRESET;···367368 outb_p((control_status & WD_PCI_R2DS) | WD_PCI_WTRP, pcipcwd_private.io_addr + 1);368369369370 /* clear reset counter */370370- msb=0;371371- reset_counter=0xff;371371+ msb = 0;372372+ reset_counter = 0xff;372373 send_command(CMD_GET_CLEAR_RESET_COUNT, &msb, &reset_counter);373374374375 if (debug >= DEBUG) {···440441 /* scan to see whether or not we got the magic character */441442 for (i = 0; i != len; i++) {442443 char c;443443- if(get_user(c, data+i))444444+ if (get_user(c, data + i))444445 return -EFAULT;445446 if (c == 'V')446447 expect_release = 42;···470471471472 switch (cmd) {472473 case WDIOC_GETSUPPORT:473473- return copy_to_user(argp, &ident,474474- sizeof (ident)) ? -EFAULT : 0;474474+ return copy_to_user(argp, &ident, sizeof(ident)) ? -EFAULT : 0;475475476476 case WDIOC_GETSTATUS:477477 {···496498 {497499 int new_options, retval = -EINVAL;498500499499- if (get_user (new_options, p))501501+ if (get_user(new_options, p))500502 return -EFAULT;501503502504 if (new_options & WDIOS_DISABLECARD) {···598600 if (pcipcwd_get_temperature(&temperature))599601 return -EFAULT;600602601601- if (copy_to_user (data, &temperature, 1))603603+ if (copy_to_user(data, &temperature, 1))602604 return -EFAULT;603605604606 return 1;···623625624626static int pcipcwd_notify_sys(struct notifier_block *this, unsigned long code, void *unused)625627{626626- if (code==SYS_DOWN || code==SYS_HALT) {627627- /* Turn the WDT off */628628- pcipcwd_stop();629629- }628628+ if (code == SYS_DOWN || code == SYS_HALT)629629+ pcipcwd_stop(); /* Turn the WDT off */630630631631 return NOTIFY_DONE;632632}
+29-32
drivers/watchdog/pcwd_usb.c
···8787#define USB_PCWD_PRODUCT_ID 0x114088888989/* table of devices that work with this driver */9090-static struct usb_device_id usb_pcwd_table [] = {9090+static struct usb_device_id usb_pcwd_table[] = {9191 { USB_DEVICE(USB_PCWD_VENDOR_ID, USB_PCWD_PRODUCT_ID) },9292 { } /* Terminating entry */9393};···109109#define CMD_DISABLE_WATCHDOG CMD_ENABLE_WATCHDOG110110111111/* Watchdog's Dip Switch heartbeat values */112112-static const int heartbeat_tbl [] = {112112+static const int heartbeat_tbl[] = {113113 5, /* OFF-OFF-OFF = 5 Sec */114114 10, /* OFF-OFF-ON = 10 Sec */115115 30, /* OFF-ON-OFF = 30 Sec */···129129130130/* Structure to hold all of our device specific stuff */131131struct usb_pcwd_private {132132- struct usb_device * udev; /* save off the usb device pointer */133133- struct usb_interface * interface; /* the interface for this device */132132+ struct usb_device *udev; /* save off the usb device pointer */133133+ struct usb_interface *interface; /* the interface for this device */134134135135 unsigned int interface_number; /* the interface number used for cmd's */136136137137- unsigned char * intr_buffer; /* the buffer to intr data */137137+ unsigned char *intr_buffer; /* the buffer to intr data */138138 dma_addr_t intr_dma; /* the dma address for the intr buffer */139139 size_t intr_size; /* the size of the intr buffer */140140- struct urb * intr_urb; /* the urb used for the intr pipe */140140+ struct urb *intr_urb; /* the urb used for the intr pipe */141141142142 unsigned char cmd_command; /* The command that is reported back */143143 unsigned char cmd_data_msb; /* The data MSB that is reported back */···153153static DEFINE_MUTEX(disconnect_mutex);154154155155/* local function prototypes */156156-static int usb_pcwd_probe (struct usb_interface *interface, const struct usb_device_id *id);157157-static void usb_pcwd_disconnect (struct usb_interface *interface);156156+static int usb_pcwd_probe(struct usb_interface *interface, const struct usb_device_id *id);157157+static void usb_pcwd_disconnect(struct usb_interface *interface);158158159159/* usb specific object needed to register this driver with the usb subsystem */160160static struct usb_driver usb_pcwd_driver = {···194194 usb_pcwd->cmd_data_lsb = data[2];195195196196 /* notify anyone waiting that the cmd has finished */197197- atomic_set (&usb_pcwd->cmd_received, 1);197197+ atomic_set(&usb_pcwd->cmd_received, 1);198198199199resubmit:200200- retval = usb_submit_urb (urb, GFP_ATOMIC);200200+ retval = usb_submit_urb(urb, GFP_ATOMIC);201201 if (retval)202202 printk(KERN_ERR PFX "can't resubmit intr, usb_submit_urb failed with result %d\n",203203 retval);···223223 dbg("sending following data cmd=0x%02x msb=0x%02x lsb=0x%02x",224224 buf[0], buf[1], buf[2]);225225226226- atomic_set (&usb_pcwd->cmd_received, 0);226226+ atomic_set(&usb_pcwd->cmd_received, 0);227227228228 if (usb_control_msg(usb_pcwd->udev, usb_sndctrlpipe(usb_pcwd->udev, 0),229229 HID_REQ_SET_REPORT, HID_DT_REPORT,···236236 got_response = 0;237237 for (count = 0; (count < USB_COMMAND_TIMEOUT) && (!got_response); count++) {238238 mdelay(1);239239- if (atomic_read (&usb_pcwd->cmd_received))239239+ if (atomic_read(&usb_pcwd->cmd_received))240240 got_response = 1;241241 }242242···355355 /* scan to see whether or not we got the magic character */356356 for (i = 0; i != len; i++) {357357 char c;358358- if(get_user(c, data+i))358358+ if (get_user(c, data + i))359359 return -EFAULT;360360 if (c == 'V')361361 expect_release = 42;···383383384384 switch (cmd) {385385 case WDIOC_GETSUPPORT:386386- return copy_to_user(argp, &ident,387387- sizeof (ident)) ? -EFAULT : 0;386386+ return copy_to_user(argp, &ident, sizeof(ident)) ? -EFAULT : 0;388387389388 case WDIOC_GETSTATUS:390389 case WDIOC_GETBOOTSTATUS:···403404 {404405 int new_options, retval = -EINVAL;405406406406- if (get_user (new_options, p))407407+ if (get_user(new_options, p))407408 return -EFAULT;408409409410 if (new_options & WDIOS_DISABLECARD) {···517518518519static int usb_pcwd_notify_sys(struct notifier_block *this, unsigned long code, void *unused)519520{520520- if (code==SYS_DOWN || code==SYS_HALT) {521521- /* Turn the WDT off */522522- usb_pcwd_stop(usb_pcwd_device);523523- }521521+ if (code == SYS_DOWN || code == SYS_HALT)522522+ usb_pcwd_stop(usb_pcwd_device); /* Turn the WDT off */524523525524 return NOTIFY_DONE;526525}···563566/**564567 * usb_pcwd_delete565568 */566566-static inline void usb_pcwd_delete (struct usb_pcwd_private *usb_pcwd)569569+static inline void usb_pcwd_delete(struct usb_pcwd_private *usb_pcwd)567570{568571 usb_free_urb(usb_pcwd->intr_urb);569572 if (usb_pcwd->intr_buffer != NULL)570573 usb_buffer_free(usb_pcwd->udev, usb_pcwd->intr_size,571574 usb_pcwd->intr_buffer, usb_pcwd->intr_dma);572572- kfree (usb_pcwd);575575+ kfree(usb_pcwd);573576}574577575578/**···622625 maxp = usb_maxpacket(udev, pipe, usb_pipeout(pipe));623626624627 /* allocate memory for our device and initialize it */625625- usb_pcwd = kzalloc (sizeof(struct usb_pcwd_private), GFP_KERNEL);628628+ usb_pcwd = kzalloc(sizeof(struct usb_pcwd_private), GFP_KERNEL);626629 if (usb_pcwd == NULL) {627630 printk(KERN_ERR PFX "Out of memory\n");628631 goto error;···637640 usb_pcwd->intr_size = (le16_to_cpu(endpoint->wMaxPacketSize) > 8 ? le16_to_cpu(endpoint->wMaxPacketSize) : 8);638641639642 /* set up the memory buffer's */640640- if (!(usb_pcwd->intr_buffer = usb_buffer_alloc(udev, usb_pcwd->intr_size, GFP_ATOMIC, &usb_pcwd->intr_dma))) {643643+ usb_pcwd->intr_buffer = usb_buffer_alloc(udev, usb_pcwd->intr_size, GFP_ATOMIC, &usb_pcwd->intr_dma);644644+ if (!usb_pcwd->intr_buffer) {641645 printk(KERN_ERR PFX "Out of memory\n");642646 goto error;643647 }···672674673675 /* Get the Firmware Version */674676 got_fw_rev = usb_pcwd_send_command(usb_pcwd, CMD_GET_FIRMWARE_VERSION, &fw_rev_major, &fw_rev_minor);675675- if (got_fw_rev) {677677+ if (got_fw_rev)676678 sprintf(fw_ver_str, "%u.%02u", fw_rev_major, fw_rev_minor);677677- } else {679679+ else678680 sprintf(fw_ver_str, "<card no answer>");679679- }680681681682 printk(KERN_INFO PFX "Found card (Firmware: %s) with temp option\n",682683 fw_ver_str);···721724 }722725723726 /* we can register the device now, as it is ready */724724- usb_set_intfdata (interface, usb_pcwd);727727+ usb_set_intfdata(interface, usb_pcwd);725728726729 printk(KERN_INFO PFX "initialized. heartbeat=%d sec (nowayout=%d)\n",727730 heartbeat, nowayout);···755758 /* prevent races with open() */756759 mutex_lock(&disconnect_mutex);757760758758- usb_pcwd = usb_get_intfdata (interface);759759- usb_set_intfdata (interface, NULL);761761+ usb_pcwd = usb_get_intfdata(interface);762762+ usb_set_intfdata(interface, NULL);760763761764 mutex_lock(&usb_pcwd->mtx);762765···816819}817820818821819819-module_init (usb_pcwd_init);820820-module_exit (usb_pcwd_exit);822822+module_init(usb_pcwd_init);823823+module_exit(usb_pcwd_exit);
···215215/*216216 * Notifier for system down217217 */218218-static int219219-sbwdog_notify_sys(struct notifier_block *this, unsigned long code, void *erf)218218+static int sbwdog_notify_sys(struct notifier_block *this, unsigned long code,219219+ void *erf)220220{221221 if (code == SYS_DOWN || code == SYS_HALT) {222222 /*
+2-2
drivers/watchdog/sbc60xxwdt.c
···183183 magic character */184184 for (ofs = 0; ofs != count; ofs++) {185185 char c;186186- if (get_user(c, buf+ofs))186186+ if (get_user(c, buf + ofs))187187 return -EFAULT;188188 if (c == 'V')189189 wdt_expect_close = 42;···238238239239 switch (cmd) {240240 case WDIOC_GETSUPPORT:241241- return copy_to_user(argp, &ident, sizeof(ident))? -EFAULT : 0;241241+ return copy_to_user(argp, &ident, sizeof(ident)) ? -EFAULT : 0;242242 case WDIOC_GETSTATUS:243243 case WDIOC_GETBOOTSTATUS:244244 return put_user(0, p);
+1-1
drivers/watchdog/sc1200wdt.c
···279279 for (i = 0; i != len; i++) {280280 char c;281281282282- if (get_user(c, data+i))282282+ if (get_user(c, data + i))283283 return -EFAULT;284284 if (c == 'V')285285 expect_close = 42;
+1-1
drivers/watchdog/scx200_wdt.c
···143143 expect_close = 0;144144 for (i = 0; i < len; ++i) {145145 char c;146146- if (get_user(c, data+i))146146+ if (get_user(c, data + i))147147 return -EFAULT;148148 if (c == 'V')149149 expect_close = 42;
+2-2
drivers/watchdog/smsc37b787_wdt.c
···408408 magic character */409409 for (i = 0; i != len; i++) {410410 char c;411411- if (get_user(c, data+i))411411+ if (get_user(c, data + i))412412 return -EFAULT;413413 if (c == 'V')414414 expect_close = 42;···438438 WDIOF_SETTIMEOUT |439439 WDIOF_MAGICCLOSE,440440 .firmware_version = 0,441441- .identity = "SMsC 37B787 Watchdog"441441+ .identity = "SMsC 37B787 Watchdog",442442 };443443444444 uarg.i = (int __user *)arg;
···180180181181 for (i = 0; i != count; i++) {182182 char c;183183- if (get_user(c, buf+i))183183+ if (get_user(c, buf + i))184184 return -EFAULT;185185 if (c == 'V')186186 expect_close = 42;···278278static int wdt_notify_sys(struct notifier_block *this, unsigned long code,279279 void *unused)280280{281281- if (code == SYS_DOWN || code == SYS_HALT) {282282- /* Turn the WDT off */283283- wdt_disable();284284- }281281+ if (code == SYS_DOWN || code == SYS_HALT)282282+ wdt_disable(); /* Turn the WDT off */283283+285284 return NOTIFY_DONE;286285}287286
+5-6
drivers/watchdog/w83697hf_wdt.c
···218218219219 for (i = 0; i != count; i++) {220220 char c;221221- if (get_user(c, buf+i))221221+ if (get_user(c, buf + i))222222 return -EFAULT;223223 if (c == 'V')224224 expect_close = 42;···325325static int wdt_notify_sys(struct notifier_block *this, unsigned long code,326326 void *unused)327327{328328- if (code == SYS_DOWN || code == SYS_HALT) {329329- /* Turn the WDT off */330330- wdt_disable();331331- }328328+ if (code == SYS_DOWN || code == SYS_HALT)329329+ wdt_disable(); /* Turn the WDT off */330330+332331 return NOTIFY_DONE;333332}334333···413414 w83697hf_init();414415 if (early_disable) {415416 if (wdt_running())416416- printk (KERN_WARNING PFX "Stopping previously enabled watchdog until userland kicks in\n");417417+ printk(KERN_WARNING PFX "Stopping previously enabled watchdog until userland kicks in\n");417418 wdt_disable();418419 }419420
+9-11
drivers/watchdog/wafer5823wdt.c
···11/*22 * ICP Wafer 5823 Single Board Computer WDT driver33- * http://www.icpamerica.com/wafer_5823.php44- * May also work on other similar models33+ * http://www.icpamerica.com/wafer_5823.php44+ * May also work on other similar models55 *66 * (c) Copyright 2002 Justin Cormack <justin@street-vision.com>77 *88- * Release 0.0288+ * Release 0.0299 *1010 * Based on advantechwdt.c which is based on wdt.c.1111 * Original copyright messages:···5050/*5151 * You must set these - there is no sane way to probe for this board.5252 *5353- * To enable, write the timeout value in seconds (1 to 255) to I/O5454- * port WDT_START, then read the port to start the watchdog. To pat5555- * the dog, read port WDT_STOP to stop the timer, then read WDT_START5656- * to restart it again.5353+ * To enable, write the timeout value in seconds (1 to 255) to I/O5454+ * port WDT_START, then read the port to start the watchdog. To pat5555+ * the dog, read port WDT_STOP to stop the timer, then read WDT_START5656+ * to restart it again.5757 */58585959static int wdt_stop = 0x843;···8787 inb_p(wdt_start);8888}89899090-static void9191-wafwdt_stop(void)9090+static void wafwdt_stop(void)9291{9392 /* stop watchdog */9493 inb_p(wdt_stop);···198199 return nonseekable_open(inode, file);199200}200201201201-static int202202-wafwdt_close(struct inode *inode, struct file *file)202202+static int wafwdt_close(struct inode *inode, struct file *file)203203{204204 if (expect_close == 42)205205 wafwdt_stop();
+1-1
drivers/watchdog/wd501p.h
···1212 * http://www.cymru.net1313 *1414 * This driver is provided under the GNU General Public License, incorporated1515- * herein by reference. The driver is provided without warranty or 1515+ * herein by reference. The driver is provided without warranty or1616 * support.1717 *1818 * Release 0.04.
···381381382382 for (i = 0; i != count; i++) {383383 char c;384384- if (get_user(c, buf+i))384384+ if (get_user(c, buf + i))385385 return -EFAULT;386386 if (c == 'V')387387 expect_close = 42;