Co-authored-by: Giacomo Pozzoni <[email protected]> (cherry picked from commit 1a624cad36f3067481ca54563a322cb85f90ad11)