RE: Clariion CX600 automatic failback support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Date: Fri, 04 Nov 2005 21:55:20 +0100
Christophe Varoqui <christophe.varoqui@xxxxxxx> wrote

> Subject: RE:  Clariion CX600 automatic failback support
> To: device-mapper development <dm-devel@xxxxxxxxxx>
> Message-ID: <1131137721.7463.12.camel@zezette>
> Content-Type: text/plain; charset=utf-8
> 
> 
> > > Yes, the test to determine if a switch is needed is sub-optimal :
> > > The no activated PG case (all Enabled for exampleÃ) keeps 
> > > triggering a switch.
> > > I checked-in a patch to solve that issue.
> > 
> > I've dealt with this problem by patching the device mapper
> > multipath driver in the kernel.
> > 
> > The patch below patches drivers/md/dm-mpath.c:multipath_status()
> > to return an active state for a path group which is either the
> > current path group or setup to be the next path group instead
> > of just returning an active state for a path group which is
> > currently active.
> > 
> Right, it deserved to be done.
> 
> I'm inclined to keep the tools patch anyway : it wastes an "int" per
> multipath but is brain-friendlier (as it avoids using mpp->nextpg to
> represent the current setting *and* the best-rated setting).
> 
> Are interested parties ok with that ?

Good point.  This slightly modified patch fixes the "*and*" case by only
returning active if either the particular path group is the current active
or there is no current active but the particular path group is set to be
the next (first) deferred active path group.

*** ../base/linux-2.6.14-rc4/drivers/md/dm-mpath.c	Mon Oct 10 20:19:19
2005
--- drivers/md/dm-mpath.c	Sat Nov  5 03:02:50 2005
***************
*** 1158,1164 ****
  		list_for_each_entry(pg, &m->priority_groups, list) {
  			if (pg->bypassed)
  				state = 'D';	/* Disabled */
! 			else if (pg == m->current_pg)
  				state = 'A';	/* Currently Active */
  			else
  				state = 'E';	/* Enabled */
--- 1158,1164 ----
  		list_for_each_entry(pg, &m->priority_groups, list) {
  			if (pg->bypassed)
  				state = 'D';	/* Disabled */
! 			else if ((pg == m->current_pg) || ((!m->current_pg)
&&(pg == m->next_pg)))
  				state = 'A';	/* Currently Active */
  			else
  				state = 'E';	/* Enabled */

--

dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux