From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752496AbdGHMIe (ORCPT ); Sat, 8 Jul 2017 08:08:34 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:34470 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750826AbdGHMId (ORCPT ); Sat, 8 Jul 2017 08:08:33 -0400 Date: Sat, 8 Jul 2017 14:08:25 +0200 (CEST) From: Thomas Gleixner To: Doug Berger cc: Marc Zyngier , Bartosz Golaszewski , Sebastian Frias , Boris Brezillon , open list Subject: Re: [PATCH 1/6] genirq: generic chip: add generic irq_mask_ack functions In-Reply-To: <20170707192016.13001-2-opendmb@gmail.com> Message-ID: References: <20170707192016.13001-1-opendmb@gmail.com> <20170707192016.13001-2-opendmb@gmail.com> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 7 Jul 2017, Doug Berger wrote: > The irq_gc_mask_disable_reg_and_ack() function name implies that it > provides the combined functions of irq_gc_mask_disable_reg() and > irq_gc_ack(). However, the implementation does not actually do > that since it writes the mask instead of the disable register. It > also does not maintain the mask cache which makes it inappropriate > to use with other masking functions. > > In addition, commit 659fb32d1b67 ("genirq: replace irq_gc_ack() with > {set,clr}_bit variants (fwd)") effectively renamed irq_gc_ack() to > irq_gc_set_bit() so this function probably should have also been > renamed at that time. > > Since this generic chip code provides three mask functions and two > ack functions, this commit provides generic implementations for all > six combinations of the mask and ack functions suitable for use > with the irq_mask_ack member of the struct irq_chip. We have exactly one user of irq_gc_mask_disable_reg_and_ack() and that needs exactly on function as replacement. Why do we need 6 variants of that right now? Thanks, tglx