All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Heikki Lindholm <holindho@domain.hid>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-core] [BUG?] dead code in ipipe_grab_irq
Date: Mon, 30 Jan 2006 16:57:11 +0100	[thread overview]
Message-ID: <43DE3757.2070006@domain.hid> (raw)
In-Reply-To: <43DE32BF.30207@domain.hid>

Heikki Lindholm wrote:
> Anders Blomdell kirjoitti:
> 
>> In the following code (ppc), shouldn't first be either declared static 
>> or deleted? To me it looks like first is always equal to one when the 
>> else clause is evaluated.
> 
> 
> You're right. "first" doesn't need to be there at all, it's probably an 
> old copy of something in the kernel.
> 

Yep; used to be a while() loop in the original implementation we do not perform here.

>> asmlinkage int __ipipe_grab_irq(struct pt_regs *regs)
>> {
>>         extern int ppc_spurious_interrupts;
>>         ipipe_declare_cpuid;
>>         int irq, first = 1;
>>
>>         if ((irq = ppc_md.get_irq(regs)) >= 0) {
>>                 __ipipe_handle_irq(irq, regs);
>>                 first = 0;
>>         } else if (irq != -2 && first)
>>                 ppc_spurious_interrupts++;
>>
>>         ipipe_load_cpuid();
>>
>>         return (ipipe_percpu_domain[cpuid] == ipipe_root_domain &&
>>                 !test_bit(IPIPE_STALL_FLAG,
>>                           &ipipe_root_domain->cpudata[cpuid].status));
>> }
>>
>>
>> Regards
>>
>> Anders Blomdell
>>
>>
>>
>> _______________________________________________
>> Xenomai-core mailing list
>> Xenomai-core@domain.hid
>> https://mail.gna.org/listinfo/xenomai-core
> 
> 
> 
> _______________________________________________
> Xenomai-core mailing list
> Xenomai-core@domain.hid
> https://mail.gna.org/listinfo/xenomai-core
> 


-- 

Philippe.


      reply	other threads:[~2006-01-30 15:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-30 14:58 [Xenomai-core] [BUG?] dead code in ipipe_grab_irq Anders Blomdell
2006-01-30 15:37 ` Heikki Lindholm
2006-01-30 15:57   ` Philippe Gerum [this message]

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=43DE3757.2070006@domain.hid \
    --to=rpm@xenomai.org \
    --cc=holindho@domain.hid \
    --cc=xenomai@xenomai.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.