From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965101AbbDIKFe (ORCPT ); Thu, 9 Apr 2015 06:05:34 -0400 Received: from hqemgate16.nvidia.com ([216.228.121.65]:7323 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965086AbbDIKF0 (ORCPT ); Thu, 9 Apr 2015 06:05:26 -0400 X-PGP-Universal: processed; by hqnvupgp08.nvidia.com on Thu, 09 Apr 2015 03:01:30 -0700 Message-ID: <55264DE5.4050508@nvidia.com> Date: Thu, 9 Apr 2015 15:31:09 +0530 From: Laxman Dewangan User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Mark Brown CC: , Subject: Re: [PATCH] regulator: kconfig: make max8973 driver to depend on GPIOLIB References: <1428500227-3379-1-git-send-email-ldewangan@nvidia.com> <20150408164323.GA6023@sirena.org.uk> In-Reply-To: <20150408164323.GA6023@sirena.org.uk> X-Originating-IP: [10.19.65.30] X-ClientProxiedBy: DRUKMAIL101.nvidia.com (10.25.59.19) To bgmail102.nvidia.com (10.25.59.11) Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wednesday 08 April 2015 10:13 PM, Mark Brown wrote: > * PGP Signed by an unknown key > > On Wed, Apr 08, 2015 at 07:07:07PM +0530, Laxman Dewangan wrote: >> MAX8973 regulator driver uses the GPIO APIs for accessing the >> control signal connected to its pin from host processor. >> >> Make this driver depends on GPIOLIB. > The GPIO usage in the driver appears to be optional, it handles the GPIO > not being controllable. This suggests to me that the gpiolib dependency > shouldn't be required and that it would be better to fix this by > ensuring that all the gpiolib functions being used have appropriate > stubs. Which ones are causing problems? > Thanks for review. Sometime ago, I got the comiplation error on random config for one of architecture which was not having GPIO architecture. The compilation error was reported on tps62360-regulator.c which is also using similar i2c calls. So to avoid similar issue, I make this depends on GPIOLIB. However, I looked gpio.h and it has all required APIs as static inline if GPIOLIB is not there so atleast compilation issue will not be there. Now going through code, I think if gpios are not there then also it should work. Not tested this on my board as I can not boot without gpio. I think we can drop this patch. Thanks, Laxman