lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1a3d30bc-130c-49ce-93ed-d380d5159dfa@gmx.de>
Date: Thu, 25 Apr 2024 12:05:20 +0200
From: Helge Deller <deller@....de>
To: Cai Xinchen <caixinchen1@...wei.com>, adaplas@...il.com,
 fullwaywang@...look.com
Cc: linux-fbdev@...r.kernel.org, dri-devel@...ts.freedesktop.org,
 linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH -next] fbdev: savage: Handle err return when
 savagefb_check_var failed

On 4/16/24 08:51, Cai Xinchen wrote:
> The commit 04e5eac8f3ab("fbdev: savage: Error out if pixclock equals zero")
> checks the value of pixclock to avoid divide-by-zero error. However
> the function savagefb_probe doesn't handle the error return of
> savagefb_check_var. When pixclock is 0, it will cause divide-by-zero error.
>
> Fixes: 04e5eac8f3ab ("fbdev: savage: Error out if pixclock equals zero")
> Signed-off-by: Cai Xinchen <caixinchen1@...wei.com>
> Cc: stable@...r.kernel.org
> ---
>   drivers/video/fbdev/savage/savagefb_driver.c | 5 ++++-
>   1 file changed, 4 insertions(+), 1 deletion(-)

applied.
Thanks!
Helge



>
> diff --git a/drivers/video/fbdev/savage/savagefb_driver.c b/drivers/video/fbdev/savage/savagefb_driver.c
> index ebc9aeffdde7..ac41f8f37589 100644
> --- a/drivers/video/fbdev/savage/savagefb_driver.c
> +++ b/drivers/video/fbdev/savage/savagefb_driver.c
> @@ -2276,7 +2276,10 @@ static int savagefb_probe(struct pci_dev *dev, const struct pci_device_id *id)
>   	if (info->var.xres_virtual > 0x1000)
>   		info->var.xres_virtual = 0x1000;
>   #endif
> -	savagefb_check_var(&info->var, info);
> +	err = savagefb_check_var(&info->var, info);
> +	if (err)
> +		goto failed;
> +
>   	savagefb_set_fix(info);
>
>   	/*


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ