am ec86729b: am 7c3749c2: am 6a62cac4: Merge "Further cleanup of the logic in device_init."

* commit 'ec86729bc9397e65aa74d4b8d19c6e85bc17f87e':
  Further cleanup of the logic in device_init.