* Benjamin Lutz, 2006-10-16 :

> Well, I'm having problems with that. I built a new kernel with all the 
> CAM debugging options enabled (otherwise it's GENERIC), but this one 
> would panic as soon as I load the atapicam module if I load it 
> manually, or as soon as drive detection starts if the boot loader loads 
> it. I've had a look at the dump with kgdb, and it appears that a 
> null-dereference happens in line 4205 of sys/cam/cam_xpt.c: path2 is 
> NULL.

OK, sorry for the delay, can you apply the attached patch and try again?

Thomas.

Index: cam_xpt.c
===================================================================
RCS file: /space/mirror/ncvs/src/sys/cam/cam_xpt.c,v
retrieving revision 1.155.2.8
diff -u -r1.155.2.8 cam_xpt.c
--- cam_xpt.c   23 Sep 2006 18:42:08 -0000      1.155.2.8
+++ cam_xpt.c   26 Oct 2006 09:16:07 -0000
@@ -4202,6 +4202,9 @@
 
        int retval = 0;
 
+       if (path1 == NULL || path2 == NULL)
+               return (-1);
+
        if (path1->bus != path2->bus) {
                if (path1->bus->path_id == CAM_BUS_WILDCARD)
                        retval = 1;

Attachment: pgpMd4nh8eUoS.pgp
Description: PGP signature

Reply via email to