Cleanup _convert_block_devices

_convert_block_devices was instantiating 2 objects for every 1
returned due to the _is_transformable test. This change simplifies the
code by removing the nested function, and at the same time does the
conversion in a single pass, which is more efficient.

Change-Id: Id6b583a1c08d684fcff073dd0289be8e3919ba0a
Merge "Cleanup _convert_block_devices"