Skip to content

Commit 5bef1b7

Browse files
andredlag-linaro
authored andcommitted
mfd: sec: Update includes to add missing and remove superfluous ones
This driver misses to include some of the respective headers of some of the APIs used. It also includes headers that aren't needed (e.g. due to previous driver rework where includes weren't updated). It is good practice to directly include all headers used, which avoids implicit dependencies and spurious build breakage if someone rearranged headers, as this could cause the implicit includes to be dropped. Include the relevant headers explicitly and drop superfluous ones. Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: André Draszik <andre.draszik@linaro.org> Link: https://lore.kernel.org/r/20250409-s2mpg10-v4-6-d66d5f39b6bf@linaro.org Signed-off-by: Lee Jones <lee@kernel.org>
1 parent 271dc4f commit 5bef1b7

2 files changed

Lines changed: 7 additions & 5 deletions

File tree

drivers/mfd/sec-core.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
// Copyright (c) 2012 Samsung Electronics Co., Ltd
44
// http://www.samsung.com
55

6+
#include <linux/device.h>
67
#include <linux/err.h>
78
#include <linux/i2c.h>
8-
#include <linux/init.h>
99
#include <linux/interrupt.h>
1010
#include <linux/mfd/core.h>
1111
#include <linux/mfd/samsung/core.h>
@@ -17,13 +17,12 @@
1717
#include <linux/mfd/samsung/s2mps15.h>
1818
#include <linux/mfd/samsung/s2mpu02.h>
1919
#include <linux/mfd/samsung/s5m8767.h>
20+
#include <linux/mod_devicetable.h>
2021
#include <linux/module.h>
21-
#include <linux/moduleparam.h>
22-
#include <linux/mutex.h>
2322
#include <linux/of.h>
23+
#include <linux/pm.h>
2424
#include <linux/pm_runtime.h>
2525
#include <linux/regmap.h>
26-
#include <linux/slab.h>
2726

2827
static const struct mfd_cell s5m8767_devs[] = {
2928
{ .name = "s5m8767-pmic", },

drivers/mfd/sec-irq.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@
33
// Copyright (c) 2011-2014 Samsung Electronics Co., Ltd
44
// http://www.samsung.com
55

6-
#include <linux/device.h>
6+
#include <linux/array_size.h>
7+
#include <linux/build_bug.h>
8+
#include <linux/dev_printk.h>
9+
#include <linux/export.h>
710
#include <linux/interrupt.h>
811
#include <linux/irq.h>
912
#include <linux/mfd/samsung/core.h>

0 commit comments

Comments
 (0)