public inbox for linux-i2c@vger.kernel.org
 help / color / mirror / Atom feed
From: Marius Hoch <mail@mariushoch.de>
To: Rudolf Marek <r.marek@assembler.cz>, Jean Delvare <jdelvare@suse.de>
Cc: linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/2] i2c: i801: Force no IRQ for Dell Latitude E7450
Date: Sun, 18 Jun 2023 14:52:50 +0200	[thread overview]
Message-ID: <9d07309f-9596-2be0-97ab-2bb9ee237c11@mariushoch.de> (raw)
In-Reply-To: <ae93843f-7ab0-9d10-cf93-261f986962a5@assembler.cz>

Hi Rudolf,

thanks for the reply.

On 04/06/2023 22:41, Rudolf Marek wrote:
> Hi Jean,
>
> Dne 04. 06. 23 v 16:01 Jean Delvare napsal(a):
>> I admit I don't know. I'm not familiar with how GSI numbers relate to
>> IRQ numbers. I think I understand that GSI numbers are an ACPI thing,
>> and the ACPI layer is responsible for mapping these to actual IRQ
>> numbers? Is there a GSI-to-IRQ table available somewhere as part of the
>> ACPI tables? If so, it would be interesting to disassemble the ACPI
>> tables on your system and check what this looks like for you.
>
> You need to check _PRT method of PCI0 device in APIC mode.
> This will tell you to what GSI (APIC/pin) it goes.
> To check you need to have a look to the DSDT table and decompile
> it. You can obtain it by running acpidump > tables.txt and the 
> acpixtract -a tables.txt
> and finally running iasl -d dsdt.asl.
>
> Then, because the SMBUS lives on bus0, you just need to check _PRT method
> under PCI0 device for the entry of 001fffff (INT C).
> If this entry exists it will tell you where is it connected.
The PCI0 device's _PRT, when PICM is true, returns AR00. That contains:
             Package (0x04)
             {
                 0x001FFFFF,
                 0x02,
                 Zero,
                 0x12
             },

So according to this IRQ (=GSI?) 18 should be used (which, as mentioned 
earlier is also used for the freefall device). (In acpi_pci_irq_enable) 
acpi_register_gsi fails for this (with gsi=18) and afterwards dev->irq 
is at 255 (which might just be an initial value? dev->irq is only set in 
acpi_pci_irq_enable afterwards).

> I assume this has no entry and then as a last chance Linux tries the 
> PCI IRQ entry
> in the configuration space gets queried. And this has 0xff which is
> telling no IRQ connected.
>
> The southbridge has a IRQ routing configuration register which can be 
> used to verify
> if this is routed anywhere or really left "unconnected". This is 
> usually in the the RCBA base + something
> register. Have a look to "D31IP" register:
>
> SMBus Pin (SMIP) — R/W. Indicates which pin the SMBus controller 
> drives as its
> interrupt. bits 15:12
>
> If there is 0, it is not routed anywhere. Also you need to check 
> "D31IR" where the PIN C is going:
>
> Interrupt C Pin Route (ICR) — R/W. Indicates which physical pin on the 
> PCH is
> connected to the INTC# pin reported for device 31 functions.
>
> The PIRQA corresponds to the PIN 16 of IOAPIC etc.
>
> If you need more info on that feel free to contact me. I can try to help.
I skipped these steps (after identifying the _PRT entry) as it seems to 
me that we have a ACPI entry here (it's just not functional), thus this 
information would presumably be of no help.

Further help in debugging this would be much appreciated. In order to 
further see why acpi_register_gsi failed, I also got the irqdomain debug 
output and this also didn't help me (except that it doesn't register a 
domain for our SMBus, like "irq: Added domain IR-PCI-MSI-0000:00:XX").
>
>
> Thanks,
> Rudolf
>


  reply	other threads:[~2023-06-18 12:53 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-14 10:36 [PATCH 0/2] i2c: i801: Force no IRQ for Dell Latitude E7450 Marius Hoch
2023-05-14 10:36 ` [PATCH 1/2] " Marius Hoch
2023-05-14 12:06   ` kernel test robot
2023-05-14 12:06   ` kernel test robot
2023-06-04 14:38   ` Jean Delvare
2023-06-18 13:08     ` Marius Hoch
2023-05-14 10:36 ` [PATCH 2/2] i2c: i801: Force no IRQ for further Dell Latitudes Marius Hoch
2023-05-23 18:03 ` [PATCH 0/2] i2c: i801: Force no IRQ for Dell Latitude E7450 Jean Delvare
2023-06-03  9:24   ` Marius Hoch
2023-06-04 14:01     ` Jean Delvare
2023-06-04 14:31       ` Jean Delvare
2023-06-04 20:41       ` Rudolf Marek
2023-06-18 12:52         ` Marius Hoch [this message]
2023-06-18 13:42       ` Marius Hoch
2023-06-19 15:19         ` Jean Delvare
2023-07-19 19:27         ` Pali Rohár
2023-10-29 17:17 ` Wolfram Sang

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=9d07309f-9596-2be0-97ab-2bb9ee237c11@mariushoch.de \
    --to=mail@mariushoch.de \
    --cc=jdelvare@suse.de \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=r.marek@assembler.cz \
    /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