Adapters and root directories

Hello all,
do you know how can I know, that a given root directory is at a given adapter name?
I mean, if you have two SCSI adapters, and you have the names, how can you determine, that a given root directory is member of one of these adapters?
I’m trying to write application, not driver…

Best:
Mark