[Bug 1814118] Re: Make RPi.GPIO work on arm64

Mathew Hodson mathew.hodson at gmail.com
Fri Apr 26 01:22:29 UTC 2019


** Changed in: rpi.gpio (Ubuntu)
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1814118

Title:
  Make RPi.GPIO work on arm64

Status in rpi.gpio package in Ubuntu:
  Fix Released
Status in rpi.gpio source package in Bionic:
  New
Status in rpi.gpio source package in Cosmic:
  New

Bug description:
  [Impact]

   * RPi.GPIO currently does not work under arm64 kernels, simply due to hardware revision detection being slightly different.
   * The patched version operates as expected under both armhf and arm64 kernels by querying /proc/device-tree/system/linux,revision (a file that exists on modern armhf and arm64 kernels), falling back to /proc/cpuinfo (the former detection method, primarily to continue supporting any older armhf kernels).
   * This will also bump the version from 0.6.3 to 0.6.5 on bionic/cosmic. This fixes several nasty bugs around PWM handling and event detection. These issues didn't affect short-term experimentation with the library, but do affect long-running deployments (memory leak in PWM allocation, and a race-condition in setting up pin event detection).

  [Test Case]

   * On an arm64 kernel:
   * Install present version of python3-rpi.gpio (0.6.3-1ubuntu4)
   * Under python3 "from RPi import GPIO"
   * Present version returns RuntimeError: This module can only be run on a Raspberry Pi
   * Upgrade to proposed version (0.6.5-1ubuntu1)
   * Under python3 "from RPi import GPIO"
   * This should succeed
   * Run test cases under test/ (note: external wiring/components required; check source header for requirements)
   * Repeat procedure with armhf kernel to ensure no regression

  [Regression Potential]

   * On armhf kernels: low; the existing detection pathway is maintained for ancient kernels lacking /proc/device-tree/system/linux but modern armhf kernels appear to have this file anyway and work with the new detection code. The new version is also operating happily upstream in Raspbian stretch.
   * On arm64 kernels: none; the existing version simply fails to import anyway

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/rpi.gpio/+bug/1814118/+subscriptions



More information about the Ubuntu-sponsors mailing list