Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757594AbdCUNzB (ORCPT ); Tue, 21 Mar 2017 09:55:01 -0400 Received: from ec2-52-27-115-49.us-west-2.compute.amazonaws.com ([52.27.115.49]:45035 "EHLO osg.samsung.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1757355AbdCUNy4 (ORCPT ); Tue, 21 Mar 2017 09:54:56 -0400 Subject: Re: [PATCH v2 6/6] selftests: enable O and KBUILD_OUTPUT To: Bamvor Zhang Jian , Michael Ellerman References: <20161129115552.8148-1-bamvor.zhangjian@huawei.com> <20161129115552.8148-7-bamvor.zhangjian@huawei.com> <87fui7owls.fsf@concordia.ellerman.id.au> Cc: Andy Lutomirski , "Zhangjian (Bamvor)" , Linux API , "linux-kernel@vger.kernel.org" , Kevin Hilman , Mark Brown , Shuah Khan From: Shuah Khan Message-ID: <5daf0b79-a000-2adb-0b1e-f528d66ff6df@osg.samsung.com> Date: Tue, 21 Mar 2017 07:54:23 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2702 Lines: 75 On 03/21/2017 03:00 AM, Bamvor Zhang Jian wrote: > Hi, > > On 21 March 2017 at 16:35, Michael Ellerman wrote: >> Andy Lutomirski writes: >> >>> On Tue, Nov 29, 2016 at 3:55 AM, wrote: >>>> From: Bamvor Jian Zhang >>>> >>>> Enable O and KBUILD_OUTPUT for kselftest. User could compile kselftest >>>> to another directory by passing O or KBUILD_OUTPUT. And O is high >>>> priority than KBUILD_OUTPUT. >>> >>> Sorry for noticing this late, but this patch >>> (a8ba798bc8ec663cf02e80b0dd770324de9bafd9) is really annoying for >>> people who *don't* use these fancy options: >> >> Yeah sorry, it wasn't quite ready to go in. Bamovar, Please give me heads up and ask me to not commit the patch, if you think it isn't ready. >> >>> $ make -C tools/testing/selftests/x86 ldt_gdt_32 >>> make: Entering directory '/home/luto/apps/linux/tools/testing/selftests/x86' >>> Makefile:44: warning: overriding recipe for target 'clean' >>> ../lib.mk:55: warning: ignoring old recipe for target 'clean' >>> make: *** No rule to make target 'ldt_gdt_32'. Stop. >>> make: Leaving directory '/home/luto/apps/linux/tools/testing/selftests/x86' >>> >>> Is there any way that you can make this work again? >> >> There obviously is *a* way, but I'm not sure there's a simple and >> obviously correct way that is an easy fix for 4.11. >> >> I see at least 18 Makefile's in tools/testing/selftests that use >> $(OUTPUT)/, which would all need to be updated at least to use $(OUTPUT) >> (no trailing slash), and then some other changes to not propagate OUTPUT >> when the user didn't specify it. But hopefully someone will prove me >> wrong. > I also look at this issue. Originally, I use OUTPUT without slash in my > patch. People argue that it is not very clear. So, I add slash in curent > version. >> >> As a (poor) alternative you can do: >> >> $ cd tools/testing/selftests/x86; make $PWD/ldt_gdt_32 >> >> or just: >> >> $ make -C tools/testing/selftests/x86 >> >> cheers > Do we really need "make -C tools/testing/selftests/x86 ldt_gdt_32"? > It is useful but it will skip the top level Makefile of selftests. Being able to build individual tests is an important use-case. Please see kselftest.txt under Documentation directory for all the use-cases and new patches shouldn't break these use-cases. Breaking these use-cases is a regression and we have to fix it. thanks, -- Shuah > > Regards > > Bamvor >> -- >> To unsubscribe from this list: send the line "unsubscribe linux-api" in >> the body of a message to majordomo@vger.kernel.org >> More majordomo info at http://vger.kernel.org/majordomo-info.html