<?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>topic Re: How to turn on device by gpio in kernel space? in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764025#M118693</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If your wanting to enable gpio at startup then you could do it from uboot hence before the kernel is launched.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A regulator isn't the ideal way to achieve this as the regulator should represent a physical regulator on the board (in your case there isn't one). However it can be used as a workaround to enable the gpio pin.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Normally in these types of scenarios there would a custom device tree entry (ie gps) in the dts with 2 properties, one to configure the power gpio pin and the other to enable/disable the power. The custom device tree entry would map to a custom kernel driver (you need to write) that would toggle the pin. However can you imagine this is more work than using a pseudo regulator.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 23 Feb 2018 09:07:05 GMT</pubDate>
    <dc:creator>mtx512</dc:creator>
    <dc:date>2018-02-23T09:07:05Z</dc:date>
    <item>
      <title>How to turn on device by gpio in kernel space?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764022#M118690</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I connected a GPS module to i.MX6 as the picture below. The power of gps module is controlled by a gpio of i.MX6. My question is "How to power on gps module in kernel space by pulling down i.MX6 gpio?" Which driver should i used? Please advise!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/18477iA53C7364C1105FE6/image-size/large?v=v2&amp;amp;px=999" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Feb 2018 07:58:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764022#M118690</guid>
      <dc:creator>trongthinh</dc:creator>
      <dc:date>2018-02-21T07:58:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to turn on device by gpio in kernel space?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764023#M118691</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Thinh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please take a look to the following thread &lt;A href="https://community.nxp.com/thread/458270"&gt;Issue with configuring GPIO as an interrupt - i.MX6Q&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here I share a .c file and a .dts of a kernel module that handles a GPIO interrupt.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Carlos&lt;BR /&gt;NXP Technical Support&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Feb 2018 21:21:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764023#M118691</guid>
      <dc:creator>Carlos_Musich</dc:creator>
      <dc:date>2018-02-22T21:21:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to turn on device by gpio in kernel space?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764024#M118692</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank for replying me! maybe my question is unclear or you misunderstand my idea. I would like to explain it more clearly now:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The power supply (+5V) of GPS module is controled by a GPIO of i.MX6.&amp;nbsp; If i.MX6 pin has logic 0, this means GPS module has +5V (Module is turned on). If i.MX6 pis has logic 1, this means module is turned off. I would like to power on GPS module on boot up in kernel space (default GPS module is off), so I think there should be a regulator driver.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have read/studied&amp;nbsp;&lt;A href="https://elixir.bootlin.com/linux/v4.0/source/Documentation/devicetree/bindings/regulator/fixed-regulator.txt"&gt;regulator-fixed&lt;/A&gt; driver, is it the exact driver that i need in this situations?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Feb 2018 01:32:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764024#M118692</guid>
      <dc:creator>trongthinh</dc:creator>
      <dc:date>2018-02-23T01:32:12Z</dc:date>
    </item>
    <item>
      <title>Re: How to turn on device by gpio in kernel space?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764025#M118693</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If your wanting to enable gpio at startup then you could do it from uboot hence before the kernel is launched.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A regulator isn't the ideal way to achieve this as the regulator should represent a physical regulator on the board (in your case there isn't one). However it can be used as a workaround to enable the gpio pin.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Normally in these types of scenarios there would a custom device tree entry (ie gps) in the dts with 2 properties, one to configure the power gpio pin and the other to enable/disable the power. The custom device tree entry would map to a custom kernel driver (you need to write) that would toggle the pin. However can you imagine this is more work than using a pseudo regulator.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Feb 2018 09:07:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-turn-on-device-by-gpio-in-kernel-space/m-p/764025#M118693</guid>
      <dc:creator>mtx512</dc:creator>
      <dc:date>2018-02-23T09:07:05Z</dc:date>
    </item>
  </channel>
</rss>

