1diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst
2index 07650ee..934a7a8 100644
3--- a/scripts/Makefile.modinst
4+++ b/scripts/Makefile.modinst
5@@ -9,7 +9,8 @@ include scripts/Kbuild.include
6
7 #
8
9-__modules := $(sort $(shell grep -h '\.ko$$' /dev/null $(wildcard $(MODVERDIR)/*.mod)))
10+__modules := $(sort $(foreach f,$(wildcard $(MODVERDIR)/*.mod),$(shell \
11+ grep -h '\.ko$$' '$f')))
12 modules := $(patsubst %.o,%.ko,$(wildcard $(__modules:.ko=.o)))
13
14 PHONY += $(modules)