Skip to contentSkip to conversation

gpiolib: Update header block in gpiolib-cdev.h

PATCH In review Andy Shevchenko 2 participants 3 messages Oct 5, 2020 – Oct 7, 2020 GPIO

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gpiolib: Update header block in gpiolib-cdev.h

The dev_t is defined in types.h while struct gpio_device forward declaration is missed. Take into account above and update header block in gpiolib-cdev.h.

---
 drivers/gpio/gpiolib-cdev.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpio/gpiolib-cdev.h +3 -1
index 973578e7ad10..b42644cbffb8 100644
@@ -3,7 +3,9 @@
 #ifndef GPIOLIB_CDEV_H
 #define GPIOLIB_CDEV_H
 
-#include <linux/device.h>
+#include <linux/types.h>
+
+struct gpio_device;
 
 int gpiolib_cdev_register(struct gpio_device *gdev, dev_t devt);
 void gpiolib_cdev_unregister(struct gpio_device *gdev);
Signature · 1 line
2.28.0
#1 lore raw
Quoted 4 lines · Andy Shevchenko

The dev_t is defined in types.h while struct gpio_device forward declaration is missed. Take into account above and update header block in gpiolib-cdev.h.

Patch applied with some fuzzing, thanks Andy!

Yours,
Linus Walleij

#2 lore raw
Quoted 9 lines · Linus Walleij
Quoted 4 lines · Andy Shevchenko

The dev_t is defined in types.h while struct gpio_device forward declaration is missed. Take into account above and update header block in gpiolib-cdev.h.

Patch applied with some fuzzing, thanks Andy!

I noticed I do not need to fuzz it if I simply apply it to fixes....

Yours,
Linus Walleij