diff options
author | David Zeuthen <davidz@redhat.com> | 2009-12-04 11:25:09 -0500 |
---|---|---|
committer | David Zeuthen <davidz@redhat.com> | 2009-12-04 11:40:00 -0500 |
commit | 7f4954d04026f28b0ebe65a514f06fefad8efaca (patch) | |
tree | cd7b920ae51dd2c4663ad983e90ea3774ea68bb8 /extras/scsi_id/scsi_id.h | |
parent | 07fb7fce66a101b22c3e121e3ee99438db798b8e (diff) |
Export ID_WWN_VENDOR_EXTENSION and ID_WWN_WITH_EXTENSION
Some SCSI devices use the same WWN and have a WWN extension that we
need to take into account when creating the /dev/disk/by-id/wwn
symlinks. Thus, introduce ID_WWN_WITH_EXTENSION. This property will
contain either the WWN (if no extension is present) or the WWN with
the vendor extension appended.
Example:
# /lib/udev/ata_id/ata_id --export /dev/sda |grep WWN
ID_WWN=0x5001517387d61905
ID_WWN_WITH_EXTENSION=0x5001517387d61905
# /lib/udev/scsi_id --whitelisted --export -d /dev/sdb |grep WWN
ID_WWN=0x600508b400105df7
ID_WWN_VENDOR_EXTENSION=0x0000e00000d80000
ID_WWN_WITH_EXTENSION=0x600508b400105df70000e00000d80000
# /lib/udev/scsi_id --whitelisted --export -d /dev/sdc |grep WWN
ID_WWN=0x600508b400105df7
ID_WWN_VENDOR_EXTENSION=0x0000e00000db0000
ID_WWN_WITH_EXTENSION=0x600508b400105df70000e00000db0000
Signed-off-by: David Zeuthen <davidz@redhat.com>
Diffstat (limited to 'extras/scsi_id/scsi_id.h')
-rw-r--r-- | extras/scsi_id/scsi_id.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/extras/scsi_id/scsi_id.h b/extras/scsi_id/scsi_id.h index 4536cfd4f2..3b8b236368 100644 --- a/extras/scsi_id/scsi_id.h +++ b/extras/scsi_id/scsi_id.h @@ -1,4 +1,5 @@ -/* +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- + * * scsi_id.h * * General defines and such for scsi_id @@ -45,6 +46,9 @@ struct scsi_id_device { /* NULs if not set - otherwise hex encoding using lower-case e.g. '50014ee0016eb572' */ char wwn[17]; + + /* NULs if not set - otherwise hex encoding using lower-case e.g. '0xe00000d80000' */ + char wwn_vendor_extension[17]; }; extern int scsi_std_inquiry(struct udev *udev, struct scsi_id_device *dev_scsi, const char *devname); |