Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp159825ybl; Mon, 12 Aug 2019 13:41:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqwudMg+TX8QXjhfyLrRS8u+JtEcDa3GDg5IDZ4LTkm58BY80oX062kv+GVYlDqSvJDUWMZ+ X-Received: by 2002:a62:7912:: with SMTP id u18mr15350441pfc.254.1565642505430; Mon, 12 Aug 2019 13:41:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565642505; cv=none; d=google.com; s=arc-20160816; b=RV9p1CnfWgJUsH8XY7IlLQYhhSqrsRa+7Kq1E/SdIMhp4kMjz44kT9ZIZb/9it7BzB QR+dN/gI0bHDhDM1StFIKYuNIpuSZSS/ZNChwO0GlEgPa5FOIO3jpHYFS95+k2Hz1UXt W8rJSwXFs/KJE7IMueGA1e86eY0DuqcmOt2CVIuQQR2IxPseU4GMwgmpRsPhirhx+dwb mVBjCjSZ4clSU7o1D2c35slF1F3z0oYS69L7oD96yMfTAFRfJkZ64hkxdMLk4eM+nNf5 aQ1hnEQFkJ/ThAEbZtEaqwXBA3Fg5+BCv/180YGYmgpkJT6D7sny64ronhCCfrYT7uSc JInA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=dLwU0FcSl0ezXNU80uM/m3BAX5vjiadznJD3VXDbRGM=; b=YhWi4WPx9D2iAkv/ehOgVDBowUNGJqW7QtCq1cSMz/9nQdT7vvQOuej72dPeTEFer8 KTkEjmVcDXG2MprkRoHxEx7sgp2UcP2jRL0zXml7iaUvJqvgHm0TGNfQAIL5xv7SIGuA FoXiBCH/pXOeHmaXLjF1w9lxqsu7qw8nn8krZ243MW8S7Zi50GNgZ4WSIq0rX89W0VIt 4v0CVDt5FMshHsqpzZgFtyqOIg7ckB5RoVoicwWihuaP+hcxrq8qtiJXYS5iJoZwPOEH bc8CapoCZegwQxcrMk902zPjGVTE3pMqj25FoiZs0ic38IDJXyL4a87OMzH1lPe7wEi7 NYCQ== 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 q13si10593818plr.158.2019.08.12.13.41.28; Mon, 12 Aug 2019 13:41:45 -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 S1726672AbfHLUk1 (ORCPT + 99 others); Mon, 12 Aug 2019 16:40:27 -0400 Received: from bmailout1.hostsharing.net ([83.223.95.100]:56027 "EHLO bmailout1.hostsharing.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726144AbfHLUk1 (ORCPT ); Mon, 12 Aug 2019 16:40:27 -0400 Received: from h08.hostsharing.net (h08.hostsharing.net [83.223.95.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.hostsharing.net", Issuer "COMODO RSA Domain Validation Secure Server CA" (not verified)) by bmailout1.hostsharing.net (Postfix) with ESMTPS id 32D7330000CF7; Mon, 12 Aug 2019 22:40:25 +0200 (CEST) Received: by h08.hostsharing.net (Postfix, from userid 100393) id 0786210A7C; Mon, 12 Aug 2019 22:40:24 +0200 (CEST) Date: Mon, 12 Aug 2019 22:40:24 +0200 From: Lukas Wunner To: sathyanarayanan kuppuswamy Cc: Denis Efremov , Bjorn Helgaas , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 1/4] PCI: pciehp: Add pciehp_set_indicators() to jointly set LED indicators Message-ID: <20190812204024.r54ihfwdcbwdj563@wunner.de> References: <20190811195944.23765-1-efremov@linux.com> <20190811195944.23765-2-efremov@linux.com> <925a00be-c2b6-697d-d46b-a279856105b4@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 12, 2019 at 11:49:23AM -0700, sathyanarayanan kuppuswamy wrote: > > On 8/11/19 12:59 PM, Denis Efremov wrote: > > > + if ((!PWR_LED(ctrl) || pwr == PWR_NONE) && > > > + (!ATTN_LED(ctrl) || attn == ATTN_NONE)) > > > + return; > > Also I think this condition needs to expand to handle the case whether pwr > != PWR_NONE and !PWR_LED(ctrl) is true. > > you need to return for case, pwr = PWR_ON, !PWR_LED(ctrl)=true , > !ATTN_LED(ctrl)=false, attn=on Why should we return in that case? We need to update the Attention Indicator Control to On. Thanks, Lukas