@@ -372,8 +372,6 @@ static int linehandle_create(struct gpio_device *gdev, void __user *ip)
goto out_free_lh;
}
- gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED);
-
dev_dbg(&gdev->dev, "registered chardev handle for line %d\n",
offset);
}
@@ -1842,8 +1840,6 @@ static int linereq_create(struct gpio_device *gdev, void __user *ip)
lr->lines[i].edflags = edflags;
- gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED);
-
dev_dbg(&gdev->dev, "registered chardev handle for line %d\n",
offset);
}
@@ -2234,8 +2230,6 @@ static int lineevent_create(struct gpio_device *gdev, void __user *ip)
if (ret)
goto out_free_le;
- gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED);
-
irq = gpiod_to_irq(desc);
if (irq <= 0) {
ret = -ENODEV;
@@ -2345,6 +2345,8 @@ static int gpiod_request_commit(struct gpio_desc *desc, const char *label)
if (ret)
goto out_clear_bit;
+ gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED);
+
return 0;
out_clear_bit:
@@ -4365,8 +4367,6 @@ struct gpio_desc *gpiod_find_and_request(struct device *consumer,
return ERR_PTR(ret);
}
- gpiod_line_state_notify(desc, GPIO_V2_LINE_CHANGED_REQUESTED);
-
return desc;
}