Fix overlapping of devices when generated.