Linux IIO development
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Joshua Crofts <joshua.crofts1@gmail.com>
Cc: "David Lechner" <dlechner@baylibre.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>, "Crt Mori" <cmo@melexis.com>,
	"Puranjay Mohan" <puranjay@kernel.org>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 04/14] iio: temperature: ltc2983: make headers conform to IWYU
Date: Sun, 23 Aug 2026 18:52:19 +0100	[thread overview]
Message-ID: <20260823185219.222c7990@jic23-huawei> (raw)
In-Reply-To: <20260822-kernel-header-removal-v1-4-ee31b124be11@gmail.com>

On Sat, 22 Aug 2026 10:02:31 +0200
Joshua Crofts <joshua.crofts1@gmail.com> wrote:

> Remove the catch-all kernel.h header and add the missing headers to
> enforce IWYU.
> 
> Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com>
> ---
> Header changes explained:
> Added:
> - <asm/div64.h>: for div64 functions
> - <linux/array_size.h>: for ARRAY_SIZE()
> - <linux/bits.h>: for GENMASK() and BIT() macros
> - <linux/mutex.h>: for struct mutex and mutex_lock/unlock
> - <linux/types.h>: for fixed-width integer types (u8, u16, etc.)
> Removed:
> - <linux/errno.h>: not directly used in this driver
> - <linux/kernel.h>: catch-all header no longer needed
> ---
>  drivers/iio/temperature/ltc2983.c | 8 ++++++--
>  1 file changed, 6 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/iio/temperature/ltc2983.c b/drivers/iio/temperature/ltc2983.c
> index fe9eec3058d4..0b1b442bb133 100644
> --- a/drivers/iio/temperature/ltc2983.c
> +++ b/drivers/iio/temperature/ltc2983.c
> @@ -5,22 +5,26 @@
>   *
>   * Copyright 2019 Analog Devices Inc.
>   */
> +
> +#include <linux/array_size.h>
>  #include <linux/bitfield.h>
> +#include <linux/bits.h>
>  #include <linux/completion.h>
>  #include <linux/device.h>
>  #include <linux/err.h>
> -#include <linux/errno.h>
> -#include <linux/kernel.h>
>  #include <linux/interrupt.h>
>  #include <linux/list.h>
>  #include <linux/module.h>
> +#include <linux/mutex.h>
>  #include <linux/property.h>
>  #include <linux/regmap.h>
>  #include <linux/regulator/consumer.h>
>  #include <linux/spi/spi.h>
> +#include <linux/types.h>
>  #include <linux/unaligned.h>
>  
>  #include <asm/byteorder.h>
> +#include <asm/div64.h>

I think we normally use linux/math64.h for that one.


>  
>  #include <linux/iio/iio.h>
>  
> 


  reply	other threads:[~2026-08-23 17:52 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-22  8:02 [PATCH 00/14] iio: temperature: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 01/14] iio: temperature: iqs620at-temp: separate IIO header from others Joshua Crofts
2026-08-22  8:02 ` [PATCH 02/14] iio: temperature: iqs620at-temp: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 03/14] iio: temperature: ltc2983: reorder headers Joshua Crofts
2026-08-22  8:02 ` [PATCH 04/14] iio: temperature: ltc2983: make headers conform to IWYU Joshua Crofts
2026-08-23 17:52   ` Jonathan Cameron [this message]
2026-08-24  8:27     ` Andy Shevchenko
2026-08-24  8:36       ` Joshua Crofts
2026-08-22  8:02 ` [PATCH 05/14] iio: temperature: mlx90632: sort headers alphabetically Joshua Crofts
2026-08-23 17:54   ` Jonathan Cameron
2026-08-22  8:02 ` [PATCH 06/14] iio: temperature: mlx90632: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 07/14] iio: temperature: mlx90635: sort headers alphabetically Joshua Crofts
2026-08-22  8:02 ` [PATCH 08/14] iio: temperature: mlx90635: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 09/14] iio: temperature: tmp117: sort headers alphabetically Joshua Crofts
2026-08-22  8:02 ` [PATCH 10/14] iio: temperature: tmp117: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 11/14] iio: temperature: tsys01: reorder headers Joshua Crofts
2026-08-23 17:58   ` Jonathan Cameron
2026-08-22  8:02 ` [PATCH 12/14] iio: temperature: tsys01: make headers conform to IWYU Joshua Crofts
2026-08-22  8:02 ` [PATCH 13/14] iio: temperature: tsys02d: reorder headers Joshua Crofts
2026-08-22  8:02 ` [PATCH 14/14] iio: temperature: tsys02d: make headers conform to IWYU Joshua Crofts
2026-08-22  8:17 ` [PATCH 00/14] iio: temperature: " Joshua Crofts

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260823185219.222c7990@jic23-huawei \
    --to=jic23@kernel.org \
    --cc=andy@kernel.org \
    --cc=cmo@melexis.com \
    --cc=dlechner@baylibre.com \
    --cc=joshua.crofts1@gmail.com \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nuno.sa@analog.com \
    --cc=puranjay@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox