From 31f0ec99bb753ae357d4da442d3497e651a77427 Mon Sep 17 00:00:00 2001 From: Ji Luo Date: Wed, 4 Nov 2020 20:29:01 +0800 Subject: [PATCH] MA-18214-1 Hard code the BT mac address for imx8mp imx8mp has serial number as all zeros, hard code the BT mac address for such case instead of setting it by property. Test: BT on imx8mp. Change-Id: I99f5b49164e1fa40c7fc6ecb639c71fa89158852 Signed-off-by: Ji Luo (cherry picked from commit 501690cb93c4df30700c1bf40f0f2eaed2444503) (cherry picked from commit 312109135045b450d57c3095a822db827a587be6) --- common/image-android.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/common/image-android.c b/common/image-android.c index 892801d6cc..ab2b03249b 100644 --- a/common/image-android.c +++ b/common/image-android.c @@ -89,8 +89,13 @@ static void append_kernel_cmdline(char *commandline) " androidboot.btmacaddr=%c%c:%c%c:%c%c:%c%c:%c%c:%c%c", bd_addr[0],bd_addr[1],bd_addr[2],bd_addr[3],bd_addr[4],bd_addr[5], bd_addr[6],bd_addr[7],bd_addr[8],bd_addr[9],bd_addr[10],bd_addr[11]); - strncat(commandline, newbootargs, COMMANDLINE_LENGTH - strlen(commandline)); + } else { + /* Some boards have serial number as all zeros (imx8mp), + * hard code the bt mac address for such case. */ + sprintf(newbootargs, " androidboot.btmacaddr=22:22:67:C6:69:73"); } + + strncat(commandline, newbootargs, COMMANDLINE_LENGTH - strlen(commandline)); #endif /* append soc type into bootargs */ -- 2.17.1