olafhering/xen — pull request #1 by aaannz (2014-04-24 08:34:36+00:00)
Title: allow /dev/sda as scsi devspec

Workflow as you suggested, stat for /dev/xxx device to get major:minor and than use /sys/dev/block/major:minor link and than enumerate scsi_device entry. I am currently taking the first match I get, the question is if this is right and if one device can has more scsi devices.

I put it all into #ifdef __linux__ as I think xen may be running on some bsd systems too.