Skip to content

Commit

Permalink
selftests/gpio: Use TEST_GEN_PROGS_EXTENDED
Browse files Browse the repository at this point in the history
[ Upstream commit ff2c395 ]

Use TEST_GEN_PROGS_EXTENDED rather than TEST_PROGS_EXTENDED.

That tells the lib.mk logic that the files it references are to be
generated by the Makefile.

Having done that we don't need to override the all rule.

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
mpe authored and gregkh committed Jun 3, 2021
1 parent 1cdabf9 commit beac83e
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tools/testing/selftests/gpio/Makefile
Expand Up @@ -11,22 +11,20 @@ LDLIBS += $(VAR_LDLIBS)

TEST_PROGS := gpio-mockup.sh
TEST_FILES := gpio-mockup-sysfs.sh
TEST_PROGS_EXTENDED := gpio-mockup-chardev
TEST_GEN_PROGS_EXTENDED := gpio-mockup-chardev

GPIODIR := $(realpath ../../../gpio)
GPIOOBJ := gpio-utils.o

all: $(TEST_PROGS_EXTENDED)

override define CLEAN
$(RM) $(TEST_PROGS_EXTENDED)
$(RM) $(TEST_GEN_PROGS_EXTENDED)
$(MAKE) -C $(GPIODIR) OUTPUT=$(GPIODIR)/ clean
endef

KSFT_KHDR_INSTALL := 1
include ../lib.mk

$(TEST_PROGS_EXTENDED): $(GPIODIR)/$(GPIOOBJ)
$(TEST_GEN_PROGS_EXTENDED): $(GPIODIR)/$(GPIOOBJ)

$(GPIODIR)/$(GPIOOBJ):
$(MAKE) OUTPUT=$(GPIODIR)/ -C $(GPIODIR)

0 comments on commit beac83e

Please sign in to comment.