From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C1F87129EF7 for ; Mon, 18 Dec 2023 13:46:02 +0000 (UTC) Received: from rdvivi-mobl4 (unknown [192.55.55.58]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp.kernel.org (Postfix) with ESMTPSA id 8A0B9C433C8; Mon, 18 Dec 2023 13:46:00 +0000 (UTC) Date: Mon, 18 Dec 2023 08:45:58 -0500 From: Rodrigo Vivi To: Himal Prasad Ghimiray Cc: Lucas De Marchi , Rodrigo Vivi , Badal Nilawar , Akinobu Mita , Jason Gunthorpe , Jens Axboe , Qi Zheng , linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/1] fault-inject: Include linux/types.h by default. Message-ID: References: <20230816134748.979231-1-himal.prasad.ghimiray@intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230816134748.979231-1-himal.prasad.ghimiray@intel.com> On Wed, Aug 16, 2023 at 07:17:48PM +0530, Himal Prasad Ghimiray wrote: > Functions should_fail_alloc_page, should_failslab, and __should_failslab > are declared irrespective of CONFIG_FAULT_INJECTION. These functions use > bool and gfp_t types, which are treated as unknown when > CONFIG_FAULT_INJECTION is disabled because the inclusion of linux/types.h > is missing. > > Fixes: 6ff1cb355e62 ("[PATCH] fault-injection capabilities infrastructure") gentle ping on this one. we'd like to be able to include fault-inject.c without adding extra includes that should be taken care by the fault-inject.h itself. > > Cc: Lucas De Marchi > Cc: Rodrigo Vivi > Cc: Badal Nilawar > Cc: Akinobu Mita > Cc: Jason Gunthorpe > Cc: Jens Axboe > Cc: Qi Zheng > Cc: linux-kernel@vger.kernel.org Cc: Andrew Morton Cc: Kefeng Wang > Signed-off-by: Himal Prasad Ghimiray Reviewed-by: Rodrigo Vivi > --- > include/linux/fault-inject.h | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/include/linux/fault-inject.h b/include/linux/fault-inject.h > index 481abf530b3c..f83ab2b6cd08 100644 > --- a/include/linux/fault-inject.h > +++ b/include/linux/fault-inject.h > @@ -2,9 +2,10 @@ > #ifndef _LINUX_FAULT_INJECT_H > #define _LINUX_FAULT_INJECT_H > > +#include > + > #ifdef CONFIG_FAULT_INJECTION > > -#include > #include > #include > #include > -- > 2.25.1 >