From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kukjin Kim Subject: RE: [PATCH v5] ARM: s3c244x: Fix mess with gpio {set,get}_pull callbacks Date: Wed, 01 Dec 2010 21:05:00 +0900 Message-ID: <003c01cb914f$fc6d3350$f54799f0$%kim@samsung.com> References: <4CF55785.5090403@metafoo.de> <1291147949-18812-1-git-send-email-anarsoul@gmail.com> <001301cb9129$15f1b5c0$41d52140$%kim@samsung.com> <201012011217.41602.anarsoul@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Return-path: Received: from mailout2.samsung.com ([203.254.224.25]:35063 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752629Ab0LAMFP (ORCPT ); Wed, 1 Dec 2010 07:05:15 -0500 Received: from epmmp2 (mailout2.samsung.com [203.254.224.25]) by mailout2.samsung.com (Oracle Communications Messaging Exchange Server 7u4-19.01 64bit (built Sep 7 2010)) with ESMTP id <0LCR00H2X08P7A70@mailout2.samsung.com> for linux-samsung-soc@vger.kernel.org; Wed, 01 Dec 2010 21:05:13 +0900 (KST) Received: from DOKGENEKIM02 ([12.23.103.104]) by mmp2.samsung.com (iPlanet Messaging Server 5.2 Patch 2 (built Jul 14 2004)) with ESMTPA id <0LCR00J7808PSC@mmp2.samsung.com> for linux-samsung-soc@vger.kernel.org; Wed, 01 Dec 2010 21:05:13 +0900 (KST) In-reply-to: <201012011217.41602.anarsoul@gmail.com> Content-language: ko Sender: linux-samsung-soc-owner@vger.kernel.org List-Id: linux-samsung-soc@vger.kernel.org To: 'Vasily Khoruzhick' Cc: 'Lars-Peter Clausen' , 'Ben Dooks' , 'Russell King' , linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, 'Abdoulaye Walsimou GAYE' Vasily Khoruzhick wrote: > > On Wednesday 01 December 2010 09:26:31 Kukjin Kim wrote: > > > How about following... > > > > +void __init s3c2440_map_io(void) > > +{ > > + s3c24xx_gpiocfg_default.set_pull = s3c_gpio_setpull_1up; > > + s3c24xx_gpiocfg_default.get_pull = s3c_gpio_getpull_1up; > > + > > + s3c244x_map_io(); > > +} > > What's difference except order? > Just same ordering is used in other Samsung S3C SoCs. Now actually doesn't matter it. > > Yeah, however, in my opinion, need to add following during gpiolib_init(). > > > > @@ -222,6 +222,11 @@ static __init int s3c24xx_gpiolib_init(void) > > if (!chip->config) > > chip->config = &s3c24xx_gpiocfg_default; > > > > + if (!chip->config->set_pull) > > + chip->config->set_pull = s3c_gpio_setpull_1up; > > + if (!chip->config->get_pull) > > + chip->config->get_pull = s3c_gpio_getpull_1up; > > + > > s3c_gpiolib_add(chip); > > } > > Pull callbacks are soc-specific, s3c24xx_gpiolib_init is common for all socs, > so we can't do like this. > Yeah, right...it depends on each SoCs. But, if there is no setup it in map_io(), there is no functions of set_pull() and get_pull(). As you know, used s3c_gpio_{set,get}pull_1up as default before your patch... Hmm...however, I will think about its necessity again. > Btw, I've sent v6 version of patch, it still with empty line issues, should I > resend v7 version or maintainers can fixup it at their side? :) > Ok..I will do it and will apply. Then, will be sent to Linus during 37-rc. Thanks. Best regards, Kgene. -- Kukjin Kim , Senior Engineer, SW Solution Development Team, Samsung Electronics Co., Ltd.