Generally, the first step in fixing something that's coming loose from your wall is to take it apart to get a good look at it. Often times the project can be completed just by tightening things back up. But what happens when that screw you need to tighten won't grip inside the hole anymore? Some jobs, but not many, will let you get away with using a larger or longer screw. There a many times however when you simply must
use the original screw type and size.
I use a little trick that works especially well for hinge screw holes and strike plate mounting screw holes. Those are two household mounting points which seem to take a lot of abuse. It can be particularly maddening when you're reattaching a door hinge or tightening a strike plate only to find that the hole is stripped out.
What I do is completely fill the screw hole with any good white glue
and then I insert two or three wooden toothpicks
into the hole, one at a time and tap them with a hammer until they're firmly in place. I break them off flush with the hole edge, then I let the glue cure for 24 hours. The next day a screw will take hold in that spot just like it did in the original wood.