Skip to content

Commit b622051

Browse files
cjd8jic23
authored andcommitted
iio: light: opt3001: make headers conform to iwyu
Remove kernel.h proxy header, device.h, irq.h, slab.h as they are unnecessary and add missing headers (array_size.h, dev_printk.h, errno.h, jiffies.h, wait.h) to enforce IWYU principle and reduce transitive dependencies. Also, replace bitops.h with bits.h as only the BIT() macro is used. Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
1 parent 243a738 commit b622051

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

drivers/iio/light/opt3001.c

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,19 @@
88
* Based on previous work from: Felipe Balbi <balbi@ti.com>
99
*/
1010

11-
#include <linux/bitops.h>
11+
#include <linux/array_size.h>
12+
#include <linux/bits.h>
1213
#include <linux/delay.h>
13-
#include <linux/device.h>
14+
#include <linux/dev_printk.h>
15+
#include <linux/errno.h>
1416
#include <linux/i2c.h>
1517
#include <linux/interrupt.h>
16-
#include <linux/irq.h>
17-
#include <linux/kernel.h>
18-
#include <linux/module.h>
18+
#include <linux/jiffies.h>
1919
#include <linux/mod_devicetable.h>
20+
#include <linux/module.h>
2021
#include <linux/mutex.h>
21-
#include <linux/slab.h>
2222
#include <linux/types.h>
23+
#include <linux/wait.h>
2324

2425
#include <linux/iio/events.h>
2526
#include <linux/iio/iio.h>

0 commit comments

Comments
 (0)