Received: from mail.onstor.com (66.201.51.107) by exch1.onstor.net
 (10.0.0.225) with Microsoft SMTP Server id 8.1.311.2; Fri, 28 Nov 2008
 11:44:30 -0800
Received: from chiesmta2-1.messageone.com ([216.203.30.55]) by mail.onstor.com
 with Microsoft SMTPSVC(6.0.3790.3959);	 Fri, 28 Nov 2008 11:44:30 -0800
Received: from ftp.linux-mips.org (ftp.linux-mips.org [213.58.128.207])	by
 chiesmta2-1.messageone.com (8.13.8/8.13.8) with ESMTP id mASJiT01025825	for
 <andy.sharp@onstor.com>; Fri, 28 Nov 2008 13:44:29 -0600
Received: from localhost.localdomain ([127.0.0.1]:40152 "EHLO
	ftp.linux-mips.org") by ftp.linux-mips.org with ESMTP	id S23974381AbYK1ToU
 (ORCPT <rfc822;andy.sharp@onstor.com>);	Fri, 28 Nov 2008 19:44:20 +0000
Received: with ECARTIS (v1.0.0; list linux-mips); Fri, 28 Nov 2008 19:44:03
 +0000 (GMT)
Received: from orbit.nwl.cc ([81.169.176.177]:54687 "EHLO
	mail.ifyouseekate.net") by ftp.linux-mips.org with ESMTP	id S23974375AbYK1Tnv
 (ORCPT <rfc822;linux-mips@linux-mips.org>);	Fri, 28 Nov 2008 19:43:51 +0000
Received: from nuty (localhost [127.0.0.1])	by mail.ifyouseekate.net (Postfix)
 with ESMTP id 5A883386DBBE;	Fri, 28 Nov 2008 20:43:46 +0100 (CET)
From: Phil Sutter <n0-1@freewrt.org>
To: Ralf Baechle <ralf@linux-mips.org>
CC: "linux-mips@linux-mips.org" <linux-mips@linux-mips.org>
Sender: "linux-mips-bounce@linux-mips.org" <linux-mips-bounce@linux-mips.org>
Date: Fri, 28 Nov 2008 11:46:22 -0800
Subject: [PATCH] MIPS: rb532: remove useless CF GPIO initialisation
Thread-Topic: [PATCH] MIPS: rb532: remove useless CF GPIO initialisation
Thread-Index: AclRkbtIbJEhB3LYSCOMG8KUQSvrmQ==
Message-ID: <20081128194346.5A883386DBBE@mail.ifyouseekate.net>
References: <20081128193322.D103C386DBBE@mail.ifyouseekate.net>
In-Reply-To: <20081128193322.D103C386DBBE@mail.ifyouseekate.net>
Accept-Language: en-US
Content-Language: en-US
X-MS-Exchange-Organization-AuthAs: Internal
X-MS-Exchange-Organization-AuthMechanism: 0b
X-MS-Exchange-Organization-AuthSource: exch1.onstor.net
X-MS-Has-Attach:
X-Auto-Response-Suppress: All
X-MS-TNEF-Correlator:
x-originalarrivaltime: 28 Nov 2008 19:44:30.0722 (UTC)
 FILETIME=[BB0F4E20:01C95191]
errors-to: linux-mips-bounce@linux-mips.org
x-ems-proccessed: 2K3Xl1OQTInXD6xxuA8z3Q==
x-ems-stamp: S+wCptbbzA/QA95VTvZqVg==
x-messageone-virus-version: vendor=fsecure
 engine=4.65.7400:2.4.4,1.2.40,4.0.164
 definitions=2008-11-26_13:2008-11-24,2008-11-26,2008-11-26 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-0810130000 definitions=main-0811260160
x-messageone-spam-score: 0
x-messageone-spam-bar:
x-list: linux-mips
x-archive-position: 21470
x-ecartis-version: Ecartis v1.0.0
x-original-sender: n0-1@freewrt.org
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0

As the pata-rb532-cf driver calls gpio_set_direction_input(), the calls
to rb532_gpio_set_func() and rb532_gpio_direction_input() are not needed
since the alternate function is automatically being disabled when
changing the GPIO pin direction.
The later two calls to rb532_gpio_set_{ilevel,istat}() are implicitly
being done by the IRQ initialisation of pata-rb532-cf.

Signed-off-by: Phil Sutter <n0-1@freewrt.org>
---
 arch/mips/rb532/gpio.c |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/mips/rb532/gpio.c b/arch/mips/rb532/gpio.c
index f5b15a1..b195f79 100644
--- a/arch/mips/rb532/gpio.c
+++ b/arch/mips/rb532/gpio.c
@@ -259,12 +259,6 @@ int __init rb532_gpio_init(void)
 		return -ENXIO;
 	}
=20
-	/* configure CF_GPIO_NUM as CFRDY IRQ source */
-	rb532_gpio_set_func(0, CF_GPIO_NUM);
-	rb532_gpio_direction_input(&rb532_gpio_chip->chip, CF_GPIO_NUM);
-	rb532_gpio_set_ilevel(1, CF_GPIO_NUM);
-	rb532_gpio_set_istat(0, CF_GPIO_NUM);
-
 	return 0;
 }
 arch_initcall(rb532_gpio_init);
--=20
1.5.6.4


