Take another look at the sentence:
When Kareem walked into the tree, he ripped his shirt and banged his forehead,
which was old and holey.
Which was old and holey, an adjective clause, comes right after forehead, an illogical target. The shirt, not Kareem's forehead, is what's old and holey! Before you continue, review the rules for misplaced and dangling modifiers.
Go back to the sentence to try again.