Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Aug 2005 03:19:53 GMT
From:      soc-cjones <soc-cjones@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 82585 for review
Message-ID:  <200508260319.j7Q3JrXm007936@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=82585

Change 82585 by soc-cjones@soc-cjones_ishtar on 2005/08/26 03:19:48

	Duh.  So simple.  Of course you need to initialize the pointer to the vinumconf in the new sd.  Gah.  So now it works.

Affected files ...

.. //depot/projects/soc2005/gvinum/src/sys/geom/vinum/geom_vinum_move.c#13 edit

Differences ...

==== //depot/projects/soc2005/gvinum/src/sys/geom/vinum/geom_vinum_move.c#13 (text+ko) ====

@@ -225,7 +225,9 @@
 	strncpy(newsd->name, cursd->name, GV_MAXSDNAME);
 	strncpy(newsd->drive, destination, GV_MAXDRIVENAME);
 	newsd->state = GV_SD_STALE;
-	printf("gv_move_sd: initialized newsd; name='%s', drive='%s', size=%lld, plex_offset=%lld\n", newsd->name, newsd->drive, newsd->size, newsd->plex_offset);
+	newsd->vinumconf = cursd->vinumconf;
+	printf("gv_move_sd: initialized newsd; name='%s', drive='%s', size=%lld, plex_offset=%lld\n",
+	       newsd->name, newsd->drive, newsd->size, newsd->plex_offset);
 	err = gv_sd_to_drive(sc, d, newsd, errstr, ERRBUFSIZ);
 	printf("gv_move_sd: allocated newsd to drive, drive_offset=%lld\n", newsd->drive_offset);
 	if (err) { /* XXX not enough free space? */
@@ -240,7 +242,8 @@
 	g_detach(cp);
         printf("gv_move_sd: detached consumer\n");
 	LIST_FOREACH_SAFE(s, &p->subdisks, in_plex, s2) {
-	    printf("gv_move_sd: traversing in_plex list (s: %p, s->name: '%s', s2: %p)\n", s, s->name, s2);
+	    printf("gv_move_sd: traversing in_plex list (s: %p, s->name: '%s', s2: %p)\n", 
+		   s, s->name, s2);
 	    printf("gv_move_sd: for sd '%s', consumer = %p\n", s->name, s->consumer);
 		if (s == cursd) {
 		    printf("\thit!\n");
@@ -272,7 +275,7 @@
 	} else {
 		printf("gv_move_sd: set newsd->consumer to %p\n", newsd->consumer);
 	}
-	newsd->consumer = cp;
+	/* newsd->consumer = cp; */
 	printf("gv_move_sd: before LIST_INSERT_HEAD\n");
 	LIST_INSERT_HEAD(&sc->subdisks, newsd, sd);
 	printf("gv_move_sd: inserted newsd into subdisks list\n");



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200508260319.j7Q3JrXm007936>