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

Skip to content
Commit f2dda068 authored by Pavan Anamula's avatar Pavan Anamula Committed by Xiaonian Wang
Browse files

drivers: mmc: fix issue raised by source code analyzer tool



Fix the below reported issues by source code analyzer.

1) Pointer 'ext_csd' returned from call to function 'mmc_get_ext_csd'
may be NULL and will be dereferenced at ext_csd[EXT_CSD_CMDQ] in
mmc_test_awake_ext_csd(), causing NUll pointer derefernce.

2) Array 'sdhci_slot' of size 2 may use index value(s) -1 as below,
when ret = 0.

	sdhci_slot[ret-1] = msm_host;

3) Variable 'host->lock' locked ,And was not unlocked when below
condition occurs in sdhci_irq().

	if (!mmc_card_and_host_support_async_int(host->mmc))
		return IRQ_NONE;

CRs-Fixed: 1000387
Change-Id: Iec6ecef1bf940e720c871be58b265394904f0cf1
Signed-off-by: default avatarPavan Anamula <pavana@codeaurora.org>
parent 5f768323
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment