LinuxPPC-Dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Alex Zeffertt <ajz@cambridgebroadband.com>
To: scarayol@assystembrime.com
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: MPC885 interruptions  : help !
Date: Wed, 15 Jun 2005 11:26:56 +0100	[thread overview]
Message-ID: <20050615112656.562f8209.ajz@cambridgebroadband.com> (raw)
In-Reply-To: <OF5286B922.38B1A4B5-ONC1257020.002FEFD0@brime.fr>

Pins on the 8xx are highly configurable.  I recommend that you check
that the pin has not been configured for another  function.  For example
on the 862 the SIU_IRQ7 pin doubles as the MII tx clock.

Alex

On Wed, 15 Jun 2005 10:35:41 +0200
scarayol@assystembrime.com wrote:

> Hi all,
> 
> I wrote a module driver to manage interruptions. I have an
> interruption on MPC885 IRQ7 activated by a push button that provides a
> negative pulse of 200 ns width.
> When the device is open, i call request_irq() to install the interrupt
> handler:
> 
> int ret = request_irq(SIU_IRQ7, fpgadriver_irq_save_handler,
> SA_INTERRUPT, FPGA_ID, NULL);
> 
> void fpgadriver_irq_save_handler(int irq, void *dev_id, struct pt_regs
> *regs)
> {
>   fpga_it_source=FPGA_IRQ_SAVE;
>   printk( "fpgadriver: fpgadriver_irq_save_handler for device \n");
>   /* Prepare a task */
>   PREPARE_TQUEUE(&fpgadriver_bh_task, fpgadriver_bh_handler, dev_id);
>   /* Add a task to the immediate bottom half and mark it for schedule
>   */ queue_task(&fpgadriver_bh_task, &tq_immediate);
>    mark_bh(IMMEDIATE_BH);
> }
> 
> my read() is like that :
> 
> static ssize_t fpgadriver_read(struct file *file, char *buf, size_t
> count, loff_t *ppos)
> {
>   //mise a jour de l'indicateur d'etat d'endormissement
>   wakeups++;
>   interruptible_sleep_on(&readq);
>   buf[0]=fpga_it_source;
>   printk("fpgadriver_read  \n");
>   return 0;
> }
> 
> I have the wake_up_interruptible(&reaq) in fpgadriver_bh_handler(). My
> problem is that fpgadriver_irq_save_handler() is never called as if
> there is no interruption.
> Is there something else to modify to validate the interruption ? Is
> SIU_IRQ7 the right value for my interruption ? What have i to check ?
> 
> Thanks for your reply.
> 
> Sophie CARAYOL
> 
> 
> 
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded

      reply	other threads:[~2005-06-15 10:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-15  8:35 MPC885 interruptions : help ! scarayol
2005-06-15 10:26 ` Alex Zeffertt [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=20050615112656.562f8209.ajz@cambridgebroadband.com \
    --to=ajz@cambridgebroadband.com \
    --cc=linuxppc-embedded@ozlabs.org \
    --cc=scarayol@assystembrime.com \
    /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