Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1345261yba; Thu, 18 Apr 2019 20:55:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqx0uNe+CnFTM5m+cI+kfOOx0KPrMnbHQI4TMcldKqdXeAgEgWlSXwGH82xiri0ZHPPRmedy X-Received: by 2002:a63:6983:: with SMTP id e125mr1607871pgc.370.1555646152443; Thu, 18 Apr 2019 20:55:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555646152; cv=none; d=google.com; s=arc-20160816; b=SNgEoDrXvLHxvwQxtgEYDiLDujXAg+s0YTz+3J3c4PjrragaKC+jzfjCkQ5+CBnvKI hMnsu+xD7jMDguMPDPv5Pj51BsNB2IF1QTtnEzBsqL0l0oea8CBt95ut+GbcSiVRFUdo Lkh4BJQ2jr4CYWpm6og/g4qTYRU8mF/fyclbzt+pcYw1RnAyN4TrhRyaucsZDQMCjoLZ CndF2NSBGjhBRjdicKHsmTfRS0jTC7xJCIvN6q+rrUXBfgdB9ehXF1slfXp38+YWxB5H PF9NwJO+cLf7h1ciq5a+HQ7aqgicLkxrem38yxm8lMyTF9UoTXrwQSFhQjsWivcIU1kt 0xIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=BRAjWrFKIMtDttZ7vr0JzJ6Ex7gfUtsVYhLD5Ouppro=; b=hFajURACxU3gJvztC3/+6Hhn6g9SCoO403GBrvED+gK1ZwBX25EpcImiy3AHrFbYAD CtKd4yoOI+EH9AHwlhr5d2dQy7giUmCUOUrYfhTd34oN38PDiHOZzJ4Kd+XA74W92MFZ 5auwqMKRv4TG1rOoLL90aUhmB3qhaqS80Y14/B9+lqg3hRRy1F/v0rEsLmKL/SPqtZqS Zinaa9Ea2WSUghwSUJd6oZlDOn4nndq4sWJIfh6N5e8M3hDjDV+5+BXhq9pPsnAfwMm/ VG95HMX3kfZIr+iz5VqEQ+4vHkY9IuoNTUk4FdjK3GxbpxDWLVEs/LekIDvhH7e5gfe7 dx5g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r63si4389360pfc.183.2019.04.18.20.55.36; Thu, 18 Apr 2019 20:55:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727268AbfDSDxC (ORCPT + 99 others); Thu, 18 Apr 2019 23:53:02 -0400 Received: from mail-sz.amlogic.com ([211.162.65.117]:60306 "EHLO mail-sz.amlogic.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727159AbfDSDxC (ORCPT ); Thu, 18 Apr 2019 23:53:02 -0400 Received: from [10.28.18.125] (10.28.18.125) by mail-sz.amlogic.com (10.28.11.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1591.10; Fri, 19 Apr 2019 11:52:52 +0800 Subject: Re: [PATCH 4/4] mtd: rawnand: meson: only initialize the RB completion once To: Martin Blumenstingl CC: , , , , , , , , , , References: <20190411220056.19109-1-martin.blumenstingl@googlemail.com> <20190411220056.19109-5-martin.blumenstingl@googlemail.com> From: Liang Yang Message-ID: <8ff232c3-f325-5b91-4de1-a39e63939df2@amlogic.com> Date: Fri, 19 Apr 2019 11:52:52 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.28.18.125] X-ClientProxiedBy: mail-sz.amlogic.com (10.28.11.5) To mail-sz.amlogic.com (10.28.11.5) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Martin, On 2019/4/19 3:44, Martin Blumenstingl wrote: > Hi Liang, > > On Mon, Apr 15, 2019 at 8:04 AM Liang Yang wrote: >> >> >> On 2019/4/12 6:00, Martin Blumenstingl wrote: >>> Documentation/scheduler/completion.txt states: >>> Calling init_completion() on the same completion object twice is >>> most likely a bug as it re-initializes the queue to an empty queue and >>> enqueued tasks could get "lost" - use reinit_completion() in that case, >>> but be aware of other races. >>> >>> Initialize nfc->completion in meson_nfc_probe using init_completion and >>> change the call in meson_nfc_queue_rb to reinit_completion so the logic >>> matches what the documentation suggests. >>> >>> Signed-off-by: Martin Blumenstingl >>> --- >>> drivers/mtd/nand/raw/meson_nand.c | 3 ++- >>> 1 file changed, 2 insertions(+), 1 deletion(-) >>> >>> diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c >>> index 57cc4bd3f665..ea57ddcec41e 100644 >>> --- a/drivers/mtd/nand/raw/meson_nand.c >>> +++ b/drivers/mtd/nand/raw/meson_nand.c >>> @@ -400,7 +400,7 @@ static int meson_nfc_queue_rb(struct meson_nfc *nfc, int timeout_ms) >>> cfg |= NFC_RB_IRQ_EN; >>> writel(cfg, nfc->reg_base + NFC_REG_CFG); >>> >>> - init_completion(&nfc->completion); >>> + reinit_completion(&nfc->completion); >> Tested-by:Liang Yang >> Acked-by: Liang Yang > thank you for reviewing and testing my patches! > > [...] >> Tested-by:Liang Yang >> Acked-by: Liang Yang > please consider the following note for future code-reviews: > most maintainers take the patch from patchwork and apply it to their git tree. > however, patchwork is not smart enough to detect when the same > Tested-by/Acked-by is sent multiple times. > this results in the same Tested-by/Acked-by being listed multiple > times in the final commit: [0] > > what I do instead is to reply with one set of Tested-by/Acked-by > (below the author's Signed-off-by) which is then valid for the whole > patch. > There's no problem to have Tested-by and Acked-by at the same time, > the issue only shows up if you send Acked-by (or any other tag) for > the same patch multiple times. > Thanks. Well, I known about it now. > > Have a great day! > Regards, > Martin > > > [0] https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git/commit/?h=nand/next&id=39e01956e2f70ff9f0e97db1a69c9847aa1d5d8b > > . >