Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp367523ybh; Thu, 12 Mar 2020 03:35:53 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsTrrYMsz9b7PZlb1/RA1mGY+IhcSjtbVUT8ebWVi6DrKJA50L5ZlVks26sfSs7Wj9fnPLX X-Received: by 2002:aca:ed54:: with SMTP id l81mr2124373oih.69.1584009352905; Thu, 12 Mar 2020 03:35:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584009352; cv=none; d=google.com; s=arc-20160816; b=SKlc/UUpvcupsr+eFqV75D7Rz+PYsS3lDzcvfbXRp+0RzrcN/XoVjknpIYmLRRxenZ 8CjaiytyPWJSXDBf0l5m/hKB5Km2SsWbnhQRVC2hIN+pvKgPl+pWFW8cjaRdK8oXvN53 JvXyLvZs3fJ6iO2toGQL29hAIHQVeQ7A8ZQdErKb7vBNN9LYusDH/4KL20PdGRl3qln5 SvJNZAXfJEzrSB/xNsd8x7q176QnFdc3Le2WRhBPmf72fOVPyR2wpy/6gpTrMiJ6Fg67 Fpl/L1mbqOR9HAhi9Y6pcOr+ExcKNZ11+P8kCBb8WcP07go3yx1aj5+HsuuHQHgDORCf 89sg== 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:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=Elhehx58JjnpVasvGfpItQAGWL5MtskgGw42pHcHbh8=; b=JdRUiM1ApiPYNEPbipbq1kHatWv38J3QYnf+kr2o2CW5DMelp1aJqU5CebelXbQk03 0h1T8MAooXNkCsU81FYyj6qv+2DjNh5qtgYgOdPBgmvqFIrpIOgLlzNTZyCq0ZAdCMHm wyJB990EpycE8Lg0eHJrd+WPGbaO5WtR9z4WvlvWgiRNvEbvpFg+48TGQ5U1ipHUHMUk 2cWfPWR0jl8jaWyKkxpfY+o/kvzlkiqOxW8FvTXieel3HIZktM1Sc+ntTMWFkmY+qnEA neEan+O8bj5UUky/xk7mZS7SRSVA+S9VrJ/ZUHf8IPQmPTXmyXsSMA2b7h6f+wu6yBxq PMyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=MkoWJc5o; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t22si2391256oth.211.2020.03.12.03.35.41; Thu, 12 Mar 2020 03:35: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; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=MkoWJc5o; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726752AbgCLKed (ORCPT + 99 others); Thu, 12 Mar 2020 06:34:33 -0400 Received: from us-smtp-1.mimecast.com ([207.211.31.81]:24541 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726302AbgCLKed (ORCPT ); Thu, 12 Mar 2020 06:34:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1584009272; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Elhehx58JjnpVasvGfpItQAGWL5MtskgGw42pHcHbh8=; b=MkoWJc5ocHikYfjf6Gclr3HcX2TOHfEXyoTtPKH2w47X5o60BdRg9y+gJyTOrnV62sImiL pKe9PFihso6C8fZpN8Joyewbmw2xgHG4sWiE8BTeAXI9zkdPI1iTd5qduYqf1jjiOkAQw1 1BHWAlc0/ABR8+61DWDXdHejs1VP5Tw= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-273-mZfkIStbNYSgFB-GvJ0d3g-1; Thu, 12 Mar 2020 06:34:30 -0400 X-MC-Unique: mZfkIStbNYSgFB-GvJ0d3g-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id F178C8017CC; Thu, 12 Mar 2020 10:34:28 +0000 (UTC) Received: from elisabeth (ovpn-200-18.brq.redhat.com [10.40.200.18]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 348FB272A5; Thu, 12 Mar 2020 10:34:23 +0000 (UTC) Date: Thu, 12 Mar 2020 11:34:16 +0100 From: Stefano Brivio To: Lakshmi Ramasubramanian Cc: Shreeya Patel , gregkh@linuxfoundation.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, outreachy-kernel@googlegroups.com, daniel.baluta@gmail.com, hverkuil@xs4all.nl, Larry.Finger@lwfinger.net Subject: Re: [Outreachy kernel] [PATCH] Staging: rtl8723bs: rtw_mlme: Remove unnecessary conditions Message-ID: <20200312113416.23d3db5c@elisabeth> In-Reply-To: <61a6c3d7-6592-b57b-6466-995309302cc2@linux.microsoft.com> References: <20200311135859.5626-1-shreeya.patel23498@gmail.com> <61a6c3d7-6592-b57b-6466-995309302cc2@linux.microsoft.com> Organization: Red Hat MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Lakshmi, On Wed, 11 Mar 2020 19:42:06 -0700 Lakshmi Ramasubramanian wrote: > On 3/11/2020 6:58 AM, Shreeya Patel wrote: > > > Remove unnecessary if and else conditions since both are leading to the > > initialization of "phtpriv->ampdu_enable" with the same value. > > > > Signed-off-by: Shreeya Patel > > Stating this based on the patch descriptions I have seen. > Others, please advise\correct me if I am wrong. > > Patch description should state the problem first[1] and then describe > how that is fixed in the given patch. > > For example: > > In the function rtw_update_ht_cap(), phtpriv->ampdu_enable is set to the > same value in both if and else statements. > > This patch removes this unnecessary if-else statement. That's my general preference as well, but I can't find any point in the "Describe your changes" section of submitting-patches.rst actually defining the order. I wouldn't imply that from the sequence the steps are presented in. In case it's possible to say everything with a single statement as Shreeya did here, though, I guess that becomes rather a linguistic factor, and I personally prefer the concise version here. -- Stefano