Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp2672021ybl; Sun, 11 Aug 2019 06:30:40 -0700 (PDT) X-Google-Smtp-Source: APXvYqxzJA8wEwdw3oXlQpaeQ/sUEWrAQ+Olv8qc+Ka4OaUQRuieg0SYNq4GCUnf7Tj4H9fNhNi6 X-Received: by 2002:a62:7513:: with SMTP id q19mr5165988pfc.192.1565530240731; Sun, 11 Aug 2019 06:30:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565530240; cv=none; d=google.com; s=arc-20160816; b=0xNviLe/aje4Zb7KfRKrZ6ObFm4qYgL+CpFkE+1fSBSA47II2YVofXXIHW01VkUnbJ tXWbVDjr3LVompA+TAeQF5m5YuPJKNWWHXWzPYIQ6LicxnLh6ZIRpG6NgZjP+DNkuZnm VOaDrt5pFAjmnC69skXzuw4u1o1Yci9tqfYtUzWphj4EpwlnYNWZsPk2E3o50PiAUcNA PMC7gEivVR2yB2CqGa824X7700RPrwpwcO0q8U1LrUruCQ7GIqJ30M5EoKDfmVQ1auWJ thmaa6KNmACu0TVlf4maP/0hXSjo6iUR98aRF1Q+L7z4yUnQ1MBqDiczsA2Ck8kgK/Jt sUqg== 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 :message-id:date:subject:cc:to:from; bh=XcN0R64ay0subyuaTqrli2YWqqqppdT258U9pgi7TrY=; b=ghZJNfb05wnFtJnwCTTY+KjN01ZDcquv6Suz11mJHSktYeHJD6y4+LsMTpfuJSAsOc Y4HQTVgWDuACWrEJTiovucVks6rvUhDNo6fo+d/2sMU7gYK//X59Xa0hpDiTORz+5XoS 4XMpf9ZkRI0nN+u7hop9YHIvRCHB+6NiUi0I6smIypn4amyNCgMUfHM5zrPGNl+TZbrY acXDmkQPDpupWz0dQ8ca3Jv6lsY8S3hhIGTROoM/c3BNm1UKBYkwrxqEqZ1o0eGhtJx+ 0FJ387+BwgMzewrJb1/sOZmeIIF38zeO1mYi5zAu3kJDayuINjGHVBImOhf11UqvlBgw Bo7A== 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 42si3063269plb.193.2019.08.11.06.30.25; Sun, 11 Aug 2019 06:30:40 -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 S1726457AbfHKN3y (ORCPT + 99 others); Sun, 11 Aug 2019 09:29:54 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:52415 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726231AbfHKN3y (ORCPT ); Sun, 11 Aug 2019 09:29:54 -0400 Received: by mail-wm1-f65.google.com with SMTP id s3so9944122wms.2; Sun, 11 Aug 2019 06:29:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=XcN0R64ay0subyuaTqrli2YWqqqppdT258U9pgi7TrY=; b=esS+8BAnViIMBUVZU0YqRYUiYQnyjdtPOecbxwlEczHqVoY9tzP3HvUGvSMoVG4YNK EGJ44Qu/7hFquhNDYAsj7XZC0yTisoKXe6/7w/LUwx+Xc7m0+BEEG9qYVssAa4W0w2Fz CKKTTPHM50d8m8WP2KL61VRzljMZq/UVYwL04ODA0VS0UzHjzZ6T8/2UlFuGzmYCebBh Lg1ELk8JOub8j2BieFrLkUcdhXWCywk2jtL4TzXShlasGlwTBmmXH9sx68XtfkWUmz2v W2wnVpVp6pDBQSYYcSvwnFUPknJ3g6h0DsexnKE8/eSNGq9zMs6QfzUNumqfcqSQXFK6 /nMA== X-Gm-Message-State: APjAAAW9xixYVDRRth1rSDCylO32fIokwd7zfDXucj2dbmvoQybxoCiW mkGyqk1YXtVdDgpAc8Eltqw= X-Received: by 2002:a7b:c5c3:: with SMTP id n3mr22459656wmk.101.1565530191629; Sun, 11 Aug 2019 06:29:51 -0700 (PDT) Received: from localhost.localdomain (broadband-188-32-48-208.ip.moscow.rt.ru. [188.32.48.208]) by smtp.googlemail.com with ESMTPSA id o16sm13781463wrp.23.2019.08.11.06.29.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 11 Aug 2019 06:29:51 -0700 (PDT) From: Denis Efremov To: Bjorn Helgaas Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, Denis Efremov Subject: [PATCH 0/4] Simplify PCIe hotplug indicator control Date: Sun, 11 Aug 2019 16:29:41 +0300 Message-Id: <20190811132945.12426-1-efremov@linux.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org PCIe defines two optional hotplug indicators: a Power indicator and an Attention indicator. Both are controlled by the same register, and each can be on, off or blinking. The current interfaces (pciehp_green_led_{on,off,blink}() and pciehp_set_attention_status()) are non-uniform and require two register writes in many cases where we could do one. This patchset introduces the new function pciehp_set_indicators(). It allows one to set two indicators with a single register write. All calls to previous interfaces (pciehp_green_led_* and pciehp_set_attention_status()) are replaced with a new one. Denis Efremov (4): PCI: pciehp: Add pciehp_set_indicators() to jointly set LED indicators PCI: pciehp: Switch LED indicators with a single write PCI: pciehp: Replace pciehp_set_attention_status() PCI: pciehp: Replace pciehp_green_led_{on,off,blink}() drivers/pci/hotplug/pciehp.h | 31 +++++++++-- drivers/pci/hotplug/pciehp_ctrl.c | 14 ++--- drivers/pci/hotplug/pciehp_hpc.c | 87 +++++++++++++------------------ 3 files changed, 69 insertions(+), 63 deletions(-) -- 2.21.0