Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp654289imu; Fri, 4 Jan 2019 04:49:11 -0800 (PST) X-Google-Smtp-Source: ALg8bN5XH0wUhvTgmvxH9orKDQwMrcQVFO1QZ14nQy67h8uF9ht4HD63OSbjtzEM6R9NkGZoa5Po X-Received: by 2002:a17:902:6bc9:: with SMTP id m9mr50253623plt.173.1546606151881; Fri, 04 Jan 2019 04:49:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546606151; cv=none; d=google.com; s=arc-20160816; b=BIrMsp2NaxjuxoPXeWqBNPuKsICleBIrRyRS6AVFj9Au5SRyevIbEn1HQ4e+gZwYHo D96NKvwOmRqu85wl0xP4a8SoHRuGTq6Bv7K96g4LEgco7dYgO75AVyZS9oHq1VBQycB/ UxU1KghPhEchLvCk8oCFgTOSDWF5nalr3Hsl0V3ItlNyeUoAnb3LwFnBQtVBDrnJLkxL /7Nwvy0iLFXHXJpPNjLp7OuzYEc0UDoh2YYOAaFHxOY6GbzFdPlc8bCvbB3RZUC10k4w MODG22rW2OJQDk1UQKWXzclfGzJX5XMoenPxc2Dgjyr/Kzh/5DJa4+mNG76XUxG6/jLo JyuQ== 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=FjB0hxHy8YS1yePIBV12UtVQyLtZSwDjBK78FJZ2qCQ=; b=SeLZgT1phaW8E1jr81GB58dTY0J6FCx2WgXiLkdDcKaCnEp6Y1FhwtG0e63FCAu878 mzZB3hAZwx7vLSGNkryJinPsJAy2Vf/N6oFz2A8/6by4xvDfdVY0s1s5kbKRTnTu39Wd bVpj2nNZ1uy5axjuj/U2Wo3mXVwtctgcYUfFPuKq3sxjz3FrhIBe8TXH4e6gIxtk8G7A pzVExQO1guDK37etAIF//1l9kPSuz2g0rkjSzj9nX6s5oiQcJlBxY2nAxq0XkyGxsVrC XaKWlYVkRz2Ff9vKuL0xadNmxcQyYPePkQAGBQB6lFRglMi8KpwJ0Z3RYfcmiFSJEl2X Eguw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=cirrus.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h69si35582124pge.121.2019.01.04.04.48.54; Fri, 04 Jan 2019 04:49:11 -0800 (PST) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=cirrus.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727496AbfADLOy (ORCPT + 99 others); Fri, 4 Jan 2019 06:14:54 -0500 Received: from mx0a-001ae601.pphosted.com ([67.231.149.25]:46264 "EHLO mx0b-001ae601.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726970AbfADLOy (ORCPT ); Fri, 4 Jan 2019 06:14:54 -0500 Received: from pps.filterd (m0077473.ppops.net [127.0.0.1]) by mx0a-001ae601.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x04BEjqi007248; Fri, 4 Jan 2019 05:14:45 -0600 Authentication-Results: ppops.net; spf=none smtp.mailfrom=ckeepax@opensource.cirrus.com Received: from mail3.cirrus.com ([87.246.76.56]) by mx0a-001ae601.pphosted.com with ESMTP id 2pp7777ph0-1; Fri, 04 Jan 2019 05:14:44 -0600 Received: from EX17.ad.cirrus.com (ex17.ad.cirrus.com [172.20.9.81]) by mail3.cirrus.com (Postfix) with ESMTP id 9795F611C8AC; Fri, 4 Jan 2019 05:17:47 -0600 (CST) Received: from imbe.wolfsonmicro.main (198.61.95.81) by EX17.ad.cirrus.com (172.20.9.81) with Microsoft SMTP Server id 14.3.408.0; Fri, 4 Jan 2019 11:14:44 +0000 Received: from imbe.wolfsonmicro.main (imbe.wolfsonmicro.main [198.61.95.81]) by imbe.wolfsonmicro.main (8.14.4/8.14.4) with ESMTP id x04BEhPS014993; Fri, 4 Jan 2019 11:14:43 GMT Date: Fri, 4 Jan 2019 11:14:43 +0000 From: Charles Keepax To: Matti Vaittinen CC: , , , , , , , Subject: Re: [PATCH] regmap: regmap-irq: Make irq-type callbak optional Message-ID: <20190104111443.GS16508@imbe.wolfsonmicro.main> References: <20190104103115.GA10043@localhost.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20190104103115.GA10043@localhost.localdomain> User-Agent: Mutt/1.5.20 (2009-12-10) X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=440 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901040101 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 04, 2019 at 12:31:15PM +0200, Matti Vaittinen wrote: > Do not register type setting callback if HW does not support > setting the irq type. IRQ core can then handle cases where > type setting is not supported and no regmap-irq specific handling > is required. > > Signed-off-by: Matti Vaittinen > --- > drivers/base/regmap/regmap-irq.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/drivers/base/regmap/regmap-irq.c b/drivers/base/regmap/regmap-irq.c > index d2d0014b0d23..a387ee499b5c 100644 > --- a/drivers/base/regmap/regmap-irq.c > +++ b/drivers/base/regmap/regmap-irq.c > @@ -322,7 +322,6 @@ static const struct irq_chip regmap_irq_chip = { > .irq_bus_sync_unlock = regmap_irq_sync_unlock, > .irq_disable = regmap_irq_disable, > .irq_enable = regmap_irq_enable, > - .irq_set_type = regmap_irq_set_type, > .irq_set_wake = regmap_irq_set_wake, > }; > > @@ -560,6 +559,9 @@ int regmap_add_irq_chip(struct regmap *map, int irq, int irq_flags, > d->chip = chip; > d->irq_base = irq_base; > > + if (num_type_reg) > + d->irq_chip.irq_set_type = regmap_irq_set_type; > + > if (chip->irq_reg_stride) > d->irq_reg_stride = chip->irq_reg_stride; > else Afraid this also causes regressions at my end, still having a bit of a look but it looks like some how this prevents properties of the IRQ getting passed along which causes my system to not probe properly with: genirq: Flags mismatch irq 58. 00002088 (cs35l35) vs. 00002088 (cs35l35) cs35l35 0-0041: Failed to request IRQ: -16 Thanks, Charles > -- > 2.14.3 > > > -- > Matti Vaittinen > ROHM Semiconductors > > ~~~ "I don't think so," said Rene Descartes. Just then, he vanished ~~~