platform-$(CONFIG_XTENSA_PLATFORM_ISS)         := iss
 platform-$(CONFIG_XTENSA_PLATFORM_XTFPGA)      := xtfpga
 
-PLATFORM = $(platform-y)
-
 # temporarily until string.h is fixed
 KBUILD_CFLAGS += -ffreestanding -D__linux__
 KBUILD_CFLAGS += -pipe -mlongcalls -mtext-section-literals
 
 KBUILD_DEFCONFIG := iss_defconfig
 
-# Only build platform if it includes a Makefile
-buildplf := $(shell test -e $(srctree)/arch/xtensa/platforms/$(PLATFORM)/Makefile && echo arch/xtensa/platforms/$(PLATFORM)/)
-
 # Find libgcc.a
 
 LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name)
 
 head-y         := arch/xtensa/kernel/head.o
 core-y         += arch/xtensa/kernel/ arch/xtensa/mm/
-core-y         += $(buildplf)
+core-y         += arch/xtensa/platforms/$(platform-y)/
 core-y                 += arch/xtensa/boot/dts/
 
 libs-y         += arch/xtensa/lib/ $(LIBGCC)