Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ffa8ed13 authored by Dafna Hirschfeld's avatar Dafna Hirschfeld Committed by Greg Kroah-Hartman
Browse files

staging: mt7621-mmc: Fix comparison to NULL



Replace comparisons of a variable 'x' to NULL with
either 'x' or '!x'.
Issues found with checkpatch.pl

Signed-off-by: default avatarDafna Hirschfeld <dafna3@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f259e47a
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -851,8 +851,8 @@ static int msdc_do_request(struct mmc_host *mmc, struct mmc_request *mrq)
#define SND_DAT 0
#define SND_CMD 1

	BUG_ON(mmc == NULL);
	BUG_ON(mrq == NULL);
	BUG_ON(!mmc);
	BUG_ON(!mrq);

	host->error = 0;

@@ -946,7 +946,7 @@ static int msdc_do_request(struct mmc_host *mmc, struct mmc_request *mrq)
	}

done:
	if (data != NULL) {
	if (data) {
		host->data = NULL;
		dma_unmap_sg(mmc_dev(mmc), data->sg, data->sg_len,
			     mmc_get_dma_dir(data));
@@ -1638,7 +1638,7 @@ static irqreturn_t msdc_irq(int irq, void *dev_id)
	}

	/* transfer complete interrupt */
	if (data != NULL) {
	if (data) {
		if (inten & MSDC_INT_XFER_COMPL) {
			data->bytes_xfered = host->xfer_size;
			complete(&host->xfer_done);
@@ -1661,7 +1661,7 @@ static irqreturn_t msdc_irq(int irq, void *dev_id)
	}

	/* command interrupts */
	if ((cmd != NULL) && (intsts & cmdsts)) {
	if (cmd && (intsts & cmdsts)) {
		if ((intsts & MSDC_INT_CMDRDY) || (intsts & MSDC_INT_ACMDRDY) ||
			(intsts & MSDC_INT_ACMD19_DONE)) {
			u32 *rsp = &cmd->resp[0];