watchdog: Use DEFINE_SPINLOCK() for static spinlocks

Rather than just defining static spinlock_t variables and then
initializing them later in init functions, simply define them with
DEFINE_SPINLOCK() and remove the calls to spin_lock_init().

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Cc: Nicolas Thill <nico@openwrt.org>
Cc: Heiko Ronsdorf <hero@ihg.uni-duisburg.de>
Cc: Rodolfo Giometti <giometti@ascensit.com>
Cc: Andrey Panin <pazke@donpac.ru>
Cc: Guido Guenther <agx@sigxcpu.org>
Cc: Curt E Bruns <curt.e.bruns@intel.com>
Cc: Deepak Saxena <dsaxena@plexity.net>
Cc: Andrew Victor <linux@maxim.org.za>
Cc: George G. Davis <gdavis@mvista.com>
Cc: Sylver Bruneau <sylver.bruneau@googlemail.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
This commit is contained in:
Axel Lin
2011-11-29 13:54:01 +08:00
committed by Wim Van Sebroeck
parent 216f3ad9aa
commit 1334f32938
11 changed files with 10 additions and 27 deletions

View File

@@ -41,7 +41,7 @@ static int heartbeat = -1; /* module parameter (seconds) */
static unsigned int wdt_max_duration; /* (seconds) */
static unsigned int wdt_tclk;
static unsigned long wdt_status;
static spinlock_t wdt_lock;
static DEFINE_SPINLOCK(wdt_lock);
static void orion_wdt_ping(void)
{
@@ -296,7 +296,6 @@ static struct platform_driver orion_wdt_driver = {
static int __init orion_wdt_init(void)
{
spin_lock_init(&wdt_lock);
return platform_driver_register(&orion_wdt_driver);
}