All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Benjamin Marzinski" <bmarzins@redhat.com>
To: peng.liang5@zte.com.cn
Cc: dm-devel@redhat.com, zhang.kai16@zte.com.cn
Subject: Re: [PATCH] multipathd: remove unnecessary condition in check_path
Date: Tue, 1 Nov 2016 12:42:01 -0500	[thread overview]
Message-ID: <20161101174201.GD1972@octiron.msp.redhat.com> (raw)
In-Reply-To: <1477988071-5104-1-git-send-email-peng.liang5@zte.com.cn>

On Tue, Nov 01, 2016 at 04:14:31PM +0800, peng.liang5@zte.com.cn wrote:
> From: PengLiang <peng.liang5@zte.com.cn>
> 
> The pp->mpp is an unnecessary condition. It will be return before this condition
> if pp->mpp is NULL.

ACK

-Ben

> 
> Signed-off-by: PengLiang <peng.liang5@zte.com.cn>
> ---
>  multipathd/main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/multipathd/main.c b/multipathd/main.c
> index 03c2dd9..6a80ebe 100644
> --- a/multipathd/main.c
> +++ b/multipathd/main.c
> @@ -1566,7 +1566,7 @@ check_path (struct vectors * vecs, struct path * pp, int ticks)
>  
>  	if ((newstate == PATH_UP || newstate == PATH_GHOST) &&
>  	     pp->wait_checks > 0) {
> -		if (pp->mpp && pp->mpp->nr_active > 0) {
> +		if (pp->mpp->nr_active > 0) {
>  			pp->state = PATH_DELAYED;
>  			pp->wait_checks--;
>  			return 1;
> -- 
> 2.8.1.windows.1

      reply	other threads:[~2016-11-01 17:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-01  8:14 [PATCH] multipathd: remove unnecessary condition in check_path peng.liang5
2016-11-01 17:42 ` Benjamin Marzinski [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161101174201.GD1972@octiron.msp.redhat.com \
    --to=bmarzins@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=peng.liang5@zte.com.cn \
    --cc=zhang.kai16@zte.com.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.