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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAFH1YnN8v+8UH3RvaeT7TJEdtEyxhoBA-ZEMk-mRFWNad8e9Jw@mail.gmail.com>
Date:   Mon, 13 Jan 2020 10:43:14 +0800
From:   Zhenzhong Duan <zhenzhong.duan@...il.com>
To:     Borislav Petkov <bp@...en8.de>
Cc:     Arvind Sankar <nivedita@...m.mit.edu>,
        linux-kernel@...r.kernel.org, x86@...nel.org,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>,
        "H. Peter Anvin" <hpa@...or.com>,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        "Rafael J. Wysocki" <rafael.j.wysocki@...el.com>
Subject: Re: [PATCH v2] x86/boot/KASLR: Fix unused variable warning

On Fri, Jan 10, 2020 at 5:00 PM Borislav Petkov <bp@...en8.de> wrote:
>
> On Fri, Jan 10, 2020 at 10:27:02AM +0800, Zhenzhong Duan wrote:
> > Yes. Will you send this formally?
>
> And then a flood of fix-this-trivial-warning patches ensues?
>
> You should know that they have the lowest prio when it comes to looking
> at them.
I see.
Just tried Arvind's patch, result is not that bad. Below are all
warnings during build:
In fact, only gop.c and kaslr.c have compile warning.

/root/kernel/drivers/firmware/efi/libstub/gop.c: In function ‘efi_setup_gop’:
/root/kernel/drivers/firmware/efi/libstub/gop.c:174:18: warning:
‘pixel_format’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  setup_pixel_info(si, pixels_per_scan_line, pixel_info, pixel_format);
                  ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:97:6: note:
‘pixel_format’ was declared here
  int pixel_format;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:166:45: warning:
‘fb_base’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  ext_lfb_base = (u64)(unsigned long)fb_base >> 32;
                                             ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:95:6: note: ‘fb_base’
was declared here
  u64 fb_base;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:174:18: warning:
‘pixels_per_scan_line’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  setup_pixel_info(si, pixels_per_scan_line, pixel_info, pixel_format);
                  ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:93:6: note:
‘pixels_per_scan_line’ was declared here
  u32 pixels_per_scan_line;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:163:17: warning:
‘height’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  si->lfb_height = height;
                 ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:92:13: note: ‘height’
was declared here
  u16 width, height;
             ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:162:16: warning:
‘width’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  si->lfb_width = width;
                ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:92:6: note: ‘width’
was declared here
  u16 width, height;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:271:18: warning:
‘pixel_format’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  setup_pixel_info(si, pixels_per_scan_line, pixel_info, pixel_format);
                  ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:194:6: note:
‘pixel_format’ was declared here
  int pixel_format;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:263:45: warning:
‘fb_base’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  ext_lfb_base = (u64)(unsigned long)fb_base >> 32;
                                             ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:192:6: note: ‘fb_base’
was declared here
  u64 fb_base;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:271:18: warning:
‘pixels_per_scan_line’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  setup_pixel_info(si, pixels_per_scan_line, pixel_info, pixel_format);
                  ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:190:6: note:
‘pixels_per_scan_line’ was declared here
  u32 pixels_per_scan_line;
      ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:260:17: warning:
‘height’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  si->lfb_height = height;
                 ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:189:13: note: ‘height’
was declared here
  u16 width, height;
             ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:259:16: warning:
‘width’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
  si->lfb_width = width;
                ^
/root/kernel/drivers/firmware/efi/libstub/gop.c:189:6: note: ‘width’
was declared here
  u16 width, height;

/root/kernel/arch/x86/boot/compressed/kaslr.c: In function ‘process_mem_region’:
/root/kernel/arch/x86/boot/compressed/kaslr.c:698:6: warning: unused
variable ‘i’ [-Wunused-variable]
  int i;

Regards
Zhenzhong

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ