<div>Hi,<br><br>I am also trying to use Xilinx GPIO driver on my board but I encounter some problems. I thought they will be resolved with this information but it doesn't.<br><br>I use GPIO driver as built-in but during kernel boot but I don't see log about it contrary to Xemac driver for instance. First I wanted to create my gpio driver normally without using Xilinx one, with ioremap and writel/readl but I didn't write anything in the register, I don't know why. Then I tried to use Xilinx GPIO driver but I don't know why I don't hit xgpio_probe, xgpio_init returns 0 so it's OK.<br>
<br>Do you have any idea ?<br><br>Thanks<br><br>Ludovic Desroches<br> </div><blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;" class="gmail_quote"><pre>arch/ppc/syslib/virtex_devices.c:<br>
<br>><i> // 0 is LEDS_4BIT, 1 is LEDS_POSITIONS, 2 is PUSH_BUTTONS_POSITION<br></i>><i> #define XPAR_GPIO(num) { \<br></i>><i> .name = "xilinx_gpio", \<br></i>><i> .id = num, \<br></i>><i> .num_resources = 2, \<br>
</i>That was a 2.<br>If anybody wants to make a patch out of those few lines of code, I couldn't <br>figure out how to do this with git... But I will use a more general GPIO <br>approach as soon as I can put my hands on our custom card.<br>
<br>><i> .resource = (struct resource[]) { \<br></i>><i> { \<br></i>><i> .start = XPAR_GPIO_##num##_BASEADDR, \<br></i>><i> .end = XPAR_GPIO_##num##_HIGHADDR, \<br></i>><i> .flags = IORESOURCE_MEM, \<br>
</i>><i> }, \<br></i>><i> { \<br></i>><i> .start = XPAR_INTC_0_GPIO_##num##_VEC_ID, \<br></i>><i> .flags = IORESOURCE_IRQ, \<br></i>><i> }, \<br></i>><i> }, \<br>
</i>><i> }<br></i>><i> [...]<br></i>><i> /* GPIO instances */<br></i>><i> #if defined(XPAR_GPIO_0_BASEADDR)<br></i>><i> XPAR_GPIO(0),<br></i>><i> #endif<br></i>><i> #if defined(XPAR_GPIO_1_BASEADDR)<br>
</i>><i> XPAR_GPIO(1),<br></i>><i> #endif<br></i>><i> #if defined(XPAR_GPIO_2_BASEADDR)<br></i>><i> XPAR_GPIO(2),<br></i>><i> #endif<br></i></pre></blockquote><br clear="all"><br>