video: fbdev: atyfb: Remove assigned but never used variable statements
authorColin Ian King <colin.king@intel.com>
Fri, 10 Sep 2021 16:58:44 +0000 (17:58 +0100)
committerHelge Deller <deller@gmx.de>
Sat, 29 Jan 2022 21:24:26 +0000 (22:24 +0100)
There are a couple of statements where local variables are being assigned
values that are never read because the function returns immediately after
the assignment. Clean up the code by removing them.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Helge Deller <deller@gmx.de>
drivers/video/fbdev/aty/mach64_gx.c

index 9c37e28fb78b5acabadb73751ff4918f6188c920..d06d248300807fc3b142cc86873a26396485707d 100644 (file)
@@ -352,10 +352,8 @@ static int aty_var_to_pll_18818(const struct fb_info *info, u32 vclk_per,
        post_divider = 1;
 
        if (MHz100 > MAX_FREQ_2595) {
-               MHz100 = MAX_FREQ_2595;
                return -EINVAL;
        } else if (MHz100 < ABS_MIN_FREQ_2595) {
-               program_bits = 0;       /* MHz100 = 257 */
                return -EINVAL;
        } else {
                while (MHz100 < MIN_FREQ_2595) {