mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yahu Gao <yahu.gao@outlook.com>
To: dlemoal@kernel.org
Cc: linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org,
	Yahu Gao <gaoyh12@lenovo.com>, Jiwei Sun <sunjw10@lenovo.com>
Subject: Re: [PATCH v2] ata: libata-core: Simplies if condition
Date: Fri, 28 Apr 2023 09:53:58 +0800	[thread overview]
Message-ID: <OS0P286MB06283D2E74F02D7C541E46D79E6B9@OS0P286MB0628.JPNP286.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <OS3P286MB0632739A614E451725FF697D9E619@OS3P286MB0632.JPNP286.PROD.OUTLOOK.COM>

ping ...

在 2023/4/22 20:14, Yahu Gao 写道:
> From: Yahu Gao <gaoyh12@lenovo.com>
>
> Replace conditions of avoid issuing [P]IDENTIFY to PMP.
>
> Reviewed-by: Jiwei Sun <sunjw10@lenovo.com>
> Signed-off-by: Yahu Gao <gaoyh12@lenovo.com>
>
> diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
> index 14c17c3bda4e..53f65d751189 100644
> --- a/drivers/ata/libata-core.c
> +++ b/drivers/ata/libata-core.c
> @@ -3802,11 +3802,7 @@ int ata_dev_revalidate(struct ata_device *dev, unsigned int new_class,
>   		return -ENODEV;
>   
>   	/* fail early if !ATA && !ATAPI to avoid issuing [P]IDENTIFY to PMP */
> -	if (ata_class_enabled(new_class) &&
> -	    new_class != ATA_DEV_ATA &&
> -	    new_class != ATA_DEV_ATAPI &&
> -	    new_class != ATA_DEV_ZAC &&
> -	    new_class != ATA_DEV_SEMB) {
> +	if (new_class == ATA_DEV_PMP) {
>   		ata_dev_info(dev, "class mismatch %u != %u\n",
>   			     dev->class, new_class);
>   		rc = -ENODEV;

  reply	other threads:[~2023-04-28  1:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20230422121415.6276-1-yahu.gao@outlook.com>
2023-04-22 12:14 ` Yahu Gao
2023-04-28  1:53   ` Yahu Gao [this message]
2023-04-28  9:51     ` Damien Le Moal
2023-05-14 22:53     ` Damien Le Moal
2023-04-22 12:14 Yahu Gao
2023-05-14 22:54 ` Damien Le Moal

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=OS0P286MB06283D2E74F02D7C541E46D79E6B9@OS0P286MB0628.JPNP286.PROD.OUTLOOK.COM \
    --to=yahu.gao@outlook.com \
    --cc=dlemoal@kernel.org \
    --cc=gaoyh12@lenovo.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sunjw10@lenovo.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®