Received: from mail.onstor.com ([66.201.51.107]) by onstor-exch02.onstor.net with Microsoft SMTPSVC(6.0.3790.1830);
	 Fri, 8 Aug 2008 08:21:22 -0700
Received: from ausesmta2-3.messageone.com ([64.20.241.45]) by mail.onstor.com with Microsoft SMTPSVC(6.0.3790.1830);
	 Fri, 8 Aug 2008 08:21:22 -0700
Received: from ftp.linux-mips.org (ftp.linux-mips.org [213.58.128.207])
	by ausesmta2-3.messageone.com (8.13.8/8.13.8) with ESMTP id m78FLKAT008520
	for <andy.sharp@onstor.com>; Fri, 8 Aug 2008 10:21:21 -0500
Received: from localhost.localdomain ([127.0.0.1]:59264 "EHLO
	ftp.linux-mips.org") by ftp.linux-mips.org with ESMTP
	id S28578132AbYHHPUs (ORCPT <rfc822;andy.sharp@onstor.com>);
	Fri, 8 Aug 2008 16:20:48 +0100
Received: with ECARTIS (v1.0.0; list linux-mips); Fri, 08 Aug 2008 16:20:31 +0100 (BST)
Received: from smtp5.pp.htv.fi ([213.243.153.39]:47340 "EHLO smtp5.pp.htv.fi")
	by ftp.linux-mips.org with ESMTP id S28577907AbYHHPUW (ORCPT
	<rfc822;linux-mips@linux-mips.org>); Fri, 8 Aug 2008 16:20:22 +0100
Received: from cs181140183.pp.htv.fi (cs181140183.pp.htv.fi [82.181.140.183])
	by smtp5.pp.htv.fi (Postfix) with ESMTP id 6B8455BC048;
	Fri,  8 Aug 2008 18:20:19 +0300 (EEST)
Date: 	Fri, 8 Aug 2008 18:18:46 +0300
From: Adrian Bunk <bunk@kernel.org>
To: Alan Cox <alan@redhat.com>, Wim Van Sebroeck <wim@iguana.be>
Cc: linux-mips@linux-mips.org, linux-kernel@vger.kernel.org,
        Andrew Morton <akpm@linux-foundation.org>
Subject: [2.6 patch] fix watchdog/txx9wdt.c compilation
Message-ID: <20080808151846.GA14495@cs181140183.pp.htv.fi>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: Mutt/1.5.18 (2008-05-17)
X-archive-position: 20158
X-ecartis-version: Ecartis v1.0.0
Sender: linux-mips-bounce@linux-mips.org
Errors-to: linux-mips-bounce@linux-mips.org
X-original-sender: bunk@kernel.org
Precedence: bulk
X-list: 	linux-mips
X-MessageOne-Virus-Version: vendor=fsecure engine=4.65.7161:2.4.4,1.2.40,4.0.164 definitions=2008-08-08_05:2008-08-07,2008-08-08,2008-08-08 signatures=0
X-MessageOne-Virus-Scanned: Clean
X-MessageOne-Envelope-Sender: linux-mips-bounce@linux-mips.org
X-MessageOne-Spam-Details: rule=m773emszm_notspam policy=m773emszm score=0 spamscore=0 ipscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx engine=3.1.0-0805090000 definitions=main-0808080056
X-MessageOne-Spam-Score: 0
X-MessageOne-Spam-Bar: 
Return-Path: linux-mips-bounce@linux-mips.org
X-OriginalArrivalTime: 08 Aug 2008 15:21:22.0156 (UTC) FILETIME=[6A1352C0:01C8F96A]

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 <bunk@kernel.org>
Signed-off-by: Adrian Bunk <bunk@kernel.org>

---
b29c2476cf814321b4ece7e359248b9a3046fc38 
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)
 {

