Messages in this thread | | | Date | Sun, 12 Nov 2023 14:00:42 +0000 | From | Marc Zyngier <> | Subject | Re: [PATCH] irqdesc: Fail check on early_irq_init allocation. |
| |
On Sat, 11 Nov 2023 17:00:36 +0000, Paran Lee <p4ranlee@gmail.com> wrote: > > When doing start_kernel(), > On early_irq_init(), alloc_desc() or alloc_percpu() > may be fails. So, Explicit fail check needed on dynamic allocation.
A failing allocation already results in a massive splat describing how the allocation failed. Further use of the NULL pointer will also result in a terminal oops, particularly if this happens this early in the boot sequence.
So what do these BUG_ON() calls buy us?
M.
-- Without deviation from the norm, progress is not possible.
| |