From: Christoph Hellwig <hch@lst.de>
To: tj@kernel.org
Cc: linux-ide@vger.kernel.org
Subject: [PATCH 1/3] libata: remove ata_is_nodata
Date: Sat, 16 Jul 2016 22:16:41 +0900 [thread overview]
Message-ID: <1468675003-13701-2-git-send-email-hch@lst.de> (raw)
In-Reply-To: <1468675003-13701-1-git-send-email-hch@lst.de>
The only caller an just check for !ata_is_data instead.
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
drivers/ata/libata-core.c | 2 +-
include/linux/libata.h | 5 -----
2 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 522848a..0749f71 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -5044,7 +5044,7 @@ static void ata_verify_xfer(struct ata_queued_cmd *qc)
{
struct ata_device *dev = qc->dev;
- if (ata_is_nodata(qc->tf.protocol))
+ if (!ata_is_data(qc->tf.protocol))
return;
if ((dev->mwdma_mask || dev->udma_mask) && ata_is_pio(qc->tf.protocol))
diff --git a/include/linux/libata.h b/include/linux/libata.h
index 1abd669..283b6be 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -1070,11 +1070,6 @@ static inline bool ata_is_atapi(u8 prot)
return ata_prot_flags(prot) & ATA_PROT_FLAG_ATAPI;
}
-static inline bool ata_is_nodata(u8 prot)
-{
- return !(ata_prot_flags(prot) & ATA_PROT_FLAG_DATA);
-}
-
static inline bool ata_is_pio(u8 prot)
{
return ata_prot_flags(prot) & ATA_PROT_FLAG_PIO;
--
2.1.4
next prev parent reply other threads:[~2016-07-16 13:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-16 13:16 protocol flag cleanups Christoph Hellwig
2016-07-16 13:16 ` Christoph Hellwig [this message]
2016-07-16 16:10 ` [PATCH 1/3] libata: remove ata_is_nodata Sergei Shtylyov
2016-07-17 1:26 ` Christoph Hellwig
2016-07-17 11:21 ` Sergei Shtylyov
2016-07-16 13:16 ` [PATCH 2/3] libata: remove ATA_PROT_FLAG_DATA Christoph Hellwig
2016-07-16 13:16 ` [PATCH 3/3] ata: define ATA_PROT_* in terms of ATA_PROT_FLAG_* Christoph Hellwig
2016-07-19 0:56 ` protocol flag cleanups Tejun Heo
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=1468675003-13701-2-git-send-email-hch@lst.de \
--to=hch@lst.de \
--cc=linux-ide@vger.kernel.org \
--cc=tj@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).