From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from wolverine02.qualcomm.com ([199.106.114.251]:45586 "EHLO wolverine02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756537Ab0CaOok (ORCPT ); Wed, 31 Mar 2010 10:44:40 -0400 Subject: Re: [PATCH 1/4] arm: msm: gpio support From: Daniel Walker In-Reply-To: References: <1269990717-2969-1-git-send-email-dwalker@codeaurora.org> <0D753D10438DA54287A00B027084269763691C346E@AUSP01VMBX24.collaborationhost.net> Content-Type: text/plain; charset="UTF-8" Date: Wed, 31 Mar 2010 07:03:02 -0700 Message-ID: <1270044182.2025.0.camel@m0nster> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-arm-msm-owner@vger.kernel.org List-ID: To: Arve =?ISO-8859-1?Q?Hj=F8nnev=E5g?= Cc: H Hartley Sweeten , "linux-arm-kernel@lists.infradead.org" , "linux-arm-msm@vger.kernel.org" On Tue, 2010-03-30 at 18:14 -0700, Arve Hjønnevåg wrote: > On Tue, Mar 30, 2010 at 4:58 PM, H Hartley Sweeten > wrote: > > On Tuesday, March 30, 2010 4:12 PM, Daniel Walker wrote: > >> From: Daniel Walker > ... > >> + > >> +static void msm_gpio_irq_ack(unsigned int irq) > >> +{ > >> + unsigned long irq_flags; > >> + struct msm_gpio_chip *msm_chip = get_irq_chip_data(irq); > >> + unsigned b; > >> + > >> + spin_lock_irqsave(&msm_chip->lock, irq_flags); > >> + > >> + b = 1U << (irq - FIRST_GPIO_IRQ - msm_chip->chip.base); > > > > Urk... That's a bit confusing... > > > > You might want to make this a macro or an inline function with some kind > > of comment. > > > > On a related note, why did you inline msm_gpio_clear_detect_status? It > is used from two other functions. > You mean other places in the Android tree? Daniel