Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751550AbdISVf0 (ORCPT ); Tue, 19 Sep 2017 17:35:26 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:36108 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751309AbdISVfY (ORCPT ); Tue, 19 Sep 2017 17:35:24 -0400 X-Google-Smtp-Source: AOwi7QA5dmW1JFs9XBnZhVOwNLx8RN/X/WqyYYyz9jRcsEz7edJjY0QGXep7XqaIxMUr0363JGuKmPBENMbmdZrexyk= MIME-Version: 1.0 In-Reply-To: References: <20170919115042.6800-1-net147@gmail.com> From: Jonathan Liu Date: Wed, 20 Sep 2017 07:35:23 +1000 Message-ID: Subject: Re: [PATCH] ARM: uaccess: Add missing include for set_thread_flag To: Thomas Garnier Cc: Russell King , Thomas Gleixner , Linux ARM , LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1534 Lines: 56 Hi Thomas, The top of the C source file I am compiling has: #include #include Tracing through the asm/uaccess.h include I see asm/uaccess.h -> asm/domain.h -> asm/thread_info.h but set_thread_info is defined in linux/thread_info.h not asm/thread_info.h (see http://elixir.free-electrons.com/linux/v4.14-rc1/ident/set_thread_flag). Regards, Jonathan On 20 September 2017 at 00:32, Thomas Garnier wrote: > On Tue, Sep 19, 2017 at 4:50 AM, Jonathan Liu wrote: >> Fixes "implicit declaration of function" compile error for out-of-tree >> kernel modules including asm/uaccess.h. > > I failed to reproduce this issue by creating an out of tree module > with a separate file (with only uaccess.h). Are you using a special > config? > > Looking at the headers on uaccess.h. You get thread_info through: > > asm/domain.h -> asm/thread_info.h > >> >> Fixes: 73ac5d6a2b6a ("arm/syscalls: Check address limit on user-mode return") >> Signed-off-by: Jonathan Liu >> --- >> arch/arm/include/asm/uaccess.h | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/arch/arm/include/asm/uaccess.h b/arch/arm/include/asm/uaccess.h >> index 87936dd5d151..13d1877ffb75 100644 >> --- a/arch/arm/include/asm/uaccess.h >> +++ b/arch/arm/include/asm/uaccess.h >> @@ -17,6 +17,7 @@ >> #include >> #include >> >> +#include >> #include >> >> /* >> -- >> 2.13.2 >> > > > > -- > Thomas