* MXC nand controller performance
@ 2009-08-20 12:57 Sascha Hauer
2009-08-20 20:10 ` Magnus Lilja
0 siblings, 1 reply; 4+ messages in thread
From: Sascha Hauer @ 2009-08-20 12:57 UTC (permalink / raw)
To: Linux MTD list
Cc: Vladimir Barinov, Magnus Lilja, Eric Benard, Daniel Mack,
Alberto Panizzo
Hi,
Hi recently found out that on my i.MX27 board the mxc nand controller
performance nearly doubles when I disable interrupts. Can anybody
confirm this behaviour, possibly on other i.MXs?
I'm trying to figure out what to do. We could disable interrupts
completely in which case the driver would become simpler. Maybe using
polling mode has other impacts on other workloads, so maybe we want to
add a flag to platform_data instead of disabling interrupts completely.
You can use the following patch to disable interrupts. It is not meant
for inclusion in this form of course.
Sascha
>From ae3909b90667a13f7bbd6a042b6b65ea7c74ee48 Mon Sep 17 00:00:00 2001
From: Sascha Hauer <s.hauer@pengutronix.de>
Date: Thu, 20 Aug 2009 14:52:32 +0200
Subject: [PATCH] mxc_nand: disable interrupts
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
drivers/mtd/nand/mxc_nand.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/mtd/nand/mxc_nand.c b/drivers/mtd/nand/mxc_nand.c
index 76beea4..bcc5929 100644
--- a/drivers/mtd/nand/mxc_nand.c
+++ b/drivers/mtd/nand/mxc_nand.c
@@ -175,6 +175,8 @@ static void wait_op_done(struct mxc_nand_host *host, int max_retries,
{
uint32_t tmp;
+ useirq = 0;
+
if (useirq) {
if ((readw(host->regs + NFC_CONFIG2) & NFC_INT) == 0) {
--
1.6.3.3
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: MXC nand controller performance
2009-08-20 12:57 MXC nand controller performance Sascha Hauer
@ 2009-08-20 20:10 ` Magnus Lilja
2009-08-21 12:22 ` Sascha Hauer
0 siblings, 1 reply; 4+ messages in thread
From: Magnus Lilja @ 2009-08-20 20:10 UTC (permalink / raw)
To: Sascha Hauer
Cc: Vladimir Barinov, Linux MTD list, Eric Benard, Daniel Mack,
Alberto Panizzo
Hi Sascha,
2009/8/20 Sascha Hauer <s.hauer@pengutronix.de>:
> Hi,
>
> Hi recently found out that on my i.MX27 board the mxc nand controller
> performance nearly doubles when I disable interrupts. Can anybody
> confirm this behaviour, possibly on other i.MXs?
> I'm trying to figure out what to do. We could disable interrupts
> completely in which case the driver would become simpler. Maybe using
> polling mode has other impacts on other workloads, so maybe we want to
> add a flag to platform_data instead of disabling interrupts completely.
A flag sounds like a good idea.
> You can use the following patch to disable interrupts. It is not meant
> for inclusion in this form of course.
I can give it a try on i.MX31, how do you measure the performance?
/Magnus
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: MXC nand controller performance
2009-08-20 20:10 ` Magnus Lilja
@ 2009-08-21 12:22 ` Sascha Hauer
2009-08-23 19:39 ` Magnus Lilja
0 siblings, 1 reply; 4+ messages in thread
From: Sascha Hauer @ 2009-08-21 12:22 UTC (permalink / raw)
To: Magnus Lilja
Cc: Vladimir Barinov, Linux MTD list, Eric Benard, Daniel Mack,
Alberto Panizzo
On Thu, Aug 20, 2009 at 10:10:27PM +0200, Magnus Lilja wrote:
> Hi Sascha,
>
> 2009/8/20 Sascha Hauer <s.hauer@pengutronix.de>:
> > Hi,
> >
> > Hi recently found out that on my i.MX27 board the mxc nand controller
> > performance nearly doubles when I disable interrupts. Can anybody
> > confirm this behaviour, possibly on other i.MXs?
> > I'm trying to figure out what to do. We could disable interrupts
> > completely in which case the driver would become simpler. Maybe using
> > polling mode has other impacts on other workloads, so maybe we want to
> > add a flag to platform_data instead of disabling interrupts completely.
>
> A flag sounds like a good idea.
>
> > You can use the following patch to disable interrupts. It is not meant
> > for inclusion in this form of course.
>
> I can give it a try on i.MX31, how do you measure the performance?
I did a 'time cat /dev/mtdblockx > /dev/null' and looked at the time
needed to mount an ubifs. I haven't done any write tests though.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: MXC nand controller performance
2009-08-21 12:22 ` Sascha Hauer
@ 2009-08-23 19:39 ` Magnus Lilja
0 siblings, 0 replies; 4+ messages in thread
From: Magnus Lilja @ 2009-08-23 19:39 UTC (permalink / raw)
To: Sascha Hauer
Cc: Vladimir Barinov, Linux MTD list, Eric Benard, Daniel Mack,
Alberto Panizzo
Hi
2009/8/21 Sascha Hauer <s.hauer@pengutronix.de>:
> On Thu, Aug 20, 2009 at 10:10:27PM +0200, Magnus Lilja wrote:
>> Hi Sascha,
>>
>> 2009/8/20 Sascha Hauer <s.hauer@pengutronix.de>:
>> > Hi,
>> >
>> > Hi recently found out that on my i.MX27 board the mxc nand controller
>> > performance nearly doubles when I disable interrupts. Can anybody
>> > confirm this behaviour, possibly on other i.MXs?
>> > I'm trying to figure out what to do. We could disable interrupts
>> > completely in which case the driver would become simpler. Maybe using
>> > polling mode has other impacts on other workloads, so maybe we want to
>> > add a flag to platform_data instead of disabling interrupts completely.
>>
>> A flag sounds like a good idea.
>>
>> > You can use the following patch to disable interrupts. It is not meant
>> > for inclusion in this form of course.
>>
>> I can give it a try on i.MX31, how do you measure the performance?
>
> I did a 'time cat /dev/mtdblockx > /dev/null' and looked at the time
> needed to mount an ubifs. I haven't done any write tests though.
I did some tests on a i.MX31 Litekit board using a kernel from Linus'
tree a couple of days ago ('time cat /dev/mtdblockx > /dev/null'):
with interrupts: 18s
without interrupts: 13s
No write tests or mounting filesystems were done.
/Magnus
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-08-23 19:39 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-20 12:57 MXC nand controller performance Sascha Hauer
2009-08-20 20:10 ` Magnus Lilja
2009-08-21 12:22 ` Sascha Hauer
2009-08-23 19:39 ` Magnus Lilja
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox