Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Mar 16 20:22
    hchenji opened #191
  • Mar 08 2021 23:54

    imphil on master

    Add LibreCores badge (compare)

  • Jan 16 2021 02:53
    hchenji commented #189
  • Dec 10 2020 17:53
    hchenji commented #190
  • Dec 10 2020 15:52
    hchenji commented #189
  • Dec 02 2020 19:23
    koenenwmn commented #189
  • Nov 25 2020 23:32
    imphil commented #189
  • Nov 25 2020 23:28
    imphil reopened #189
  • Nov 25 2020 23:28
    imphil commented #189
  • Nov 25 2020 23:28
    imphil closed #189
  • Nov 25 2020 23:28
    imphil commented #189
  • Nov 24 2020 00:01
    hchenji commented #189
  • Nov 20 2020 08:04
    deadspace99 commented #189
  • Nov 09 2020 17:13
    hchenji commented #189
  • Nov 08 2020 10:57
    deadspace99 commented #189
  • Nov 07 2020 11:48
    deadspace99 opened #190
  • Nov 03 2020 18:05
    hchenji opened #189
  • May 16 2020 14:24
    ppenna unassigned #82
  • May 04 2020 22:12

    imphil on master

    README: Fix name of license file (compare)

  • May 04 2020 21:29

    imphil on master

    Update README Make it a bit mo… (compare)

Pedro Henrique Penna
@ppenna
if I use the right IRQ (no. 4)
however, if I build the module using the bad IRQ (no. 3) ir boots fine
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
I see, well, maybe the itnerrupt handler is getting called and then not returning?
Pedro Henrique Penna
@ppenna
however, I'm obviously not able to receive right interrupts
I have put a printf there
*printk
and it nothing is printed on the screen
it's kind, the interrupt handler does not get called
or something...
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
ok, maybe its related to the change you made about the -level setting for the interrupt handler?
Pedro Henrique Penna
@ppenna
I was thinking about spurious interrupts
what do you mean level setting?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
is there any way you can print out the interrupt level before you call register?
Pedro Henrique Penna
@ppenna
I changed nothing
I don't know... how would you normally do that?
I'm registering IRQ 4 as IRQF_SHARED | IRQF_TRIGGER_HIGH;
Pedro Henrique Penna
@ppenna
maybe this is not good
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
it says -level...
Pedro Henrique Penna
@ppenna
so I assume that I'm registering the handler correctly
because
IRQF_SHARED | IRQF_TRIGGER_HIGH;
am I wrong?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
Here is a simple example we have of the ompic
Pedro Henrique Penna
@ppenna
am I registering the interrupt handler wrong?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
        int irq;

        irq = irq_of_parse_and_map(node, 0);
        setup_irq(irq, &ompi_ipi_irqaction);
It looks ok at first glance, but a bit more complicated, I am nost sure you need those flags too i.e. why are you doing 'IRQF_TRIGGER_HIGH'? Is it opposite normal?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
But you dont need to request that IRQ since we are using device tree, you specified 4 in .dts.
Pedro Henrique Penna
@ppenna
I should somehow state when the IRQ is triggered
oh, why not?
sorry, I didn't know that
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
because that is what .dts file is for... it specifies how the IRQs are wired up
Pedro Henrique Penna
@ppenna
when I specify that on DTS then I don't need to request_irq()?
ok
then how I would register the interrupt handler?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
yes, instead the _of api does that for you
Pedro Henrique Penna
@ppenna
setup_irq()?
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
see my example I posted 5 lines above
Pedro Henrique Penna
@ppenna
yes... I see
just to be sure actually
Ghost
@ghost~5910ddcfd73408ce4f5dfa87
Give me a second you have to make a few more changes to make it device tree aware
Pedro Henrique Penna
@ppenna
ok
I also need to informe the device node
how will I get that?
You can look at examples in the linux kernel
i.e.
static const struct of_device_id of_platform_serial_table[] = {
{ .compatible = "ns8250", .data = (void *)PORT_8250, },