<?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: Need support to Set the primary Display on IMX8QM in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Need-support-to-Set-the-primary-Display-on-IMX8QM/m-p/1630330#M203930</link>
    <description>&lt;P&gt;This order is decided by the LDB driver probe order. The LDB1 connector should be first and then LDB2 connector.&lt;/P&gt;
&lt;P&gt;You can find the display hal code in&amp;nbsp;nxp-opensource/imx/display/display/DisplayManager.cpp&lt;/P&gt;
&lt;P&gt;The code will set the first connector as&amp;nbsp;primary device(using &lt;STRONG&gt;setPrimaryDisplay&lt;/STRONG&gt;), you can judge the value of&amp;nbsp; &lt;STRONG&gt;*id &lt;/STRONG&gt;to decide which device should be&amp;nbsp;primary.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;for (int i = 0; i &amp;lt; res-&amp;gt;count_connectors; i++) {
        display = mKmsDisplays[*id];

        if (display-&amp;gt;setDrm(drmFd, res-&amp;gt;connectors[i]) != 0) {
            continue;
        }

        display-&amp;gt;setDisplayLimitation(tileHwLimit);
        display-&amp;gt;readType();
        display-&amp;gt;readConnection();
        // primary display allow not connected.
        if (!display-&amp;gt;connected() &amp;amp;&amp;amp; (*foundPrimary || !main)) {
            (*id)++;
            continue;
        }

        if (display-&amp;gt;openKms() != 0) {
            display-&amp;gt;closeKms();
            (*id)++;
            continue;
        }

        // primary display is fixed by name.
        if (!*foundPrimary &amp;amp;&amp;amp; main) {
            ALOGI("%s set %d as primary display", __func__, (*id));
            *foundPrimary = true;
            setPrimaryDisplay(*id);
        }&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 10 Apr 2023 06:25:34 GMT</pubDate>
    <dc:creator>Zhiming_Liu</dc:creator>
    <dc:date>2023-04-10T06:25:34Z</dc:date>
    <item>
      <title>Need support to Set the primary Display on IMX8QM</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Need-support-to-Set-the-primary-Display-on-IMX8QM/m-p/1630134#M203915</link>
      <description>&lt;P&gt;Hello Support Portal,&lt;/P&gt;&lt;P&gt;SOC: IMX8QM&lt;/P&gt;&lt;P&gt;We have connected the Dual Channel display on the LDB2 node and the Single Channel display on the LDB1 node.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Dual Channel Display: 1920X720&lt;/P&gt;&lt;P&gt;Single Channel Display: 1280X800&lt;/P&gt;&lt;P&gt;The android is detecting both the display&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PunitTeksun_0-1681038419466.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/218425iDCB26EEBA9B40C79/image-size/medium?v=v2&amp;amp;px=400" role="button" title="PunitTeksun_0-1681038419466.png" alt="PunitTeksun_0-1681038419466.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Currently Android considers Single channel 1280X800 Display as a primary display and a Dual channel&amp;nbsp; 1920X720 display as a secondary display.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What we want :&lt;/STRONG&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Dual channel display - &lt;STRONG&gt;primary&lt;/STRONG&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Single channel display - secondary&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have tried following things&lt;/P&gt;&lt;P&gt;1) First we connect the Dual channel display and then after some time we connect the single-channel display but still, the single-channel display is considered as a primary display&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; If we disable the single-channel display node from the device tree then the dual-channel display is considered the primary display.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 09 Apr 2023 11:18:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Need-support-to-Set-the-primary-Display-on-IMX8QM/m-p/1630134#M203915</guid>
      <dc:creator>PunitTeksun</dc:creator>
      <dc:date>2023-04-09T11:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: Need support to Set the primary Display on IMX8QM</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Need-support-to-Set-the-primary-Display-on-IMX8QM/m-p/1630330#M203930</link>
      <description>&lt;P&gt;This order is decided by the LDB driver probe order. The LDB1 connector should be first and then LDB2 connector.&lt;/P&gt;
&lt;P&gt;You can find the display hal code in&amp;nbsp;nxp-opensource/imx/display/display/DisplayManager.cpp&lt;/P&gt;
&lt;P&gt;The code will set the first connector as&amp;nbsp;primary device(using &lt;STRONG&gt;setPrimaryDisplay&lt;/STRONG&gt;), you can judge the value of&amp;nbsp; &lt;STRONG&gt;*id &lt;/STRONG&gt;to decide which device should be&amp;nbsp;primary.&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;for (int i = 0; i &amp;lt; res-&amp;gt;count_connectors; i++) {
        display = mKmsDisplays[*id];

        if (display-&amp;gt;setDrm(drmFd, res-&amp;gt;connectors[i]) != 0) {
            continue;
        }

        display-&amp;gt;setDisplayLimitation(tileHwLimit);
        display-&amp;gt;readType();
        display-&amp;gt;readConnection();
        // primary display allow not connected.
        if (!display-&amp;gt;connected() &amp;amp;&amp;amp; (*foundPrimary || !main)) {
            (*id)++;
            continue;
        }

        if (display-&amp;gt;openKms() != 0) {
            display-&amp;gt;closeKms();
            (*id)++;
            continue;
        }

        // primary display is fixed by name.
        if (!*foundPrimary &amp;amp;&amp;amp; main) {
            ALOGI("%s set %d as primary display", __func__, (*id));
            *foundPrimary = true;
            setPrimaryDisplay(*id);
        }&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 Apr 2023 06:25:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Need-support-to-Set-the-primary-Display-on-IMX8QM/m-p/1630330#M203930</guid>
      <dc:creator>Zhiming_Liu</dc:creator>
      <dc:date>2023-04-10T06:25:34Z</dc:date>
    </item>
  </channel>
</rss>

