core: don't reset assume state too early

Beniamino Galvani requested to merge bg/assume into main

If the device is still unmanaged by platform-init (which means that udev didn't emit the event for the interface) when the device gets realized, we currently clear the assume state. Later, when the device becomes managed, NM is not able to properly assume the device using the UUID.

This situation arises when NM already configured the device in initrd and after switch root udev runs again.

Among all unamanaged flags, platform-init is the only one that can be delayed externally. We should not clear the assume state if the device has only platform-init in the unmanaged flags.

Merge request reports