linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Dan Malek <dan@embeddededge.com>
To: Guillaume Autran <gautran@mrv.com>
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: [PATCH] ppc32: fix cpm_uart_int() missing interrupts
Date: Thu, 19 May 2005 15:54:54 -0400	[thread overview]
Message-ID: <5e493590088edcf959e30390363e798d@embeddededge.com> (raw)
In-Reply-To: <428CEA55.1040904@mrv.com>


On May 19, 2005, at 3:34 PM, Guillaume Autran wrote:

> Is it better like this ?

Yes, but now I see one problem with it.  :-)

We have to clear all events even though we may not
handle all of them.  Your while loop filters only the events
we process, but there could be others causing the interrupt
which will never get cleared.  In this case we end up with
an infinite interrupt loop where we don't process anything,
but we don't make the interrupt go away, either.   It may be
easier to forget the loop, just read/clear the event register
up front, then process based on the events based upon
what we found. It's what we tend to do in the other drivers.

The functions called to do the rx/tx processing have loops
in them to process all of the data they find, so it isn't likely
you have left anything behind.  If you want to try to save
the interrupt overhead, change it to do/while, check again
at the end before the exit.

Thanks.


	-- Dan

  reply	other threads:[~2005-05-19 19:54 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-18 17:09 [PATCH] ppc32: fix CONFIG_TASK_SIZE handling on 40x Eugene Surovegin
2005-05-19 17:59 ` [PATCH] ppc32: fix cpm_uart_int() missing interrupts Guillaume Autran
2005-05-19 18:11   ` Dan Malek
2005-05-19 19:34     ` Guillaume Autran
2005-05-19 19:54       ` Dan Malek [this message]
2005-05-19 20:26         ` Guillaume Autran
2005-05-19 20:32           ` Dan Malek
2005-05-19 20:36           ` Guillaume Autran
2005-05-20 14:19             ` Dan Malek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5e493590088edcf959e30390363e798d@embeddededge.com \
    --to=dan@embeddededge.com \
    --cc=gautran@mrv.com \
    --cc=linuxppc-embedded@ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).