diff options
| author | Luo Yifan <[email protected]> | 2024-11-07 01:59:36 +0000 |
|---|---|---|
| committer | Mark Brown <[email protected]> | 2024-11-07 13:07:17 +0000 |
| commit | 23569c8b314925bdb70dd1a7b63cfe6100868315 (patch) | |
| tree | 63f4de30ae4aeac34558c1acd924bbb874692e2e /drivers/usb/cdns3/cdns3-ti.c | |
| parent | ASoC: stm: Prevent potential division by zero in stm32_sai_mclk_round_rate() (diff) | |
| download | kernel-23569c8b314925bdb70dd1a7b63cfe6100868315.tar.gz kernel-23569c8b314925bdb70dd1a7b63cfe6100868315.zip | |
ASoC: stm: Prevent potential division by zero in stm32_sai_get_clk_div()
This patch checks if div is less than or equal to zero (div <= 0). If
div is zero or negative, the function returns -EINVAL, ensuring the
division operation is safe to perform.
Signed-off-by: Luo Yifan <[email protected]>
Reviewed-by: Olivier Moysan <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-ti.c')
0 files changed, 0 insertions, 0 deletions
