Re: 答复: Re: [PATCH] multipath-tools: improve processing efficiency for addition and deletion of multipath devices

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

 



On Fri, 2017-02-17 at 11:24 +0800, tang.junhui@xxxxxxxxxx wrote:
> Hello Martin,
> 
> Thanks for your responsible,
> 
> > I'd like the following better for this check. It uses much less cyc
> les.
> 
> >  static bool
> > can_discard_by_devpath(const char *devpath)
> 
> > This would be better readable and faster if you'd put the "kernel"
> > tests first so that you need to check only "action" later:
> 
> >     if (!strncmp(later->kernel, "dm-", 3) ||
> >        strcmp(earlier->kernel, later->kernel))
> >        return false;
> 
> Yes, I think these codes can be reworked, but since they have no
> logical
> effect, and this patch takes too long time, can you commit a new
> patch 
> to rework these codes?

Yes, I could do that.

Regards
Martin

-- 
Dr. Martin Wilck <mwilck@xxxxxxxx>, Tel. +49 (0)911 74053 2107
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)

--
dm-devel mailing list
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