All of lore.kernel.org
 help / color / mirror / Atom feed
* [Ocfs2-devel] ocfs2: ei_cpos/phys confusion?
@ 2010-01-31 16:53 Roel Kluin
  2010-02-05  1:18 ` Tao Ma
  0 siblings, 1 reply; 2+ messages in thread
From: Roel Kluin @ 2010-01-31 16:53 UTC (permalink / raw)
  To: ocfs2-devel

in ocfs2_try_to_merge_extent_map(), vi fs/ocfs2/extent_map.c +185

        if (ins->ei_phys == (emi->ei_phys + emi->ei_clusters) &&
            ins->ei_cpos == (emi->ei_cpos + emi->ei_clusters) &&
            ins->ei_flags == emi->ei_flags) {
                emi->ei_clusters += ins->ei_clusters;
                return 1;
        } else if ((ins->ei_phys + ins->ei_clusters) == emi->ei_phys &&
                   (ins->ei_cpos + ins->ei_clusters) == emi->ei_phys &&
----------------------------------------------------------------^^^^
                   ins->ei_flags == emi->ei_flags) {
                emi->ei_phys = ins->ei_phys;
                emi->ei_cpos = ins->ei_cpos;
                emi->ei_clusters += ins->ei_clusters;
                return 1;
        }

should that 2nd emi->ei_phys be emi->ei_cpos?

Roel

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Ocfs2-devel] ocfs2: ei_cpos/phys confusion?
  2010-01-31 16:53 [Ocfs2-devel] ocfs2: ei_cpos/phys confusion? Roel Kluin
@ 2010-02-05  1:18 ` Tao Ma
  0 siblings, 0 replies; 2+ messages in thread
From: Tao Ma @ 2010-02-05  1:18 UTC (permalink / raw)
  To: ocfs2-devel

Hi Roel,

Roel Kluin wrote:
> in ocfs2_try_to_merge_extent_map(), vi fs/ocfs2/extent_map.c +185
> 
>         if (ins->ei_phys == (emi->ei_phys + emi->ei_clusters) &&
>             ins->ei_cpos == (emi->ei_cpos + emi->ei_clusters) &&
>             ins->ei_flags == emi->ei_flags) {
>                 emi->ei_clusters += ins->ei_clusters;
>                 return 1;
>         } else if ((ins->ei_phys + ins->ei_clusters) == emi->ei_phys &&
>                    (ins->ei_cpos + ins->ei_clusters) == emi->ei_phys &&
> ----------------------------------------------------------------^^^^
>                    ins->ei_flags == emi->ei_flags) {
>                 emi->ei_phys = ins->ei_phys;
>                 emi->ei_cpos = ins->ei_cpos;
>                 emi->ei_clusters += ins->ei_clusters;
>                 return 1;
>         }
> 
> should that 2nd emi->ei_phys be emi->ei_cpos?
oh, yes, you are right. Do you want to provide a patch?

Regards,
Tao
> 
> Roel
> 
> _______________________________________________
> Ocfs2-devel mailing list
> Ocfs2-devel at oss.oracle.com
> http://oss.oracle.com/mailman/listinfo/ocfs2-devel

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-02-05  1:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-31 16:53 [Ocfs2-devel] ocfs2: ei_cpos/phys confusion? Roel Kluin
2010-02-05  1:18 ` Tao Ma

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.