From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt0-x22f.google.com (mail-qt0-x22f.google.com [IPv6:2607:f8b0:400d:c0d::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 9B8828211E for ; Mon, 13 Feb 2017 04:59:44 -0800 (PST) Received: by mail-qt0-x22f.google.com with SMTP id x49so82211716qtc.2 for ; Mon, 13 Feb 2017 04:59:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=nSowl0wjXp4F1ekT4gRPHhWaNR2tffvfICvThZtS/i4=; b=QGVT/jdrzLq2o+PTpkSFOKYq5JF0IEJu3o0IwWEMKATSy3jhwF7J6jwZgqTM9wbia8 /NUpkMskAKOPHcHQyyYuV8mh/9Hnq/shfjqJiB7CdBR1vES/Ftph0pz7KQSOf0le3p50 eEOKVtjr7WEDzTzU7DQ/ebQjl5aEx4bijrijQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=nSowl0wjXp4F1ekT4gRPHhWaNR2tffvfICvThZtS/i4=; b=Ji7b1ORon6Anoj0HV4EqK+ZGQxJtDqPTAoMTUA9MCvMroPz3Eetx2lG4R7dIKyQIiv RVdqVEYMLyODNuypsnuSWfXgVUe9VEqUXG9rymLjfdUG7QEdfhXvgyjYXl2mv2zvbTM8 lQNivVqwBipoYO1lwhWe3t3yXeZWxxMjzLKtocuICbH24wxjDI9xjlpXse2Apr71KoWs 4mgxM6TT/IHRkCe81CS01kuqwhdlANie8nZ+kdeO2K6v/CmwBTePUOpr1GtIfCOMI/Mo 2QIEyepBUM/6GXHkCdbz06ZXeHKRuEpGuRUoyxrhC9BzZT/35KC4RAx6pDA7HWf9LBun RF+A== X-Gm-Message-State: AMke39kdRgyMfSAeXWgeJeD/99L0jssBFhb1DHTbI+S6IZWKFHkfduLkeGb6GHu21c+r3K3V6Un4r9uko2QV22aK X-Received: by 10.200.50.157 with SMTP id z29mr19598759qta.131.1486990783332; Mon, 13 Feb 2017 04:59:43 -0800 (PST) MIME-Version: 1.0 Received: by 10.140.41.114 with HTTP; Mon, 13 Feb 2017 04:59:42 -0800 (PST) In-Reply-To: <1486972380-24255-2-git-send-email-haojian.zhuang@linaro.org> References: <1486972380-24255-1-git-send-email-haojian.zhuang@linaro.org> <1486972380-24255-2-git-send-email-haojian.zhuang@linaro.org> From: Haojian Zhuang Date: Mon, 13 Feb 2017 20:59:42 +0800 Message-ID: To: Leif Lindholm , "edk2-devel@lists.01.org" , Ard Biesheuvel Subject: Re: [PATCH 2/2] ArmPlatformPkg/PL061Gpio: fix the offset value in Get function X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Feb 2017 12:59:44 -0000 Content-Type: text/plain; charset=UTF-8 On 13 February 2017 at 15:53, Haojian Zhuang wrote: > When call PL061GetPins() or PL061SetPins(), should use GPIO_PIN_MASK(offset) > as parameter, not offset. > > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Haojian Zhuang > --- > ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c > index ff8bb3b..81b9f6d 100644 > --- a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c > +++ b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c > @@ -186,7 +186,7 @@ Get ( > return EFI_INVALID_PARAMETER; > } > > - if (PL061GetPins (RegisterBase, Offset)) { > + if (PL061GetPins (RegisterBase, GPIO_PIN_MASK(Offset))) { > *Value = 1; > } else { > *Value = 0; > -- > 2.7.4 > Correct Ard's email address. Regards Haojian