[WATCHDOG] v2.6.27-rc watchdog fixes - Kernel

This is a discussion on [WATCHDOG] v2.6.27-rc watchdog fixes - Kernel ; Hi Linus, Please pull from 'master' branch of git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git or if master.kernel.org hasn't synced up yet: master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git This will update the following files: MAINTAINERS | 6 ------ drivers/watchdog/Makefile | 5 ++++- drivers/watchdog/at91rm9200_wdt.c | 2 +- drivers/watchdog/ixp4xx_wdt.c | 2 +- drivers/watchdog/shwdt.c ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: [WATCHDOG] v2.6.27-rc watchdog fixes

  1. [WATCHDOG] v2.6.27-rc watchdog fixes

    Hi Linus,

    Please pull from 'master' branch of
    git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git
    or if master.kernel.org hasn't synced up yet:
    master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git

    This will update the following files:

    MAINTAINERS | 6 ------
    drivers/watchdog/Makefile | 5 ++++-
    drivers/watchdog/at91rm9200_wdt.c | 2 +-
    drivers/watchdog/ixp4xx_wdt.c | 2 +-
    drivers/watchdog/shwdt.c | 24 ++++++++++++------------
    drivers/watchdog/txx9wdt.c | 2 +-
    drivers/watchdog/wdt285.c | 2 +-
    7 files changed, 20 insertions(+), 23 deletions(-)

    with these Changes:

    Author: Adrian Bunk
    Date: Sun Aug 10 14:03:41 2008 +0300

    [WATCHDOG] fix watchdog/ixp4xx_wdt.c compilation

    This patch fixes the following compile error caused by
    commit 20d35f3e50ea7e573f9568b9fce4e98523aaee5d
    ([WATCHDOG 22/57] ixp4xx_wdt: unlocked_ioctl):

    <-- snip -->

    ...
    CC drivers/watchdog/ixp4xx_wdt.o
    ixp4xx_wdt.c:32: error: expected '=', ',', ';', 'asm' or '__attribute__'
    ixp4xx_wdt.c: In function 'wdt_enable':
    ixp4xx_wdt.c:41: error: 'wdt_lock' undeclared (first use in this
    ixp4xx_wdt.c:41: error: (Each undeclared identifier is reported only
    ixp4xx_wdt.c:41: error: for each function it appears in.)
    ixp4xx_wdt.c: In function 'wdt_disable':
    ixp4xx_wdt.c:52: error: 'wdt_lock' undeclared (first use in this
    ixp4xx_wdt.c: In function 'ixp4xx_wdt_init':
    ixp4xx_wdt.c:186: error: 'wdt_lock' undeclared (first use in this
    make[3]: *** [drivers/watchdog/ixp4xx_wdt.o] Error 1

    <-- snip -->

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Adrian Bunk
    Date: Fri Aug 8 19:03:46 2008 +0300

    [WATCHDOG] fix watchdog/wdt285.c compilation

    This patch fixes the following compile error caused by
    commit d0e58eed05f9baf77c4f75e794ae245f6dae240a
    ([WATCHDOG 55/57] wdt285: switch to unlocked_ioctl and tidy up ...):

    <-- snip -->

    ...
    CC [M] drivers/watchdog/wdt285.o
    wdt285.c: In function 'footbridge_watchdog_init':
    wdt285.c:211: error: 'KERN_WARN' undeclared (first use in this function)
    wdt285.c:211: error: (Each undeclared identifier is reported only once
    wdt285.c:211: error: for each function it appears in.)
    wdt285.c:212: error: expected ')' before string constant
    make[3]: *** [drivers/watchdog/wdt285.o] Error 1

    <-- snip -->

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Adrian Bunk
    Date: Fri Aug 8 18:57:45 2008 +0300

    [WATCHDOG] fix watchdog/at91rm9200_wdt.c compilation

    This patch fixes the following compile error:

    <-- snip -->

    ...
    CC drivers/watchdog/at91rm9200_wdt.o
    at91rm9200_wdt.c:188: error: 'at91_wdt_ioctl' undeclared here (not in a
    make[3]: *** [drivers/watchdog/at91rm9200_wdt.o] Error 1

    <-- snip -->

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Adrian Bunk
    Date: Fri Aug 8 18:39:11 2008 +0300

    [WATCHDOG] fix watchdog/shwdt.c compilation

    This patch fixes the following compile errors caused by
    commit 70b814ec1a484279a51bf9f7193551b996627247
    ([WATCHDOG 45/57] shwdt: coding style, cleanup, switch to unlocked_io):

    <-- snip -->

    ...
    CC drivers/watchdog/shwdt.o
    shwdt.c:64: error: 'WTCSR_CKS_4096' undeclared here (not in a function)
    shwdt.c: In function 'sh_wdt_start':
    shwdt.c:92: error: 'wdt_lock' undeclared (first use in this function)
    shwdt.c:92: error: (Each undeclared identifier is reported only once
    shwdt.c:92: error: for each function it appears in.)
    shwdt.c:97: error: implicit declaration of function 'sh_wdt_read_csr'
    shwdt.c:98: error: 'WTCSR_WT' undeclared (first use in this function)
    shwdt.c:99: error: implicit declaration of function 'sh_wdt_write_csr'
    shwdt.c:101: error: implicit declaration of function 'sh_wdt_write_cnt'
    shwdt.c:112: error: 'WTCSR_TME' undeclared (first use in this function)
    shwdt.c:113: error: 'WTCSR_RSTS' undeclared (first use in this function)
    shwdt.c: In function 'sh_wdt_stop':
    shwdt.c:142: error: 'wdt_lock' undeclared (first use in this function)
    shwdt.c:147: error: 'WTCSR_TME' undeclared (first use in this function)
    shwdt.c: In function 'sh_wdt_keepalive':
    shwdt.c:160: error: 'wdt_lock' undeclared (first use in this function)
    shwdt.c: In function 'sh_wdt_set_heartbeat':
    shwdt.c:176: error: 'wdt_lock' undeclared (first use in this function)
    shwdt.c: In function 'sh_wdt_ping':
    shwdt.c:192: error: 'wdt_lock' undeclared (first use in this function)
    shwdt.c:197: error: 'WTCSR_IOVF' undeclared (first use in this function)
    shwdt.c: At top level:
    shwdt.c:417: error: conflicting type qualifiers for 'sh_wdt_info'
    shwdt.c:71: error: previous declaration of 'sh_wdt_info' was here
    make[3]: *** [drivers/watchdog/shwdt.o] Error 1

    <-- snip -->

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Adrian Bunk
    Date: Fri Aug 8 18:18:46 2008 +0300

    [WATCHDOG] fix watchdog/txx9wdt.c compilation

    This patch fixes the following compile error caused by
    commit 8dc244f7deac4c0e95ce0ffd26f494bb6e1534c0
    ([WATCHDOG 48/57] txx9: Fix locking, switch to unlocked_ioctl):

    <-- snip -->

    ...
    CC drivers/watchdog/txx9wdt.o
    txx9wdt.c:48: warning: type defaults to 'int' in declaration of
    txx9wdt.c:48: warning: parameter names (without types) in function
    txx9wdt.c: In function 'txx9wdt_ping':
    txx9wdt.c:52: error: 'txx9_lock' undeclared (first use in this function)
    txx9wdt.c:52: error: (Each undeclared identifier is reported only once
    txx9wdt.c:52: error: for each function it appears in.)
    txx9wdt.c: In function 'txx9wdt_start':
    txx9wdt.c:59: error: 'txx9_lock' undeclared (first use in this function)
    txx9wdt.c: In function 'txx9wdt_stop':
    txx9wdt.c:71: error: 'txx9_lock' undeclared (first use in this function)
    make[3]: *** [drivers/watchdog/txx9wdt.o] Error 1

    <-- snip -->

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Adrian Bunk
    Date: Thu Aug 7 00:10:52 2008 +0300

    [WATCHDOG] MAINTAINERS: remove ZF MACHZ WATCHDOG entry

    - maintainer has not been active for years
    - maintainer email bounces
    - URL no longer exists
    - covered by the WATCHDOG DEVICE DRIVERS entry

    Signed-off-by: Adrian Bunk
    Signed-off-by: Wim Van Sebroeck

    Author: Jean Delvare
    Date: Fri Aug 8 10:29:21 2008 +0200

    [WATCHDOG] Fix build with CONFIG_ITCO_VENDOR_SUPPORT=n

    The problem is that iTCO_vendor_support.ko is still being built while
    iTCO_vendor.h claims that its functions do not exist. The following
    Makefile update fixes that. It causes iTCO_vendor_support.ko to no
    longer be built if CONFIG_ITCO_VENDOR_SUPPORT=n.

    Signed-off-by: Jean Delvare
    Signed-off-by: Wim Van Sebroeck

    The Changes can also be looked at on:
    http://www.kernel.org/git/?p=linux/k....git;a=summary

    For completeness, I added the overal diff below.

    Greetings,
    Wim.

    ================================================== ==============================
    diff --git a/MAINTAINERS b/MAINTAINERS
    index 41d7a1e..b343814 100644
    --- a/MAINTAINERS
    +++ b/MAINTAINERS
    @@ -4683,12 +4683,6 @@ L: linux-wireless@vger.kernel.org
    L: zd1211-devs@lists.sourceforge.net (subscribers-only)
    S: Maintained

    -ZF MACHZ WATCHDOG
    -P: Fernando Fuganti
    -M: fuganti@netbank.com.br
    -W: http://cvs.conectiva.com.br/drivers/ZFL-watchdog/
    -S: Maintained
    -
    ZR36067 VIDEO FOR LINUX DRIVER
    P: Ronald Bultje
    M: rbultje@ronald.bitfreak.net
    diff --git a/drivers/watchdog/Makefile b/drivers/watchdog/Makefile
    index 049c918..ca3dc04 100644
    --- a/drivers/watchdog/Makefile
    +++ b/drivers/watchdog/Makefile
    @@ -66,7 +66,10 @@ obj-$(CONFIG_IB700_WDT) += ib700wdt.o
    obj-$(CONFIG_IBMASR) += ibmasr.o
    obj-$(CONFIG_WAFER_WDT) += wafer5823wdt.o
    obj-$(CONFIG_I6300ESB_WDT) += i6300esb.o
    -obj-$(CONFIG_ITCO_WDT) += iTCO_wdt.o iTCO_vendor_support.o
    +obj-$(CONFIG_ITCO_WDT) += iTCO_wdt.o
    +ifeq ($(CONFIG_ITCO_VENDOR_SUPPORT),y)
    +obj-$(CONFIG_ITCO_WDT) += iTCO_vendor_support.o
    +endif
    obj-$(CONFIG_IT8712F_WDT) += it8712f_wdt.o
    obj-$(CONFIG_HP_WATCHDOG) += hpwdt.o
    obj-$(CONFIG_SC1200_WDT) += sc1200wdt.o
    diff --git a/drivers/watchdog/at91rm9200_wdt.c b/drivers/watchdog/at91rm9200_wdt.c
    index bacd867..d061f0a 100644
    --- a/drivers/watchdog/at91rm9200_wdt.c
    +++ b/drivers/watchdog/at91rm9200_wdt.c
    @@ -128,7 +128,7 @@ static struct watchdog_info at91_wdt_info = {
    /*
    * Handle commands from user-space.
    */
    -static long at91_wdt_ioct(struct file *file,
    +static long at91_wdt_ioctl(struct file *file,
    unsigned int cmd, unsigned long arg)
    {
    void __user *argp = (void __user *)arg;
    diff --git a/drivers/watchdog/ixp4xx_wdt.c b/drivers/watchdog/ixp4xx_wdt.c
    index 41264a5..8302ef0 100644
    --- a/drivers/watchdog/ixp4xx_wdt.c
    +++ b/drivers/watchdog/ixp4xx_wdt.c
    @@ -29,7 +29,7 @@ static int nowayout = WATCHDOG_NOWAYOUT;
    static int heartbeat = 60; /* (secs) Default is 1 minute */
    static unsigned long wdt_status;
    static unsigned long boot_status;
    -static spin_lock_t wdt_lock;
    +static DEFINE_SPINLOCK(wdt_lock);

    #define WDT_TICK_RATE (IXP4XX_PERIPHERAL_BUS_CLOCK * 1000000UL)

    diff --git a/drivers/watchdog/shwdt.c b/drivers/watchdog/shwdt.c
    index 824125a..cdc7138 100644
    --- a/drivers/watchdog/shwdt.c
    +++ b/drivers/watchdog/shwdt.c
    @@ -30,7 +30,7 @@
    #include
    #include
    #include
    -#include
    +#include

    #define PFX "shwdt: "

    @@ -68,7 +68,7 @@ static int clock_division_ratio = WTCSR_CKS_4096;
    static void sh_wdt_ping(unsigned long data);

    static unsigned long shwdt_is_open;
    -static struct watchdog_info sh_wdt_info;
    +static const struct watchdog_info sh_wdt_info;
    static char shwdt_expect_close;
    static DEFINE_TIMER(timer, sh_wdt_ping, 0, 0);
    static unsigned long next_heartbeat;
    @@ -89,7 +89,7 @@ static void sh_wdt_start(void)
    __u8 csr;
    unsigned long flags;

    - spin_lock_irqsave(&wdt_lock, flags);
    + spin_lock_irqsave(&shwdt_lock, flags);

    next_heartbeat = jiffies + (heartbeat * HZ);
    mod_timer(&timer, next_ping_period(clock_division_ratio));
    @@ -127,7 +127,7 @@ static void sh_wdt_start(void)
    csr &= ~RSTCSR_RSTS;
    sh_wdt_write_rstcsr(csr);
    #endif
    - spin_unlock_irqrestore(&wdt_lock, flags);
    + spin_unlock_irqrestore(&shwdt_lock, flags);
    }

    /**
    @@ -139,14 +139,14 @@ static void sh_wdt_stop(void)
    __u8 csr;
    unsigned long flags;

    - spin_lock_irqsave(&wdt_lock, flags);
    + spin_lock_irqsave(&shwdt_lock, flags);

    del_timer(&timer);

    csr = sh_wdt_read_csr();
    csr &= ~WTCSR_TME;
    sh_wdt_write_csr(csr);
    - spin_unlock_irqrestore(&wdt_lock, flags);
    + spin_unlock_irqrestore(&shwdt_lock, flags);
    }

    /**
    @@ -157,9 +157,9 @@ static inline void sh_wdt_keepalive(void)
    {
    unsigned long flags;

    - spin_lock_irqsave(&wdt_lock, flags);
    + spin_lock_irqsave(&shwdt_lock, flags);
    next_heartbeat = jiffies + (heartbeat * HZ);
    - spin_unlock_irqrestore(&wdt_lock, flags);
    + spin_unlock_irqrestore(&shwdt_lock, flags);
    }

    /**
    @@ -173,9 +173,9 @@ static int sh_wdt_set_heartbeat(int t)
    if (unlikely(t < 1 || t > 3600)) /* arbitrary upper limit */
    return -EINVAL;

    - spin_lock_irqsave(&wdt_lock, flags);
    + spin_lock_irqsave(&shwdt_lock, flags);
    heartbeat = t;
    - spin_unlock_irqrestore(&wdt_lock, flags);
    + spin_unlock_irqrestore(&shwdt_lock, flags);
    return 0;
    }

    @@ -189,7 +189,7 @@ static void sh_wdt_ping(unsigned long data)
    {
    unsigned long flags;

    - spin_lock_irqsave(&wdt_lock, flags);
    + spin_lock_irqsave(&shwdt_lock, flags);
    if (time_before(jiffies, next_heartbeat)) {
    __u8 csr;

    @@ -203,7 +203,7 @@ static void sh_wdt_ping(unsigned long data)
    } else
    printk(KERN_WARNING PFX "Heartbeat lost! Will not ping "
    "the watchdog\n");
    - spin_unlock_irqrestore(&wdt_lock, flags);
    + spin_unlock_irqrestore(&shwdt_lock, flags);
    }

    /**
    diff --git a/drivers/watchdog/txx9wdt.c b/drivers/watchdog/txx9wdt.c
    index dbbc018..6adab77 100644
    --- a/drivers/watchdog/txx9wdt.c
    +++ b/drivers/watchdog/txx9wdt.c
    @@ -45,7 +45,7 @@ static unsigned long txx9wdt_alive;
    static int expect_close;
    static struct txx9_tmr_reg __iomem *txx9wdt_reg;
    static struct clk *txx9_imclk;
    -static DECLARE_LOCK(txx9_lock);
    +static DEFINE_SPINLOCK(txx9_lock);

    static void txx9wdt_ping(void)
    {
    diff --git a/drivers/watchdog/wdt285.c b/drivers/watchdog/wdt285.c
    index c8d7f1b..db362c3 100644
    --- a/drivers/watchdog/wdt285.c
    +++ b/drivers/watchdog/wdt285.c
    @@ -208,7 +208,7 @@ static int __init footbridge_watchdog_init(void)
    soft_margin);

    if (machine_is_cats())
    - printk(KERN_WARN
    + printk(KERN_WARNING
    "Warning: Watchdog reset may not work on this machine.\n");
    return 0;
    }
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  2. Re: [WATCHDOG] v2.6.27-rc watchdog fixes

    On Sun, Aug 10, 2008 at 10:45:27PM +0200, Wim Van Sebroeck wrote:
    > Hi Linus,
    >
    > Please pull from 'master' branch of
    > git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git
    > or if master.kernel.org hasn't synced up yet:
    > master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git
    >
    > This will update the following files:
    >
    > MAINTAINERS | 6 ------
    > drivers/watchdog/Makefile | 5 ++++-
    > drivers/watchdog/at91rm9200_wdt.c | 2 +-
    > drivers/watchdog/ixp4xx_wdt.c | 2 +-
    > drivers/watchdog/shwdt.c | 24 ++++++++++++------------
    > drivers/watchdog/txx9wdt.c | 2 +-
    > drivers/watchdog/wdt285.c | 2 +-
    > 7 files changed, 20 insertions(+), 23 deletions(-)


    Note that s3c2410_wdt still gives an additional warning that I've
    fixed in my set of ARM watchdog fixes.

    It would be nice to get _all_ the issues resolved.

    --
    Russell King
    Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
    maintainer of:
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  3. Re: [WATCHDOG] v2.6.27-rc watchdog fixes

    Hi Russell,

    > Note that s3c2410_wdt still gives an additional warning that I've
    > fixed in my set of ARM watchdog fixes.


    Where can I find your patch-set?

    Thanks in advance,
    Wim.

    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  4. Re: [WATCHDOG] v2.6.27-rc watchdog fixes

    On Mon, Aug 11, 2008 at 08:36:04PM +0200, Wim Van Sebroeck wrote:
    > Hi Russell,
    >
    > > Note that s3c2410_wdt still gives an additional warning that I've
    > > fixed in my set of ARM watchdog fixes.

    >
    > Where can I find your patch-set?


    It's in part of my general ARM updates, and I combined Adrian's three
    patches together, along with the remaining bits from my s3c2410 patch.
    Here's the mbox mail corresponding with the commit:

    From rmk Sun Aug 10 23:28:46 2008
    References:
    Message-ID:
    From: Russell King
    Date: Sun, 10 Aug 2008 23:28:46 +0100
    Content-type: text/plain; charset="utf-8"
    Content-Disposition: inline
    Content-Transfer-Encoding: 8bit
    Mime-Version: 1.0
    Subject: Re: [PATCH] [ARM] Fix a pile of broken watchdog drivers

    From: Adrian Bunk

    These patches from Adrian fix:
    - ixp4xx_wdt: 20d35f3e50ea7e573f9568b9fce4e98523aaee5d
    CC drivers/watchdog/ixp4xx_wdt.o
    ixp4xx_wdt.c:32: error: expected '=', ',', ';', 'asm' or '__attribute__'
    ixp4xx_wdt.c: In function 'wdt_enable':
    ixp4xx_wdt.c:41: error: 'wdt_lock' undeclared (first use in this
    ixp4xx_wdt.c:41: error: (Each undeclared identifier is reported only
    ixp4xx_wdt.c:41: error: for each function it appears in.)
    ixp4xx_wdt.c: In function 'wdt_disable':
    ixp4xx_wdt.c:52: error: 'wdt_lock' undeclared (first use in this
    ixp4xx_wdt.c: In function 'ixp4xx_wdt_init':
    ixp4xx_wdt.c:186: error: 'wdt_lock' undeclared (first use in this
    make[3]: *** [drivers/watchdog/ixp4xx_wdt.o] Error 1

    - at91rm9200_wdt: 2760600da2a13d5a2a335ba012d0f3ad5df4c098
    CC drivers/watchdog/at91rm9200_wdt.o
    at91rm9200_wdt.c:188: error: 'at91_wdt_ioctl' undeclared here (not in a
    make[3]: *** [drivers/watchdog/at91rm9200_wdt.o] Error 1

    - wdt285: d0e58eed05f9baf77c4f75e794ae245f6dae240a
    CC [M] drivers/watchdog/wdt285.o
    wdt285.c: In function 'footbridge_watchdog_init':
    wdt285.c:211: error: 'KERN_WARN' undeclared (first use in this function)
    wdt285.c:211: error: (Each undeclared identifier is reported only once
    wdt285.c:211: error: for each function it appears in.)
    wdt285.c:212: error: expected ')' before string constant
    make[3]: *** [drivers/watchdog/wdt285.o] Error 1

    And this patch from rmk:
    - s3c2410_wdt: 41dc8b72e37c514f7332cbc3f3dd864910c2a1fa
    CC drivers/watchdog/s3c2410_wdt.o
    s3c2410_wdt.c: In function `s3c2410wdt_start':
    s3c2410_wdt.c:161: warning: `return' with a value, in function returning void

    Reported-by: Adrian Bunk
    Signed-off-by: Adrian Bunk
    Signed-off-by: Russell King
    ---
    drivers/watchdog/at91rm9200_wdt.c | 4 ++--
    drivers/watchdog/ixp4xx_wdt.c | 2 +-
    drivers/watchdog/s3c2410_wdt.c | 2 --
    drivers/watchdog/wdt285.c | 2 +-
    4 files changed, 4 insertions(+), 6 deletions(-)

    diff --git a/drivers/watchdog/at91rm9200_wdt.c b/drivers/watchdog/at91rm9200_wdt.c
    index bacd867..ba01dac 100644
    --- a/drivers/watchdog/at91rm9200_wdt.c
    +++ b/drivers/watchdog/at91rm9200_wdt.c
    @@ -128,8 +128,8 @@ static struct watchdog_info at91_wdt_info = {
    /*
    * Handle commands from user-space.
    */
    -static long at91_wdt_ioct(struct file *file,
    - unsigned int cmd, unsigned long arg)
    +static long at91_wdt_ioctl(struct file *file,
    + unsigned int cmd, unsigned long arg)
    {
    void __user *argp = (void __user *)arg;
    int __user *p = argp;
    diff --git a/drivers/watchdog/ixp4xx_wdt.c b/drivers/watchdog/ixp4xx_wdt.c
    index 41264a5..8302ef0 100644
    --- a/drivers/watchdog/ixp4xx_wdt.c
    +++ b/drivers/watchdog/ixp4xx_wdt.c
    @@ -29,7 +29,7 @@ static int nowayout = WATCHDOG_NOWAYOUT;
    static int heartbeat = 60; /* (secs) Default is 1 minute */
    static unsigned long wdt_status;
    static unsigned long boot_status;
    -static spin_lock_t wdt_lock;
    +static DEFINE_SPINLOCK(wdt_lock);

    #define WDT_TICK_RATE (IXP4XX_PERIPHERAL_BUS_CLOCK * 1000000UL)

    diff --git a/drivers/watchdog/s3c2410_wdt.c b/drivers/watchdog/s3c2410_wdt.c
    index 3da2b90..22715e3 100644
    --- a/drivers/watchdog/s3c2410_wdt.c
    +++ b/drivers/watchdog/s3c2410_wdt.c
    @@ -157,8 +157,6 @@ static void s3c2410wdt_start(void)
    writel(wdt_count, wdt_base + S3C2410_WTCNT);
    writel(wtcon, wdt_base + S3C2410_WTCON);
    spin_unlock(&wdt_lock);
    -
    - return 0;
    }

    static int s3c2410wdt_set_heartbeat(int timeout)
    diff --git a/drivers/watchdog/wdt285.c b/drivers/watchdog/wdt285.c
    index c8d7f1b..db362c3 100644
    --- a/drivers/watchdog/wdt285.c
    +++ b/drivers/watchdog/wdt285.c
    @@ -208,7 +208,7 @@ static int __init footbridge_watchdog_init(void)
    soft_margin);

    if (machine_is_cats())
    - printk(KERN_WARN
    + printk(KERN_WARNING
    "Warning: Watchdog reset may not work on this machine.\n");
    return 0;
    }



    --
    Russell King
    Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
    maintainer of:
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  5. Re: [WATCHDOG] v2.6.27-rc watchdog fixes

    Hi Russell,

    > It's in part of my general ARM updates, and I combined Adrian's three
    > patches together, along with the remaining bits from my s3c2410 patch.
    > Here's the mbox mail corresponding with the commit:


    Applied the patch together with Ben's previously issued patches.
    We now have these Changes (Ben can you test also?):

    Author: Russell King
    Date: Sun Aug 10 23:28:46 2008 +0100

    [WATCHDOG] fix watchdog/s3c2410_wdt.c compilation

    This patch fixes the following compile errors caused by
    commit 41dc8b72e37c514f7332cbc3f3dd864910c2a1fa
    (s3c2410_wdt watchdog driver: Locking and coding style):

    <-- snip -->

    ...
    CC drivers/watchdog/s3c2410_wdt.o
    s3c2410_wdt.c: In function `s3c2410wdt_start':
    s3c2410_wdt.c:161: warning: `return' with a value, in function returning void

    <-- snip -->

    Signed-off-by: Russell King
    Signed-off-by: Wim Van Sebroeck

    Author: Ben Dooks
    Date: Sun Jun 22 22:36:51 2008 +0100

    [WATCHDOG] Fix s3c2410_wdt driver coding style issues

    Fixup coding style issues in the s3c2410_wdt driver.

    Signed-off-by: Ben Dooks
    Signed-off-by: Wim Van Sebroeck

    Author: Ben Dooks
    Date: Sun Jun 22 22:36:50 2008 +0100

    [WATCHDOG] Clean out header of s3c2410_wdt driver.

    Remove the changelog from the top of the driver, which
    is redundant as this information is more accurately
    represented from the revision control holding the
    file.

    Signed-off-by: Ben Dooks
    Signed-off-by: Wim Van Sebroeck

    Author: Ben Dooks
    Date: Sun Jun 22 22:36:49 2008 +0100

    [WATCHDOG] Fix NULL usage in s3c2410_wdt driver.

    Fix comparison of a pointer to 0, instead of using
    NULL for a invalid pointer.

    Signed-off-by: Ben Dooks
    Signed-off-by: Wim Van Sebroeck

    ================================================== ==============================
    diff --git a/drivers/watchdog/s3c2410_wdt.c b/drivers/watchdog/s3c2410_wdt.c
    index 3da2b90..86d4280 100644
    --- a/drivers/watchdog/s3c2410_wdt.c
    +++ b/drivers/watchdog/s3c2410_wdt.c
    @@ -21,18 +21,6 @@
    * You should have received a copy of the GNU General Public License
    * along with this program; if not, write to the Free Software
    * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
    - *
    - * Changelog:
    - * 05-Oct-2004 BJD Added semaphore init to stop crashes on open
    - * Fixed tmr_count / wdt_count confusion
    - * Added configurable debug
    - *
    - * 11-Jan-2005 BJD Fixed divide-by-2 in timeout code
    - *
    - * 25-Jan-2005 DA Added suspend/resume support
    - * Replaced reboot notifier with .shutdown method
    - *
    - * 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA
    */

    #include
    @@ -157,8 +145,6 @@ static void s3c2410wdt_start(void)
    writel(wdt_count, wdt_base + S3C2410_WTCNT);
    writel(wtcon, wdt_base + S3C2410_WTCON);
    spin_unlock(&wdt_lock);
    -
    - return 0;
    }

    static int s3c2410wdt_set_heartbeat(int timeout)
    @@ -367,7 +353,7 @@ static int s3c2410wdt_probe(struct platform_device *pdev)
    return -ENOENT;
    }

    - size = (res->end-res->start)+1;
    + size = (res->end - res->start) + 1;
    wdt_mem = request_mem_region(res->start, size, pdev->name);
    if (wdt_mem == NULL) {
    dev_err(dev, "failed to get memory region\n");
    @@ -376,7 +362,7 @@ static int s3c2410wdt_probe(struct platform_device *pdev)
    }

    wdt_base = ioremap(res->start, size);
    - if (wdt_base == 0) {
    + if (wdt_base == NULL) {
    dev_err(dev, "failed to ioremap() region\n");
    ret = -EINVAL;
    goto err_req;
    ================================================== ==============================

    Greetings,
    Wim.

    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  6. Re: [WATCHDOG] v2.6.27-rc watchdog fixes

    On Mon, Aug 11, 2008 at 10:51:24PM +0200, Wim Van Sebroeck wrote:
    > Hi Russell,
    >
    > > It's in part of my general ARM updates, and I combined Adrian's three
    > > patches together, along with the remaining bits from my s3c2410 patch.
    > > Here's the mbox mail corresponding with the commit:

    >
    > Applied the patch together with Ben's previously issued patches.
    > We now have these Changes (Ben can you test also?):


    Okay, but this means I'll need to kick that commit out of my git
    tree, or maybe just leave it and let git handle the merge.

    --
    Russell King
    Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
    maintainer of:
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

+ Reply to Thread