manual picking from ChibiOS migration branch to make my evening a little less depressing

This commit is contained in:
rusefi 2017-03-27 22:52:43 -04:00
parent 9a4560b64d
commit 7a4515f78b
4 changed files with 6 additions and 3 deletions

View File

@ -144,7 +144,7 @@ void LECalculator::push(le_action_e action, float value) {
*/
bool LECalculator::processElement(Engine *engine, LEElement *element) {
#if EFI_PROD_CODE || defined(__DOXYGEN__)
efiAssert(getRemainingStack(chThdSelf()) > 64, "FSIO logic", false);
efiAssert(getRemainingStack(chThdGetSelfX()) > 64, "FSIO logic", false);
#endif
switch (element->action) {

View File

@ -132,7 +132,7 @@ static persisted_configuration_state_e doReadConfiguration(flashaddr_t address,
* connectivity so no console output here
*/
persisted_configuration_state_e readConfiguration(Logging * logger) {
efiAssert(getRemainingStack(chThdSelf()) > 256, "read f", PC_ERROR);
efiAssert(getRemainingStack(chThdGetSelfX()) > 256, "read f", PC_ERROR);
assertEngineReference(PASS_ENGINE_PARAMETER_F);
persisted_configuration_state_e result = doReadConfiguration(FLASH_ADDR, logger);
if (result != PC_OK) {

View File

@ -41,7 +41,7 @@ uint32_t lastExecutionCount;
static void executorCallback(void *arg) {
(void)arg;
efiAssertVoid(getRemainingStack(chThdSelf()) > 256, "lowstck#2y");
efiAssertVoid(getRemainingStack(chThdGetSelfX()) > 256, "lowstck#2y");
// callbackTime = getTimeNowNt();
// if((callbackTime > nextEventTimeNt) && (callbackTime - nextEventTimeNt > US2NT(5000))) {

View File

@ -63,6 +63,9 @@ typedef EventListener event_listener_t;
typedef EventSource event_source_t;
typedef VTList virtual_timers_list_t;
typedef VirtualTimer virtual_timer_t;
#define chSysLockFromISR chSysLockFromIsr
#define chSysUnlockFromISR chSysUnlockFromIsr
#define chThdGetSelfX chThdSelf
#define HAL_SUCCESS CH_SUCCESS
#define HAL_FAILED CH_FAILED