Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 40237
b: refs/heads/master
c: a7933e0
h: refs/heads/master
i:
  40235: f016dce
v: v3
  • Loading branch information
Samuel Tardieu authored and Wim Van Sebroeck committed Oct 4, 2006
1 parent dae7ac0 commit fc6cff1
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c81b2996253a94278057f83a24dfa9053f0dee7a
refs/heads/master: a7933e05d46f49385841d09028ee07fae2b383f2
17 changes: 15 additions & 2 deletions trunk/drivers/char/watchdog/w83697hf_wdt.c
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,19 @@ w83697hf_set_reg(unsigned char reg, unsigned char data)
outb_p(data, W83697HF_EFDR);
}

static void
w83697hf_select_wdt(void)
{
w83697hf_unlock();
w83697hf_set_reg(0x07, 0x08); /* Switch to logic device 8 (GPIO2) */
}

static inline void
w83697hf_deselect_wdt(void)
{
w83697hf_lock();
}

static void
w83697hf_select_wd_register(void)
{
Expand Down Expand Up @@ -142,11 +155,11 @@ wdt_ctrl(int timeout)
{
spin_lock(&io_lock);

w83697hf_select_wd_register();
w83697hf_select_wdt();

w83697hf_set_reg(0xF4, timeout); /* Write Timeout counter to CRF4 */

w83697hf_unselect_wd_register();
w83697hf_deselect_wdt();

spin_unlock(&io_lock);
}
Expand Down

0 comments on commit fc6cff1

Please sign in to comment.