Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751968AbbBRLpT (ORCPT ); Wed, 18 Feb 2015 06:45:19 -0500 Received: from down.free-electrons.com ([37.187.137.238]:38770 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751050AbbBRLpR (ORCPT ); Wed, 18 Feb 2015 06:45:17 -0500 Message-ID: <54E47ABF.8070306@free-electrons.com> Date: Wed, 18 Feb 2015 08:42:55 -0300 From: Ezequiel Garcia User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Robert Jarzmik , David Woodhouse , Brian Norris , Maxime Ripard CC: linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mtd: pxa3xx-nand: handle PIO in threaded interrupt References: <1424203617-29431-1-git-send-email-robert.jarzmik@free.fr> In-Reply-To: <1424203617-29431-1-git-send-email-robert.jarzmik@free.fr> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1568 Lines: 42 On 02/17/2015 05:06 PM, Robert Jarzmik wrote: > Change the handling of the data stage in the driver : don't pump data in > the top-half interrupt, but rather schedule a thread for non dma cases. > > This will enable latencies in the data pumping, especially if delays are > required. Moreover platform shall be more reactive as other interrupts > can be served while pumping data. > > No throughput degradation was observed, at least on the zylonite > platform, while a slight degradation was being expected. > > Signed-off-by: Robert Jarzmik > --- > drivers/mtd/nand/pxa3xx_nand.c | 23 ++++++++++++++++++++--- > 1 file changed, 20 insertions(+), 3 deletions(-) > > diff --git a/drivers/mtd/nand/pxa3xx_nand.c b/drivers/mtd/nand/pxa3xx_nand.c > index 96b0b1d..237c92c 100644 > --- a/drivers/mtd/nand/pxa3xx_nand.c > +++ b/drivers/mtd/nand/pxa3xx_nand.c > @@ -569,11 +569,25 @@ static void start_data_dma(struct pxa3xx_nand_info *info) > {} > #endif > > +static irqreturn_t pxa3xx_nand_irq_thread(int irq, void *data) > +{ > + struct pxa3xx_nand_info *info = data; > + > + handle_data_pio(info); > + > + info->state = STATE_CMD_DONE; Are you sure you need to set the state here? -- Ezequiel Garc?a, Free Electrons Embedded Linux, Kernel and Android Engineering http://free-electrons.com -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/