diff options
author | Pav Lucistnik <pav@FreeBSD.org> | 2007-10-21 16:18:51 +0000 |
---|---|---|
committer | Pav Lucistnik <pav@FreeBSD.org> | 2007-10-21 16:18:51 +0000 |
commit | 9cd588d1cf0fe22009924016f119eed12abe1ed0 (patch) | |
tree | 78deef4001bc52d2daf19e3e971256cf6a27379d /sysutils/smartmontools-devel/files/patch-os__freebsd.cpp | |
parent | - Update to 5.6 snapshot 20071020 (diff) |
- Allow smartctl to interact with SCSI /dev/pass devices, thus enabling it to
work with RAID controllers that expose disks via these devices.
Submitted by: scottl
Notes
Notes:
svn path=/head/; revision=201726
Diffstat (limited to 'sysutils/smartmontools-devel/files/patch-os__freebsd.cpp')
-rw-r--r-- | sysutils/smartmontools-devel/files/patch-os__freebsd.cpp | 29 |
1 files changed, 23 insertions, 6 deletions
diff --git a/sysutils/smartmontools-devel/files/patch-os__freebsd.cpp b/sysutils/smartmontools-devel/files/patch-os__freebsd.cpp index 7a20564c8cb9..8521192345c1 100644 --- a/sysutils/smartmontools-devel/files/patch-os__freebsd.cpp +++ b/sysutils/smartmontools-devel/files/patch-os__freebsd.cpp @@ -1,9 +1,26 @@ - -$FreeBSD$ - ---- os_freebsd.cpp.orig -+++ os_freebsd.cpp -@@ -1008,7 +1008,7 @@ +--- os_freebsd.cpp.orig 2006-09-17 05:17:53.000000000 +0200 ++++ os_freebsd.cpp 2007-10-21 18:09:02.000000000 +0200 +@@ -873,6 +873,7 @@ + static const char * fbsd_dev_prefix = "/dev/"; + static const char * fbsd_dev_ata_disk_prefix = "ad"; + static const char * fbsd_dev_scsi_disk_plus = "da"; ++static const char * fbsd_dev_scsi_pass = "pass"; + static const char * fbsd_dev_scsi_tape1 = "sa"; + static const char * fbsd_dev_scsi_tape2 = "nsa"; + static const char * fbsd_dev_scsi_tape3 = "esa"; +@@ -908,6 +909,11 @@ + return CONTROLLER_ATA; + } + ++ // form /dev/pass* or pass* ++ if (!strncmp(fbsd_dev_scsi_pass, dev_name, ++ strlen(fbsd_dev_scsi_pass))) ++ goto handlescsi; ++ + // form /dev/da* or da* + if (!strncmp(fbsd_dev_scsi_disk_plus, dev_name, + strlen(fbsd_dev_scsi_disk_plus))) +@@ -1008,7 +1014,7 @@ // to first list. Turn on NOCHECK for second call. This results in no // error if no more matches found, however it does append the actual // pattern to the list of paths.... |