esp32s3: Use PANIC() instead of assert(0)

Considering kernel code, it's reasonable to use `PANIC()` instead
of `assert(0)` to handle with situations that require abort. Unlike
`assert`, `PANIC()` doesn't dependent on `NDEBUG`.
This commit is contained in:
Tiago Medicci Serrano
2023-08-14 16:29:21 -03:00
committed by Alan Carvalho de Assis
parent 6f235c5f0a
commit 281ab83309
2 changed files with 4 additions and 4 deletions
@@ -2317,7 +2317,7 @@ int esp32s3_bt_controller_init(void)
else
{
wlerr("Internal 150kHz RC oscillator not detected.");
assert(0);
PANIC();
}
#endif
@@ -802,7 +802,7 @@ static void esp_set_isr(int32_t n, void *f, void *arg)
if (!adapter)
{
wlerr("Failed to alloc %d memory\n", tmp);
assert(0);
PANIC();
return;
}
@@ -813,7 +813,7 @@ static void esp_set_isr(int32_t n, void *f, void *arg)
if (ret)
{
wlerr("Failed to attach IRQ %d\n", irq);
assert(0);
PANIC();
return;
}
@@ -821,7 +821,7 @@ static void esp_set_isr(int32_t n, void *f, void *arg)
if (ret)
{
wlerr("Failed to attach IRQ %d\n", irq);
assert(0);
PANIC();
return;
}
}