diff mbox series

mmc: queue: Remove unused define

Message ID 20210203072014.30272-1-cw9316.lee@samsung.com
State New
Headers show
Series mmc: queue: Remove unused define | expand

Commit Message

Chanwoo Lee Feb. 3, 2021, 7:20 a.m. UTC
From: ChanWoo Lee <cw9316.lee@samsung.com>

MMC_CQE_QUEUE_FULL is not set and is only cleared.
Therefore, define is unnecessary.

Signed-off-by: ChanWoo Lee <cw9316.lee@samsung.com>
---
 drivers/mmc/core/queue.c | 2 --
 drivers/mmc/core/queue.h | 1 -
 2 files changed, 3 deletions(-)

Comments

Adrian Hunter Feb. 3, 2021, 7:36 a.m. UTC | #1
On 3/02/21 9:20 am, Chanwoo Lee wrote:
> From: ChanWoo Lee <cw9316.lee@samsung.com>
> 
> MMC_CQE_QUEUE_FULL is not set and is only cleared.
> Therefore, define is unnecessary.
> 
> Signed-off-by: ChanWoo Lee <cw9316.lee@samsung.com>

Looks like a pre blk-mq remanent.

Acked-by: Adrian Hunter <adrian.hunter@intel.com>

> ---
>  drivers/mmc/core/queue.c | 2 --
>  drivers/mmc/core/queue.h | 1 -
>  2 files changed, 3 deletions(-)
> 
> diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c
> index 002426e3cf76..9f37a8b909e8 100644
> --- a/drivers/mmc/core/queue.c
> +++ b/drivers/mmc/core/queue.c
> @@ -33,8 +33,6 @@ void mmc_cqe_check_busy(struct mmc_queue *mq)
>  {
>  	if ((mq->cqe_busy & MMC_CQE_DCMD_BUSY) && !mmc_cqe_dcmd_busy(mq))
>  		mq->cqe_busy &= ~MMC_CQE_DCMD_BUSY;
> -
> -	mq->cqe_busy &= ~MMC_CQE_QUEUE_FULL;
>  }
>  
>  static inline bool mmc_cqe_can_dcmd(struct mmc_host *host)
> diff --git a/drivers/mmc/core/queue.h b/drivers/mmc/core/queue.h
> index fd11491ced9f..57c59b6cb1b9 100644
> --- a/drivers/mmc/core/queue.h
> +++ b/drivers/mmc/core/queue.h
> @@ -81,7 +81,6 @@ struct mmc_queue {
>  	int			in_flight[MMC_ISSUE_MAX];
>  	unsigned int		cqe_busy;
>  #define MMC_CQE_DCMD_BUSY	BIT(0)
> -#define MMC_CQE_QUEUE_FULL	BIT(1)
>  	bool			busy;
>  	bool			use_cqe;
>  	bool			recovery_needed;
>
Ulf Hansson Feb. 8, 2021, 12:06 p.m. UTC | #2
On Wed, 3 Feb 2021 at 08:23, Chanwoo Lee <cw9316.lee@samsung.com> wrote:
>

> From: ChanWoo Lee <cw9316.lee@samsung.com>

>

> MMC_CQE_QUEUE_FULL is not set and is only cleared.

> Therefore, define is unnecessary.

>

> Signed-off-by: ChanWoo Lee <cw9316.lee@samsung.com>


Applied for next, thanks!

As a next step, we should probably convert the mq->cqe_busy member
into a bool rather than the unsigned int.

Kind regards
Uffe


> ---

>  drivers/mmc/core/queue.c | 2 --

>  drivers/mmc/core/queue.h | 1 -

>  2 files changed, 3 deletions(-)

>

> diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c

> index 002426e3cf76..9f37a8b909e8 100644

> --- a/drivers/mmc/core/queue.c

> +++ b/drivers/mmc/core/queue.c

> @@ -33,8 +33,6 @@ void mmc_cqe_check_busy(struct mmc_queue *mq)

>  {

>         if ((mq->cqe_busy & MMC_CQE_DCMD_BUSY) && !mmc_cqe_dcmd_busy(mq))

>                 mq->cqe_busy &= ~MMC_CQE_DCMD_BUSY;

> -

> -       mq->cqe_busy &= ~MMC_CQE_QUEUE_FULL;

>  }

>

>  static inline bool mmc_cqe_can_dcmd(struct mmc_host *host)

> diff --git a/drivers/mmc/core/queue.h b/drivers/mmc/core/queue.h

> index fd11491ced9f..57c59b6cb1b9 100644

> --- a/drivers/mmc/core/queue.h

> +++ b/drivers/mmc/core/queue.h

> @@ -81,7 +81,6 @@ struct mmc_queue {

>         int                     in_flight[MMC_ISSUE_MAX];

>         unsigned int            cqe_busy;

>  #define MMC_CQE_DCMD_BUSY      BIT(0)

> -#define MMC_CQE_QUEUE_FULL     BIT(1)

>         bool                    busy;

>         bool                    use_cqe;

>         bool                    recovery_needed;

> --

> 2.29.0

>
diff mbox series

Patch

diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c
index 002426e3cf76..9f37a8b909e8 100644
--- a/drivers/mmc/core/queue.c
+++ b/drivers/mmc/core/queue.c
@@ -33,8 +33,6 @@  void mmc_cqe_check_busy(struct mmc_queue *mq)
 {
 	if ((mq->cqe_busy & MMC_CQE_DCMD_BUSY) && !mmc_cqe_dcmd_busy(mq))
 		mq->cqe_busy &= ~MMC_CQE_DCMD_BUSY;
-
-	mq->cqe_busy &= ~MMC_CQE_QUEUE_FULL;
 }
 
 static inline bool mmc_cqe_can_dcmd(struct mmc_host *host)
diff --git a/drivers/mmc/core/queue.h b/drivers/mmc/core/queue.h
index fd11491ced9f..57c59b6cb1b9 100644
--- a/drivers/mmc/core/queue.h
+++ b/drivers/mmc/core/queue.h
@@ -81,7 +81,6 @@  struct mmc_queue {
 	int			in_flight[MMC_ISSUE_MAX];
 	unsigned int		cqe_busy;
 #define MMC_CQE_DCMD_BUSY	BIT(0)
-#define MMC_CQE_QUEUE_FULL	BIT(1)
 	bool			busy;
 	bool			use_cqe;
 	bool			recovery_needed;