<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>i.MX Processorsのトピックgpio-sim as a GPIO Interrupt for PMIC driver</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/gpio-sim-as-a-GPIO-Interrupt-for-PMIC-driver/m-p/1972220#M229553</link>
    <description>&lt;P&gt;&lt;SPAN&gt;Hi everyone,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm currently working on getting a custom i.MX93 board up and running, and I'm facing an issue with the PMIC (the NXP PCA9451A). The problem is that the PMIC requires a GPIO interrupt to load its driver, but our board does not have any free GPIOs available.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;To solve this, we came up with the idea of using a "fake" GPIO through gpio-sim or gpio-mockup, so that we can get the PMIC up and running for now. In a future revision of the board, we plan to replace this mockup GPIO with a real one. However, I'm struggling to get the PMIC driver to load, regardless of how I configure the gpio-sim node.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I've seen a linux patch&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;from 2022 "[PATCH v2 0/3] allow gpio simulator be used as interrupt controller ", which seems to be attempting the same thing I'm trying to do. We're currently using Linux version 6.6.28-lf-6.6.y-lf-6.6.y-g81ea508ca4b7-dirty.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I've also made sure to add the necessary kernel configuration options, including:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_GPIO_SIM=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_GPIOLIB=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_IRQ_SIM=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;SPAN&gt;Despite this, the PMIC driver does not load. Below is how I'd like the PMIC node to look in the device tree, using gpio-sim as the interrupt parent:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;amp;lpi2c1 {
    #address-cells = &amp;lt;1&amp;gt;;
    #size-cells = &amp;lt;0&amp;gt;;
    clock-frequency = &amp;lt;400000&amp;gt;;
    pinctrl-names = "default", "sleep";
    pinctrl-0 = &amp;lt;&amp;amp;pinctrl_lpi2c1&amp;gt;;
    pinctrl-1 = &amp;lt;&amp;amp;pinctrl_lpi2c1&amp;gt;;
    status = "okay";

    pmic@25 {
        compatible = "nxp,pca9451a";
        reg = &amp;lt;0x25&amp;gt;;
        interrupt-parent = &amp;lt;&amp;amp;gpio_sim&amp;gt;;
        interrupts = &amp;lt;0 IRQ_TYPE_EDGE_FALLING&amp;gt;;&lt;/LI-CODE&gt;&lt;P&gt;&lt;SPAN&gt;Has anyone successfully used gpio-sim in a similar scenario, or can anyone suggest how the gpio-sim node should be configured to make this work?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any help would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Elia&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 11 Oct 2024 14:26:26 GMT</pubDate>
    <dc:creator>elFunko</dc:creator>
    <dc:date>2024-10-11T14:26:26Z</dc:date>
    <item>
      <title>gpio-sim as a GPIO Interrupt for PMIC driver</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/gpio-sim-as-a-GPIO-Interrupt-for-PMIC-driver/m-p/1972220#M229553</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi everyone,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm currently working on getting a custom i.MX93 board up and running, and I'm facing an issue with the PMIC (the NXP PCA9451A). The problem is that the PMIC requires a GPIO interrupt to load its driver, but our board does not have any free GPIOs available.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;To solve this, we came up with the idea of using a "fake" GPIO through gpio-sim or gpio-mockup, so that we can get the PMIC up and running for now. In a future revision of the board, we plan to replace this mockup GPIO with a real one. However, I'm struggling to get the PMIC driver to load, regardless of how I configure the gpio-sim node.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I've seen a linux patch&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;from 2022 "[PATCH v2 0/3] allow gpio simulator be used as interrupt controller ", which seems to be attempting the same thing I'm trying to do. We're currently using Linux version 6.6.28-lf-6.6.y-lf-6.6.y-g81ea508ca4b7-dirty.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I've also made sure to add the necessary kernel configuration options, including:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_GPIO_SIM=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_GPIOLIB=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;SPAN&gt;CONFIG_IRQ_SIM=y&lt;/SPAN&gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;SPAN&gt;Despite this, the PMIC driver does not load. Below is how I'd like the PMIC node to look in the device tree, using gpio-sim as the interrupt parent:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;amp;lpi2c1 {
    #address-cells = &amp;lt;1&amp;gt;;
    #size-cells = &amp;lt;0&amp;gt;;
    clock-frequency = &amp;lt;400000&amp;gt;;
    pinctrl-names = "default", "sleep";
    pinctrl-0 = &amp;lt;&amp;amp;pinctrl_lpi2c1&amp;gt;;
    pinctrl-1 = &amp;lt;&amp;amp;pinctrl_lpi2c1&amp;gt;;
    status = "okay";

    pmic@25 {
        compatible = "nxp,pca9451a";
        reg = &amp;lt;0x25&amp;gt;;
        interrupt-parent = &amp;lt;&amp;amp;gpio_sim&amp;gt;;
        interrupts = &amp;lt;0 IRQ_TYPE_EDGE_FALLING&amp;gt;;&lt;/LI-CODE&gt;&lt;P&gt;&lt;SPAN&gt;Has anyone successfully used gpio-sim in a similar scenario, or can anyone suggest how the gpio-sim node should be configured to make this work?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any help would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Elia&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2024 14:26:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/gpio-sim-as-a-GPIO-Interrupt-for-PMIC-driver/m-p/1972220#M229553</guid>
      <dc:creator>elFunko</dc:creator>
      <dc:date>2024-10-11T14:26:26Z</dc:date>
    </item>
    <item>
      <title>Re: gpio-sim as a GPIO Interrupt for PMIC driver</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/gpio-sim-as-a-GPIO-Interrupt-for-PMIC-driver/m-p/1993513#M230804</link>
      <description>&lt;P&gt;To anyone having the same question I got it to work:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;/ {
	gpio_sim {
		compatible = "gpio-simulator";

		bank0: bank0 {
			gpio-controller;
			#gpio-cells = &amp;lt;1&amp;gt;;
			ngpios = &amp;lt;1&amp;gt;;

			interrupt-controller;
			#interrupt-cells = &amp;lt;1&amp;gt;;
		};
	};
};&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Nov 2024 08:52:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/gpio-sim-as-a-GPIO-Interrupt-for-PMIC-driver/m-p/1993513#M230804</guid>
      <dc:creator>elFunko</dc:creator>
      <dc:date>2024-11-13T08:52:46Z</dc:date>
    </item>
  </channel>
</rss>

