[PATCH 2/2] powerpc/watchdog: allow the e500 watchdog driver to be compiled as a module

Josh Boyer jwboyer at gmail.com
Sat Sep 18 10:37:47 EST 2010


On Fri, Sep 17, 2010 at 6:53 PM, Timur Tabi <timur at freescale.com> wrote:
> Register the __init and __exit functions in the PowerPC e500 watchdog driver
> as module entry/exit functions, and modify the Kconfig entry.
>
> Add a .release method for the PowerPC e500 watchdog driver, so that the
> watchdog is disabled when the driver is closed.

This is used for more than just e500.

>
> Loosely based on original code from Jiang Yutang <b14898 at freescale.com>.
>
> Signed-off-by: Timur Tabi <timur at freescale.com>
> ---
>
> This patch requires:
>
>        powerpc: export ppc_tb_freq so that modules can reference it
>
>  drivers/watchdog/Kconfig     |    5 ++++-
>  drivers/watchdog/booke_wdt.c |   39 +++++++++++++++++++++++++++++++++++++--
>  2 files changed, 41 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig
> index 24efd8e..d9cf5a9 100644
> --- a/drivers/watchdog/Kconfig
> +++ b/drivers/watchdog/Kconfig
> @@ -957,9 +957,12 @@ config PIKA_WDT
>          the Warp platform.
>
>  config BOOKE_WDT
> -       bool "PowerPC Book-E Watchdog Timer"
> +       tristate "PowerPC Book-E Watchdog Timer"
>        depends on BOOKE || 4xx
>        ---help---
> +         Watchdog driver for PowerPC e500 chips, such as the Freescale
> +         MPC85xx SOCs.
> +

Again, used for more than e500.  That || 4xx in the depends statement
right above your addition isn't there for fun :).

josh


More information about the Linuxppc-dev mailing list