Skip to content

Commit 7c1cf55

Browse files
Yang Librgl
authored andcommitted
gpio: idt3243x: Fix an ignored error return from platform_get_irq()
The return from the call to platform_get_irq() is int, it can be a negative error code, however this is being assigned to an unsigned int variable 'parent_irq', so making 'parent_irq' an int. Eliminate the following coccicheck warning: ./drivers/gpio/gpio-idt3243x.c:167:6-16: WARNING: Unsigned expression compared with zero: parent_irq < 0 Reported-by: Abaci Robot <[email protected]> Fixes: 30fee1d ("gpio: idt3243x: Fix IRQ check in idt_gpio_probe") Signed-off-by: Yang Li <[email protected]> Signed-off-by: Bartosz Golaszewski <[email protected]>
1 parent 30fee1d commit 7c1cf55

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpio/gpio-idt3243x.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ static int idt_gpio_probe(struct platform_device *pdev)
132132
struct device *dev = &pdev->dev;
133133
struct gpio_irq_chip *girq;
134134
struct idt_gpio_ctrl *ctrl;
135-
unsigned int parent_irq;
135+
int parent_irq;
136136
int ngpios;
137137
int ret;
138138

0 commit comments

Comments
 (0)