lkml.org 
[lkml]   [2012]   [Mar]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V2 2/2] gpio: add STA2X11 GPIO block
Thank you Grant for your comments. Agreed with all of them.

>> + /* 384 was used in previous code: be compatible for other drivers */
>> + err = irq_alloc_descs(-1, 384, GSTA_NR_GPIO, NUMA_NO_NODE);
>
> That's a lot of irqs. Will they all be used?

384 is the starting point, isn't it? The number is 128. One per gpio pin.
We have change-detect for mmc and other stuff that live in high gpio
numbers.

> How do other drivers determine which irq number to use (is it
> statically assigned, or is there a dynamic mechanism)? If only a
> portion are used, then the irq_domain linear mapping would be a win
> here.

The code I received uses static numbers. The chip is the main chipset
in the typical use case, so only one is there even if it is PCI. I
also have a PCIe card to use it as slave device, and I'm careful to
allow several of them, even if it's not the main use case. Maybe here
I fell short. I'm reposting soon, with a full change log.

This "compatibility" is something I need to run the boards with
existing code for the parts that are not cleaned up for upstream, yet.

/alessandro


\
 
 \ /
  Last update: 2012-03-02 11:03    [W:0.851 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site