Message ID | 57686D67.8010201@codeaurora.org (mailing list archive) |
---|---|
State | New, archived |
Delegated to: | Bjorn Helgaas |
Headers | show |
> Can you try the following and see if it makes any difference? > > > --- a/drivers/acpi/pci_link.c > +++ b/drivers/acpi/pci_link.c > @@ -500,7 +500,7 @@ static int acpi_irq_get_penalty(int irq) > int penalty = 0; > > if (irq < ACPI_MAX_ISA_IRQS) > - penalty += acpi_isa_irq_penalty[irq]; > + return acpi_isa_irq_penalty[irq]; > > /* > * Penalize IRQ used by ACPI SCI. If ACPI SCI pin attributes conflict > @@ -586,6 +586,10 @@ static int acpi_pci_link_allocate(struct acpi_pci_link *link) > acpi_device_bid(link->device)); > return -ENODEV; > } else { > + if (irq < ACPI_MAX_ISA_IRQS) > + acpi_isa_irq_penalty[irq] = acpi_irq_get_penalty(irq) + > + PIRQ_PENALTY_PCI_USING; > + > > > > > Bjorn I tried this on kernel 4.7.0-rc4, but that didn't help. It still tried to grab irq7. Regards, Wim. ----- wim@djo.tudelft.nl ----- -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 6/21/2016 8:47 AM, Wim Osterholt wrote: >> Can you try the following and see if it makes any difference? >> >> >> --- a/drivers/acpi/pci_link.c >> +++ b/drivers/acpi/pci_link.c >> @@ -500,7 +500,7 @@ static int acpi_irq_get_penalty(int irq) >> int penalty = 0; >> >> if (irq < ACPI_MAX_ISA_IRQS) >> - penalty += acpi_isa_irq_penalty[irq]; >> + return acpi_isa_irq_penalty[irq]; >> >> /* >> * Penalize IRQ used by ACPI SCI. If ACPI SCI pin attributes conflict >> @@ -586,6 +586,10 @@ static int acpi_pci_link_allocate(struct acpi_pci_link *link) >> acpi_device_bid(link->device)); >> return -ENODEV; >> } else { >> + if (irq < ACPI_MAX_ISA_IRQS) >> + acpi_isa_irq_penalty[irq] = acpi_irq_get_penalty(irq) + >> + PIRQ_PENALTY_PCI_USING; >> + >> >> >> >>> Bjorn > > > I tried this on kernel 4.7.0-rc4, but that didn't help. It still tried to > grab irq7. > > Thanks, It was a guess with no proof. Let's undo the change above and start adding some print statements to collect data from your system. Can you add this to the end of acpi_irq_get_penalty function and then send the output? pr_info("%s:%d irq = %d penalty = %d\n", __func__, __LINE__, irq, penalty); > Regards, Wim. > > > ----- wim@djo.tudelft.nl ----- > > -- > To unsubscribe from this list: send the line "unsubscribe linux-pci" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >
On Tue, Jun 21, 2016 at 09:40:10AM -0400, Sinan Kaya wrote: > > Thanks, It was a guess with no proof. > > Let's undo the change above and start adding some print statements to collect > data from your system. > > Can you add this to the end of acpi_irq_get_penalty function and then send > the output? > > pr_info("%s:%d irq = %d penalty = %d\n", __func__, __LINE__, irq, > penalty); > This produced some 60 lines extra. Too much to include here. The entire dmesg file is here: http://webserver.djo.tudelft.nl/dmesg474+printpenalty Regards, Wim. ----- wim@djo.tudelft.nl ----- -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 2016-06-21 18:13, Wim Osterholt wrote: > On Tue, Jun 21, 2016 at 09:40:10AM -0400, Sinan Kaya wrote: >> >> Thanks, It was a guess with no proof. >> >> Let's undo the change above and start adding some print statements to >> collect >> data from your system. >> >> Can you add this to the end of acpi_irq_get_penalty function and then >> send >> the output? >> >> pr_info("%s:%d irq = %d penalty = %d\n", __func__, __LINE__, irq, >> penalty); >> > > This produced some 60 lines extra. Too much to include here. > The entire dmesg file is here: > http://webserver.djo.tudelft.nl/dmesg474+printpenalty Thanks, let's go back to 4.6 and add a very similar printf to every single place where the array is modified and also right before the enabled message. I am trying to find a system with similar characteristics for debug > > > Regards, Wim. > > > ----- wim@djo.tudelft.nl ----- > > -- > To unsubscribe from this list: send the line "unsubscribe linux-pci" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, Jun 22, 2016 at 11:54:39PM -0400, okaya@codeaurora.org wrote: > On 2016-06-21 18:13, Wim Osterholt wrote: > >> > >> pr_info("%s:%d irq = %d penalty = %d\n", __func__, __LINE__, irq, > >> penalty); > >> > > > > This produced some 60 lines extra.... > > Thanks, let's go back to 4.6 and add a very similar printf to every > single place where the array is modified and also right before the > enabled message. > I don't get this right. Assuming that you're still talking about the same file, I find a few instances of 'enabled', most of them in if-statements and one where it might be set, so it looks. However, that's already in a printk statement. I don't know about arrays and even less where these are set. Even worse, I don't know what to put in a 'similar' line if you don't mean 'exactly the same'. So please state file and line numbers and the line to be inserted. Groeten, Wim. ----- wim@djo.tudelft.nl ----- -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 6/23/2016 10:12 AM, Wim Osterholt wrote: > On Wed, Jun 22, 2016 at 11:54:39PM -0400, okaya@codeaurora.org wrote: >> On 2016-06-21 18:13, Wim Osterholt wrote: >>>> >>>> pr_info("%s:%d irq = %d penalty = %d\n", __func__, __LINE__, irq, >>>> penalty); >>>> >>> >>> This produced some 60 lines extra.... >> >> Thanks, let's go back to 4.6 and add a very similar printf to every >> single place where the array is modified and also right before the >> enabled message. >> > > I don't get this right. > Assuming that you're still talking about the same file, I find a few > instances of 'enabled', most of them in if-statements and one where it might > be set, so it looks. However, that's already in a printk statement. > I don't know about arrays and even less where these are set. Even worse, I > don't know what to put in a 'similar' line if you don't mean 'exactly the > same'. > So please state file and line numbers and the line to be inserted. > Sure, let me get a patch for you. I was hoping to do it yesterday. I ran out of time. I typed the message from my phone. > > > Groeten, Wim. > > > ----- wim@djo.tudelft.nl ----- >
--- a/drivers/acpi/pci_link.c +++ b/drivers/acpi/pci_link.c @@ -500,7 +500,7 @@ static int acpi_irq_get_penalty(int irq) int penalty = 0; if (irq < ACPI_MAX_ISA_IRQS) - penalty += acpi_isa_irq_penalty[irq]; + return acpi_isa_irq_penalty[irq]; /* * Penalize IRQ used by ACPI SCI. If ACPI SCI pin attributes conflict @@ -586,6 +586,10 @@ static int acpi_pci_link_allocate(struct acpi_pci_link *link) acpi_device_bid(link->device)); return -ENODEV; } else { + if (irq < ACPI_MAX_ISA_IRQS) + acpi_isa_irq_penalty[irq] = acpi_irq_get_penalty(irq) + + PIRQ_PENALTY_PCI_USING; +