Desaturation Explanation

Hi,

The desaturation logic computes and applies desaturation gains twice: https://github.com/somebody-once-told-me/PX4-Autopilot/blob/8468e710a3efc7b5717ee1f5885822c62fd53016/src/modules/control_allocator/ControlAllocation/ControlAllocationSequentialDesaturation.cpp#L69

Can someone explain the algorithm, or point me to a reference?

Thanks.