src/config_file: do not attempt to mount an already mounted slot
src/config_file: do not attempt to mount an already mounted slot

So far, when loading the slot status file, we unconditionally attempt to
mount the slot to the default RAUC mount path, read the content and
remount it.
This basically works for most cases, as also if the slot is already
mounted (because it is the root slot, for example), a further mount will
implicitly only create a bind mount in the system.

However, there are sever cases where this will fail. A common example
is when the rootfs slot we currently run from is mounted readonly.
Then an attempt to (bind)mount it (rw) in RAUC will result in an error
like:

| mount: /dev/sda4 is already mounted or /run/rauc/rootfs.1 busy
|        /dev/sda4 is already mounted on /

As a result of this a

  rauc status --detailed

call will not give any data from the currently running rootfs.

The safest way to avoid issues like this is to use the already existing
information about detected external mounts and simply skip mounting if
the respective slot is already reported as being mounted.

Signed-off-by: Enrico Jorns <a2e5f936c390f36494e46e71bcfbe365bb1e8c49@pengutronix.de>

jluebbe/rauc,rauc/rauc,ejoerns/rauc,ejoerns/rauc,jluebbe/rauc,rauc/rauc,jluebbe/rauc,ejoerns/rauc,rauc/rauc