Skip to content

Commit

Permalink
target: msm8916: Allow forcing SD card (disable eMMC) with FORCE_SDCA…
Browse files Browse the repository at this point in the history
…RD=1
  • Loading branch information
stephan-gh committed Jan 1, 2022
1 parent bdfbcb7 commit 56944de
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,9 @@ endif
ifeq ($(LK2ND_FORCE_FASTBOOT),1)
DEFINES += LK2ND_FORCE_FASTBOOT=1
endif
ifeq ($(FORCE_SDCARD),1)
DEFINES += FORCE_SDCARD=1
endif

ifeq ($(ENABLE_VB_ATTEST),1)
DEFINES += ENABLE_VB_ATTEST=1
Expand Down
2 changes: 2 additions & 0 deletions target/msm8916/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ void target_sdc_init()
struct mmc_config_data config;
struct mmc_config_data sd_config;

#ifndef FORCE_SDCARD
/* Try slot 1*/
config.bus_width = DATA_BUS_WIDTH_8BIT;
config.slot = 1;
Expand All @@ -134,6 +135,7 @@ void target_sdc_init()
if (!emmc_dev) {
dprintf(CRITICAL, "FAILED TO INIT EMMC mmc_slot = %u \n",1);
}
#endif

dprintf(SPEW, "initialising mmc_slot =%u\n", 2);

Expand Down

0 comments on commit 56944de

Please sign in to comment.