<?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: GPS Service was kickout while selinux is enabled in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857645#M131045</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Benson Wu,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would recommend looking for insight on the Google Developer forums as permissions in newer Android versions are becoming more intricate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a couple of threads in our communities regarding Selinux but not for Oreo, like the one below. So a dedicated Android forums may provide better information.&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/message/1065246?commentID=1065246#comment-1065246"&gt;https://community.nxp.com/message/1065246?commentID=1065246#comment-1065246&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My apologies for the inconvenience!&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Jan 2019 21:45:19 GMT</pubDate>
    <dc:creator>gusarambula</dc:creator>
    <dc:date>2019-01-17T21:45:19Z</dc:date>
    <item>
      <title>GPS Service was kickout while selinux is enabled</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857644#M131044</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am developing Android platform (Oreo) with imx6dl and imx6Q&lt;/P&gt;&lt;P&gt;Recently, I just add ublox GNSS driver (v3.5) from ublox on my platform and met a problem related to Selinux.&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;If OS was built with Selinux is enabled(enforced) , ublox driver tried to bind but failed continuously(kicked repeatedly) and the message is as below:&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/****************************************************************************/&lt;/P&gt;&lt;P&gt;init: starting service 'ubx-gnss'...&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "running") OK!&lt;BR /&gt;init: property_set("ro.boottime.ubx-gnss", "964917483781") failed: property already set&lt;BR /&gt;&lt;STRONG&gt;init: Service 'ubx-gnss' (pid 1515) killed by signal 6&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;init: Sending signal 9 to service 'ubx-gnss' (pid 1515) process group...&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;init: Successfully killed process cgroup uid 0 pid 1515 in 0ms&lt;/STRONG&gt;&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "restarting") OK!&lt;BR /&gt;init: Untracked pid 1518 exited with status 0&lt;BR /&gt;130|sabresd_6dq:/ # starinit: starting service 'ubx-gnss'... &lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "running") OK!&lt;BR /&gt;init: property_set("ro.boottime.ubx-gnss", "969921627782") failed: property already set&lt;BR /&gt;init: Service 'ubx-gnss' (pid 1523) killed by signal 6&lt;BR /&gt;init: Sending signal 9 to service 'ubx-gnss' (pid 1523) process group...&lt;BR /&gt;init: Successfully killed process cgroup uid 0 pid 1523 in 0ms&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "restarting") OK!&lt;BR /&gt;init: Untracked pid 1526 killed by signal 13&lt;/P&gt;&lt;P&gt;................&lt;/P&gt;&lt;P&gt;/***************************************************************/&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;the result of getprop is as below:&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;[init.svc.ubx-gnss]: [restarting]&lt;/P&gt;&lt;P&gt;[ro.boottime.ubx-gnss]: [10671214334]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;However&lt;/STRONG&gt;, if I built OS with disable Selinux( add androidboot.selinux=permissive in bootarg ) then ublox driver can be attached successfully. and NMEA message can come out&amp;nbsp;&lt;/P&gt;&lt;P&gt;Logs:&lt;/P&gt;&lt;P&gt;/**************************************************************************/&lt;/P&gt;&lt;P&gt;init: starting service 'ubx-gnss'...&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "running") OK!&lt;BR /&gt;init: property_set("ro.boottime.ubx-gnss", "2643702243981") failed: property already set&lt;/P&gt;&lt;P&gt;/*************************************************************************/&lt;/P&gt;&lt;P&gt;getprop:&lt;/P&gt;&lt;P&gt;[init.svc.ubx-gnss]: [running]&lt;BR /&gt;[ro.boottime.ubx-gnss]: [10671214334]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is no related AVC message . My GPS port is i2c-0 .&lt;/P&gt;&lt;P&gt;/*********************************************************/&lt;/P&gt;&lt;P&gt;# dmesg | grep avc &lt;BR /&gt;[ 11.278137] type=1400 audit(15.880:4): avc: granted { read } for pid=1 comm="init" name="ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.640669] type=1400 audit(15.880:4): avc: granted { read } for pid=1 comm="init" name="ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.679859] type=1400 audit(15.880:5): avc: granted { read open } for pid=1 comm="init" path="/dev/ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.696924] type=1400 audit(15.880:5): avc: granted { read open } for pid=1 comm="init" path="/dev/ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.714734] type=1400 audit(16.000:6): avc: granted { read } for pid=277 comm="init" name="ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.732394] type=1400 audit(16.000:6): avc: granted { read } for pid=277 comm="init" name="ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 15.748371] type=1400 audit(16.000:7): avc: granted { read open } for pid=277 comm="init" path="/dev/ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;BR /&gt;[ 1020.549032] type=1400 audit(16.000:7): avc: granted { read open } for pid=277 comm="init" path="/dev/ttymxc0" dev="tmpfs" ino=9581 scontext=u:r:init:s0 tcontext=u:object_r:tty_device:s0 tclass=chr_file&lt;/P&gt;&lt;P&gt;/**************************************************************/&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Further information in later experiment:&lt;/P&gt;&lt;P&gt;I try to build OS image with&amp;nbsp;&lt;SPAN&gt;disable Selinux but I purposely enter the incorrect path for&amp;nbsp;library , then I got the &lt;STRONG&gt;SAME&amp;nbsp;&lt;/STRONG&gt;error messages as the OS image with enabled Selinux.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;/****************************************************************************/&lt;/P&gt;&lt;P&gt;init: starting service 'ubx-gnss'...&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "running") OK!&lt;BR /&gt;init: property_set("ro.boottime.ubx-gnss", "964917483781") failed: property already set&lt;BR /&gt;&lt;STRONG&gt;init: Service 'ubx-gnss' (pid 1515) killed by signal 6&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;init: Sending signal 9 to service 'ubx-gnss' (pid 1515) process group...&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;init: Successfully killed process cgroup uid 0 pid 1515 in 0ms&lt;/STRONG&gt;&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "restarting") OK!&lt;BR /&gt;init: Untracked pid 1518 exited with status 0&lt;BR /&gt;130|sabresd_6dq:/ # starinit: starting service 'ubx-gnss'...&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "running") OK!&lt;BR /&gt;init: property_set("ro.boottime.ubx-gnss", "969921627782") failed: property already set&lt;BR /&gt;init: Service 'ubx-gnss' (pid 1523) killed by signal 6&lt;BR /&gt;init: Sending signal 9 to service 'ubx-gnss' (pid 1523) process group...&lt;BR /&gt;init: Successfully killed process cgroup uid 0 pid 1523 in 0ms&lt;BR /&gt;init: property_set("init.svc.ubx-gnss", "restarting") OK!&lt;BR /&gt;init: Untracked pid 1526 killed by signal 13&lt;/P&gt;&lt;P&gt;................&lt;/P&gt;&lt;P&gt;/***************************************************************/&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;It seemed that I have permission issue to access shared library when Selinux is enabled.&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt; &amp;nbsp;Please give me some help if possible. Thank you!&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jan 2019 01:29:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857644#M131044</guid>
      <dc:creator>bensonwu</dc:creator>
      <dc:date>2019-01-08T01:29:51Z</dc:date>
    </item>
    <item>
      <title>Re: GPS Service was kickout while selinux is enabled</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857645#M131045</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Benson Wu,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would recommend looking for insight on the Google Developer forums as permissions in newer Android versions are becoming more intricate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a couple of threads in our communities regarding Selinux but not for Oreo, like the one below. So a dedicated Android forums may provide better information.&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/message/1065246?commentID=1065246#comment-1065246"&gt;https://community.nxp.com/message/1065246?commentID=1065246#comment-1065246&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My apologies for the inconvenience!&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Jan 2019 21:45:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857645#M131045</guid>
      <dc:creator>gusarambula</dc:creator>
      <dc:date>2019-01-17T21:45:19Z</dc:date>
    </item>
    <item>
      <title>Re: GPS Service was kickout while selinux is enabled</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857646#M131046</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I will suggest to you that disabled your service first, and start it after boot_completed, just as follows, the system will give you enough message about permission, and then you just add the permission what it needs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;service ubx-gnss&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;EM&gt; disabled&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;on property:sys.boot_completed=1&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;bootchart stop&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;start ubx-gnss&lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Jan 2019 09:08:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/GPS-Service-was-kickout-while-selinux-is-enabled/m-p/857646#M131046</guid>
      <dc:creator>luwinbo</dc:creator>
      <dc:date>2019-01-18T09:08:46Z</dc:date>
    </item>
  </channel>
</rss>

