diff mbox

[2/3] mmc: Add a new mmc_is_io_op helper function

Message ID 1448450927-13682-3-git-send-email-carlo@caione.org (mailing list archive)
State New, archived
Headers show

Commit Message

Carlo Caione Nov. 25, 2015, 11:28 a.m. UTC
From: Carlo Caione <carlo@endlessm.com>

Add a helper function to check if an opcode is a sd-io-* opcode.

Signed-off-by: Carlo Caione <carlo@endlessm.com>
---
 drivers/mmc/core/sdio_ops.h | 5 +++++
 1 file changed, 5 insertions(+)
diff mbox

Patch

diff --git a/drivers/mmc/core/sdio_ops.h b/drivers/mmc/core/sdio_ops.h
index e4b5ceb..9b614b2 100644
--- a/drivers/mmc/core/sdio_ops.h
+++ b/drivers/mmc/core/sdio_ops.h
@@ -26,5 +26,10 @@  static inline bool mmc_is_rw_io_op(u32 opcode)
 	return opcode == SD_IO_RW_DIRECT || opcode == SD_IO_RW_EXTENDED;
 }
 
+static inline bool mmc_is_io_op(u32 opcode)
+{
+	return mmc_is_rw_io_op(opcode) || opcode == SD_IO_SEND_OP_COND;
+}
+
 #endif