How to fill a big cavity on a wooden door frame?
I would push some backer rod into the space so it fills most of the void but not all, leave some space to fill with wood filler or vinyl Spackle.
Once the filler is dry you can sand it all down and paint.