mmc_card: no zombie threads please
This commit is contained in:
parent
8f45cf697f
commit
0601c4b6bf
|
@ -570,11 +570,7 @@ static THD_FUNCTION(MMCmonThread, arg) {
|
|||
chThdSleepMilliseconds(300);
|
||||
#endif
|
||||
|
||||
if (!mountMmc()) {
|
||||
// no card present (or mounted via USB), don't do internal logging
|
||||
return;
|
||||
}
|
||||
|
||||
if (mountMmc()) {
|
||||
#if EFI_TUNER_STUDIO
|
||||
engine->outputChannels.sd_logging_internal = true;
|
||||
#endif
|
||||
|
@ -584,6 +580,16 @@ static THD_FUNCTION(MMCmonThread, arg) {
|
|||
} else {
|
||||
mlgLogger();
|
||||
}
|
||||
} else {
|
||||
// no card present (or mounted via USB), don't do internal logging
|
||||
}
|
||||
|
||||
efiPrintf("SD logger has died!");
|
||||
|
||||
// exiting thread will create zombie!
|
||||
while(1) {
|
||||
chThdSleepMilliseconds(100);
|
||||
}
|
||||
}
|
||||
|
||||
void mlgLogger() {
|
||||
|
|
Loading…
Reference in New Issue