WIP: info: Read MDADM arrays as their size, not the size of their underlying drives

Closed Iain Lane requested to merge wip/info-udisks2-mdadm into master

These are exposed to the user as the size of the array. If we find such an array, read its size, record the drives and don't count their sizes individually.

This is slightly fiddly for a couple of reasons:

  • There's no API exposed in udisks2 to get directly from the UDisksMDRaid object to the underlying UDisksDrives, so we have to construct proxies manually.
  • We might see the drives first, before we encounter the RAID array. So we keep a reference to the UDisks objects when counting disk sizes and then use this to later on subtract the size if we later find out a drive is actually part of an array.

This builds on !387 (merged). For me the total is quite wrong because it counts my RAID drives individually rather than through the array. That one should be reviewed first, and then ideally this MR as followup.

Merge request reports