[bug report]scsi: drive letter drift problem

From: Wenchao Hao
Date: Mon Jul 12 2021 - 00:47:11 EST


We deploy two SCSI disk in one SCSI host(virtio-scsi bus) for one machine, whose ids are [0:0:0:0] and [0:0:1:0].

Mostly, the device letter are assigned as following after reboot:
[0:0:0:0] --> sda
[0:0:1:0] --> sdb

While in rare cases, the device letter shown as following:
[0:0:0:0] --> sdb
[0:0:1:0] --> sda

Could we guarantee "sda" is assigned to [0:0:0:0] and "sdb" is assigned to [0:0:1:0] or not?
If we can, then how?