From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jean Delvare Subject: Re: i2c-remove-redundant-i2c_client-list.patch Date: Wed, 9 Jan 2008 17:09:01 +0100 Message-ID: <20080109170901.10e49b48@hyperion.delvare> References: <20071216052308.A0FB11668D7@adsl-69-226-248-13.dsl.pltn13.pacbell.net> <200712291905.15160.david-b@pacbell.net> <20080106122356.78556b8a@hyperion.delvare> <200801061130.31774.david-b@pacbell.net> <20080108151817.35e05c6c@hyperion.delvare> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20080108151817.35e05c6c-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: i2c-bounces-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org Errors-To: i2c-bounces-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org To: David Brownell Cc: i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org List-Id: linux-i2c@vger.kernel.org Quoting myself: > Admittedly it will slow down things a bit as each iteration of the loop > will have one additional level of indirection. This makes the calling > code somewhat simpler though. Whether it is worth the additional > runtime cost, I just don't know. What do you think? For the records, what I wrote above is not entirely true. By folding i2c_verify_client() into __i2c_for_each_client(), it is possible to get the exact same runtime cost (in terms of function call count) as we have without my proposed change. So performance is not a reason for not doing it. -- Jean Delvare