pgreco / rpms / kernel

Forked from rpms/kernel 4 years ago
Clone
Pablo Greco d6c4c4
From patchwork Wed Oct  2 14:43:18 2019
Pablo Greco d6c4c4
Content-Type: text/plain; charset="utf-8"
Pablo Greco d6c4c4
MIME-Version: 1.0
Pablo Greco d6c4c4
Content-Transfer-Encoding: 7bit
Pablo Greco d6c4c4
X-Patchwork-Submitter: Thierry Reding <thierry.reding@gmail.com>
Pablo Greco d6c4c4
X-Patchwork-Id: 11171225
Pablo Greco d6c4c4
Return-Path: 
Pablo Greco d6c4c4
 <SRS0=hIqC=X3=lists.infradead.org=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@kernel.org>
Pablo Greco d6c4c4
Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org
Pablo Greco d6c4c4
 [172.30.200.123])
Pablo Greco d6c4c4
	by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C771E1747
Pablo Greco d6c4c4
	for <patchwork-linux-arm@patchwork.kernel.org>;
Pablo Greco d6c4c4
 Wed,  2 Oct 2019 14:45:14 +0000 (UTC)
Pablo Greco d6c4c4
Received: from bombadil.infradead.org (bombadil.infradead.org
Pablo Greco d6c4c4
 [198.137.202.133])
Pablo Greco d6c4c4
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
Pablo Greco d6c4c4
	(No client certificate requested)
Pablo Greco d6c4c4
	by mail.kernel.org (Postfix) with ESMTPS id 9703B21D81
Pablo Greco d6c4c4
	for <patchwork-linux-arm@patchwork.kernel.org>;
Pablo Greco d6c4c4
 Wed,  2 Oct 2019 14:45:14 +0000 (UTC)
Pablo Greco d6c4c4
Authentication-Results: mail.kernel.org;
Pablo Greco d6c4c4
	dkim=pass (2048-bit key) header.d=lists.infradead.org
Pablo Greco d6c4c4
 header.i=@lists.infradead.org header.b="LCP5OdWP";
Pablo Greco d6c4c4
	dkim=fail reason="signature verification failed" (2048-bit key)
Pablo Greco d6c4c4
 header.d=gmail.com header.i=@gmail.com header.b="ahoJ80fO"
Pablo Greco d6c4c4
DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9703B21D81
Pablo Greco d6c4c4
Authentication-Results: mail.kernel.org;
Pablo Greco d6c4c4
 dmarc=fail (p=none dis=none) header.from=gmail.com
Pablo Greco d6c4c4
Authentication-Results: mail.kernel.org;
Pablo Greco d6c4c4
 spf=none
Pablo Greco d6c4c4
 smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
Pablo Greco d6c4c4
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
Pablo Greco d6c4c4
	d=lists.infradead.org; s=bombadil.20170209; h=Sender:
Pablo Greco d6c4c4
	Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post:
Pablo Greco d6c4c4
	List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To
Pablo Greco d6c4c4
	:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:
Pablo Greco d6c4c4
	Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:
Pablo Greco d6c4c4
	List-Owner; bh=csIWPoJz7RR9msf1imaCNOLXiDPcaRmxRKjOL8gMaXM=; b=LCP5OdWPpIBxJz
Pablo Greco d6c4c4
	tSNffGBZI2pwLSarAvmqKIowLW5LghNe3CVQh7HM3sIR+IqrUtTSXi/0EEQAQORrYHSnR4zrDlubl
Pablo Greco d6c4c4
	8IIqIetbgOrEmYRpHQxWZV/Z0p5JTdvNVeOiR63CuFbjz/h9UXPWOiLZijU1eZfSN2UuEJWxzoWMF
Pablo Greco d6c4c4
	CsXxW+3rZ3os8AAa9x0lt6gGLwAPEPrxP44q4AJTVp3q+cD7GTXHu0F2ZT2flxES+cFF2/cPg2GiM
Pablo Greco d6c4c4
	yR5j7GNMDhdxFKjGp8qcDhfCKx/0jF0DofnC4JsVlN0R25HdwYHzdHhysk8ca7JxLIMJlgXsgM5aY
Pablo Greco d6c4c4
	4XUIEB/0CjoPtdbP+8yw==;
Pablo Greco d6c4c4
Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org)
Pablo Greco d6c4c4
	by bombadil.infradead.org with esmtp (Exim 4.92.2 #3 (Red Hat Linux))
Pablo Greco d6c4c4
	id 1iFfsO-0006Nf-SR; Wed, 02 Oct 2019 14:45:12 +0000
Pablo Greco d6c4c4
Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443])
Pablo Greco d6c4c4
 by bombadil.infradead.org with esmtps (Exim 4.92.2 #3 (Red Hat Linux))
Pablo Greco d6c4c4
 id 1iFfqd-0003rK-EL
Pablo Greco d6c4c4
 for linux-arm-kernel@lists.infradead.org; Wed, 02 Oct 2019 14:43:47 +0000
Pablo Greco d6c4c4
Received: by mail-wr1-x443.google.com with SMTP id w12so19991081wro.5
Pablo Greco d6c4c4
 for <linux-arm-kernel@lists.infradead.org>;
Pablo Greco d6c4c4
 Wed, 02 Oct 2019 07:43:21 -0700 (PDT)
Pablo Greco d6c4c4
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
Pablo Greco d6c4c4
 h=from:to:cc:subject:date:message-id:mime-version
Pablo Greco d6c4c4
 :content-transfer-encoding;
Pablo Greco d6c4c4
 bh=y9l/1MkRoZLCyZNPXaR5fzwvTbuyIzYA20JLtWuhYR4=;
Pablo Greco d6c4c4
 b=ahoJ80fONPxwQPqvbuQRAba40syj0YJFK3SbqTxd0FOzhs1n3WTvNd/gHQ+2WK5WwB
Pablo Greco d6c4c4
 8joqipXveUGBgePR1RwHR0oQyDAumewRmSMStvhyCHPeo154CNqZfGQNlbNlRng2QJqd
Pablo Greco d6c4c4
 1/Sq8GNJ1DjcLifpHWbCC9LoK5U3UkvdIWHPFx0cqJ+ENvPHkYPr2FdpaZ8jxuJta3TT
Pablo Greco d6c4c4
 dplkNk0AsL/tc33KBJbKUSlnYppX878WQXUvnhdB+TRmr5R3dtc5Ewc0TH4h7V1SXTly
Pablo Greco d6c4c4
 GiNnbbCc+BKzzqk9PTo/Pqf5dzWcpNDBA1GUkzQZDTXOXXUzBjnlrTaQctjSdE6meWfJ
Pablo Greco d6c4c4
 JbDw==
Pablo Greco d6c4c4
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
Pablo Greco d6c4c4
 d=1e100.net; s=20161025;
Pablo Greco d6c4c4
 h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version
Pablo Greco d6c4c4
 :content-transfer-encoding;
Pablo Greco d6c4c4
 bh=y9l/1MkRoZLCyZNPXaR5fzwvTbuyIzYA20JLtWuhYR4=;
Pablo Greco d6c4c4
 b=m4CouDn44ioMScPU+9h/V5vlxCAt0m4CSZKRu3pcsThkHE6u1TeKieaoBr1mh1qnIv
Pablo Greco d6c4c4
 YS+V9Cd7osJa8R8USg+SJkEaSSarOn4kUq2MPTgMMmvKb63SSCCs0QD44nwEBAjIgMd/
Pablo Greco d6c4c4
 /akFUOMTGQBnN7P8Iq3KWI00bVJLeoVWmqtQPkLFI1cIRrkCKTF4jh6b+i6xsiT8t2rd
Pablo Greco d6c4c4
 l6WPsWnKkqUmPAqzpmLJ9bmSsiGBBFUexUJDcQnskkx6tTBzFhyNtpsbq6VdcY2mS3LR
Pablo Greco d6c4c4
 rgGbisZRFdLvdZfGhmPX1hRgDoiHQLuWNAv49LtJtR7/CjNFmsKr4MBg1ydz0uO01Axr
Pablo Greco d6c4c4
 zoIQ==
Pablo Greco d6c4c4
X-Gm-Message-State: APjAAAXPZ9a+CEGZKeL6T+FXZoBRFrxryg3xujpPFnNpjznB8ehsaTI0
Pablo Greco d6c4c4
 P6wL6cWqK9IRnS17Y/YRAb4=
Pablo Greco d6c4c4
X-Google-Smtp-Source: 
Pablo Greco d6c4c4
 APXvYqyETp8FIXhzzDrv+mhfzHhU0D9h3bcpLQ9oRbkEYPG7JvxLk5RVWx/ooYmku2+exI6oXsHTnA==
Pablo Greco d6c4c4
X-Received: by 2002:a5d:4dd0:: with SMTP id f16mr2905889wru.85.1570027400467;
Pablo Greco d6c4c4
 Wed, 02 Oct 2019 07:43:20 -0700 (PDT)
Pablo Greco d6c4c4
Received: from localhost (p2E5BE2CE.dip0.t-ipconnect.de. [46.91.226.206])
Pablo Greco d6c4c4
 by smtp.gmail.com with ESMTPSA id z125sm10251381wme.37.2019.10.02.07.43.19
Pablo Greco d6c4c4
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Pablo Greco d6c4c4
 Wed, 02 Oct 2019 07:43:19 -0700 (PDT)
Pablo Greco d6c4c4
From: Thierry Reding <thierry.reding@gmail.com>
Pablo Greco d6c4c4
To: Lee Jones <lee.jones@linaro.org>
Pablo Greco d6c4c4
Subject: [PATCH] mfd: max77620: Do not allocate IRQs upfront
Pablo Greco d6c4c4
Date: Wed,  2 Oct 2019 16:43:18 +0200
Pablo Greco d6c4c4
Message-Id: <20191002144318.140365-1-thierry.reding@gmail.com>
Pablo Greco d6c4c4
X-Mailer: git-send-email 2.23.0
Pablo Greco d6c4c4
MIME-Version: 1.0
Pablo Greco d6c4c4
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 
Pablo Greco d6c4c4
X-CRM114-CacheID: sfid-20191002_074330_018855_CC323A91 
Pablo Greco d6c4c4
X-CRM114-Status: GOOD (  11.81  )
Pablo Greco d6c4c4
X-Spam-Score: -0.2 (/)
Pablo Greco d6c4c4
X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary:
Pablo Greco d6c4c4
 Content analysis details:   (-0.2 points)
Pablo Greco d6c4c4
 pts rule name              description
Pablo Greco d6c4c4
 ---- ----------------------
Pablo Greco d6c4c4
 --------------------------------------------------
Pablo Greco d6c4c4
 -0.0 RCVD_IN_DNSWL_NONE     RBL: Sender listed at https://www.dnswl.org/,
Pablo Greco d6c4c4
 no trust [2a00:1450:4864:20:0:0:0:443 listed in]
Pablo Greco d6c4c4
 [list.dnswl.org]
Pablo Greco d6c4c4
 -0.0 SPF_PASS               SPF: sender matches SPF record
Pablo Greco d6c4c4
 0.0 SPF_HELO_NONE          SPF: HELO does not publish an SPF Record
Pablo Greco d6c4c4
 0.0 FREEMAIL_FROM          Sender email is commonly abused enduser mail
Pablo Greco d6c4c4
 provider (thierry.reding[at]gmail.com)
Pablo Greco d6c4c4
 -0.1 DKIM_VALID_EF          Message has a valid DKIM or DK signature from
Pablo Greco d6c4c4
 envelope-from domain
Pablo Greco d6c4c4
 0.1 DKIM_SIGNED            Message has a DKIM or DK signature,
Pablo Greco d6c4c4
 not necessarily
Pablo Greco d6c4c4
 valid
Pablo Greco d6c4c4
 -0.1 DKIM_VALID_AU          Message has a valid DKIM or DK signature from
Pablo Greco d6c4c4
 author's domain
Pablo Greco d6c4c4
 -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature
Pablo Greco d6c4c4
X-BeenThere: linux-arm-kernel@lists.infradead.org
Pablo Greco d6c4c4
X-Mailman-Version: 2.1.29
Pablo Greco d6c4c4
Precedence: list
Pablo Greco d6c4c4
List-Id: <linux-arm-kernel.lists.infradead.org>
Pablo Greco d6c4c4
List-Unsubscribe: 
Pablo Greco d6c4c4
 <http://lists.infradead.org/mailman/options/linux-arm-kernel>,
Pablo Greco d6c4c4
 <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe>
Pablo Greco d6c4c4
List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/>
Pablo Greco d6c4c4
List-Post: <mailto:linux-arm-kernel@lists.infradead.org>
Pablo Greco d6c4c4
List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help>
Pablo Greco d6c4c4
List-Subscribe: 
Pablo Greco d6c4c4
 <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>,
Pablo Greco d6c4c4
 <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe>
Pablo Greco d6c4c4
Cc: linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org,
Pablo Greco d6c4c4
 linux-arm-kernel@lists.infradead.org
Pablo Greco d6c4c4
Content-Type: text/plain; charset="us-ascii"
Pablo Greco d6c4c4
Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org>
Pablo Greco d6c4c4
Errors-To: 
Pablo Greco d6c4c4
 linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org
Pablo Greco d6c4c4
Pablo Greco d6c4c4
From: Thierry Reding <treding@nvidia.com>
Pablo Greco d6c4c4
Pablo Greco d6c4c4
regmap_add_irq_chip() will try to allocate all of the IRQ descriptors
Pablo Greco d6c4c4
upfront if passed a non-zero irq_base parameter. However, the intention
Pablo Greco d6c4c4
is to allocate IRQ descriptors on an as-needed basis if possible. Pass 0
Pablo Greco d6c4c4
instead of -1 to fix that use-case.
Pablo Greco d6c4c4
Pablo Greco d6c4c4
Signed-off-by: Thierry Reding <treding@nvidia.com>
Pablo Greco d6c4c4
---
Pablo Greco d6c4c4
 drivers/mfd/max77620.c       | 5 ++---
Pablo Greco d6c4c4
 include/linux/mfd/max77620.h | 1 -
Pablo Greco d6c4c4
 2 files changed, 2 insertions(+), 4 deletions(-)
Pablo Greco d6c4c4
Pablo Greco d6c4c4
diff --git a/drivers/mfd/max77620.c b/drivers/mfd/max77620.c
Pablo Greco d6c4c4
index a851ff473a44..c7ed5c353553 100644
Pablo Greco d6c4c4
--- a/drivers/mfd/max77620.c
Pablo Greco d6c4c4
+++ b/drivers/mfd/max77620.c
Pablo Greco d6c4c4
@@ -507,7 +507,6 @@ static int max77620_probe(struct i2c_client *client,
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
 	i2c_set_clientdata(client, chip);
Pablo Greco d6c4c4
 	chip->dev = &client->dev;
Pablo Greco d6c4c4
-	chip->irq_base = -1;
Pablo Greco d6c4c4
 	chip->chip_irq = client->irq;
Pablo Greco d6c4c4
 	chip->chip_id = (enum max77620_chip_id)id->driver_data;
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
@@ -545,8 +544,8 @@ static int max77620_probe(struct i2c_client *client,
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
 	max77620_top_irq_chip.irq_drv_data = chip;
Pablo Greco d6c4c4
 	ret = devm_regmap_add_irq_chip(chip->dev, chip->rmap, client->irq,
Pablo Greco d6c4c4
-				       IRQF_ONESHOT | IRQF_SHARED,
Pablo Greco d6c4c4
-				       chip->irq_base, &max77620_top_irq_chip,
Pablo Greco d6c4c4
+				       IRQF_ONESHOT | IRQF_SHARED, 0,
Pablo Greco d6c4c4
+				       &max77620_top_irq_chip,
Pablo Greco d6c4c4
 				       &chip->top_irq_data);
Pablo Greco d6c4c4
 	if (ret < 0) {
Pablo Greco d6c4c4
 		dev_err(chip->dev, "Failed to add regmap irq: %d\n", ret);
Pablo Greco d6c4c4
diff --git a/include/linux/mfd/max77620.h b/include/linux/mfd/max77620.h
Pablo Greco d6c4c4
index 12ba157cb83f..f552ef5b1100 100644
Pablo Greco d6c4c4
--- a/include/linux/mfd/max77620.h
Pablo Greco d6c4c4
+++ b/include/linux/mfd/max77620.h
Pablo Greco d6c4c4
@@ -329,7 +329,6 @@ struct max77620_chip {
Pablo Greco d6c4c4
 	struct regmap *rmap;
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
 	int chip_irq;
Pablo Greco d6c4c4
-	int irq_base;
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
 	/* chip id */
Pablo Greco d6c4c4
 	enum max77620_chip_id chip_id;