From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 29339EB64D9 for ; Sat, 17 Jun 2023 18:49:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233868AbjFQStV (ORCPT ); Sat, 17 Jun 2023 14:49:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53746 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229663AbjFQStU (ORCPT ); Sat, 17 Jun 2023 14:49:20 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 39D2E139; Sat, 17 Jun 2023 11:49:19 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C22BD60E05; Sat, 17 Jun 2023 18:49:18 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D829DC433C0; Sat, 17 Jun 2023 18:49:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1687027758; bh=juJml5zp0/KVA49PSBk/X2QkCMRvnLk1esmJD55Wk0A=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=FybeXQwIIcJEiezzLLvi1D4S62KBiZr0uop1G77/KWtQUbF01467Svw0rqohE5JEm 9sEBUwDDQIjNt7vddWnJIGmrBaumnWgYAbDSQQG2gTgGQFx40+cVoUdRw7nICapudh SWbec3puSwLEnM2X71NxRlmxy5eZj4X9EPYEYIp6W9WdMQ8ZOgZHMPUr6rRVPFc6kF IEVw+yiB/w8MoN9XtjfIKbobVBd5kioyG83Rys8uB0B2YeEyVhB281pZuQ5Gwik+WO IfE28J5YwRNr/LNLkrTQlyCipSqkth87KTZeyuKs0ikT9WCVR0AV2Lxe1zE0uK+3HE d1oEDndmpeVPQ== Date: Sat, 17 Jun 2023 19:49:11 +0100 From: Jonathan Cameron To: Christophe JAILLET Cc: Lars-Peter Clausen , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-iio@vger.kernel.org Subject: Re: [PATCH 2/2] iio: st_sensors: Remove some redundant includes in st_sensors.h Message-ID: <20230617194911.7963bd6d@jic23-huawei> In-Reply-To: References: <045ca726a9108325a3eaace807a264170895686c.1686600780.git.christophe.jaillet@wanadoo.fr> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org On Mon, 12 Jun 2023 22:13:37 +0200 Christophe JAILLET wrote: > There is no need to include i2c.h and spi/spi.h in st_sensors.h. > Should it be needed, st_sensors_(i2c|spi).h should be used. Agreed these should be dropped from here. But I don't agree with statement that i2c.h and spi/spi.h should be gotten implicitly from st_sensors_i2c.h / st_sensors_spi.h If they are needed the should be included directly in the files where they are needed. Jonathan > > Signed-off-by: Christophe JAILLET > --- > Based on one of my script, this reduces the number of included files from > 573 files to 515 files when compiling drivers/iio/accel/st_accel_buffer.c > --- > include/linux/iio/common/st_sensors.h | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/include/linux/iio/common/st_sensors.h b/include/linux/iio/common/st_sensors.h > index 607c3a89a647..a1d3d57d6d6e 100644 > --- a/include/linux/iio/common/st_sensors.h > +++ b/include/linux/iio/common/st_sensors.h > @@ -10,8 +10,6 @@ > #ifndef ST_SENSORS_H > #define ST_SENSORS_H > > -#include > -#include > #include > #include > #include