diff options
| author | Bastien Curutchet (Schneider Electric) <bastien.curutchet@bootlin.com> | 2025-11-20 10:12:01 +0100 |
|---|---|---|
| committer | Paolo Abeni <pabeni@redhat.com> | 2025-11-25 12:32:41 +0100 |
| commit | 9e059305be41a5bd27e03458d8333cf30d70be34 (patch) | |
| tree | 6afcaf2905b5ce9f82594d4dfa892d6dc8fb1211 /tools/lib/python/kdoc/kdoc_re.py | |
| parent | 7b3c09e1667977edee11de94a85e2593a7c15e87 (diff) | |
net: dsa: microchip: ptp: Fix checks on irq_find_mapping()
irq_find_mapping() returns a positive IRQ number or 0 if no IRQ is found
but it never returns a negative value. However, during the PTP IRQ setup,
we verify that its returned value isn't negative.
Fix the irq_find_mapping() check to enter the error path when 0 is
returned. Return -EINVAL in such case.
Cc: stable@vger.kernel.org
Fixes: cc13ab18b201 ("net: dsa: microchip: ptp: enable interrupt for timestamping")
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Bastien Curutchet (Schneider Electric) <bastien.curutchet@bootlin.com>
Link: https://patch.msgid.link/20251120-ksz-fix-v6-2-891f80ae7f8f@bootlin.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'tools/lib/python/kdoc/kdoc_re.py')
0 files changed, 0 insertions, 0 deletions
