Author: mav
Date: Tue May  3 13:16:02 2011
New Revision: 221384
URL: http://svn.freebsd.org/changeset/base/221384

Log:
  Do not report legacy unit numbers (do not create legacy aliases) for disks
  on port multiplier ports above first two. They don't fit into ATA_STATIC_ID
  scheme and so can't be mapped properly. No need to pollute dev.

Modified:
  head/sys/cam/cam_xpt.c

Modified: head/sys/cam/cam_xpt.c
==============================================================================
--- head/sys/cam/cam_xpt.c      Tue May  3 12:29:03 2011        (r221383)
+++ head/sys/cam/cam_xpt.c      Tue May  3 13:16:02 2011        (r221384)
@@ -3600,9 +3600,12 @@ xpt_path_legacy_ata_id(struct cam_path *
                }
                xpt_unlock_buses();
        }
-       if (path->target != NULL)
-               return (bus_id * 2 + path->target->target_id);
-       else
+       if (path->target != NULL) {
+               if (path->target->target_id < 2)
+                       return (bus_id * 2 + path->target->target_id);
+               else
+                       return (-1);
+       } else
                return (bus_id * 2);
 }
 
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to