Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 515749 - Remove warnings from kvm compilation
Remove warnings from kvm compilation
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: kvm (Show other bugs)
5.5
All Linux
low Severity medium
: rc
: ---
Assigned To: Juan Quintela
Lawrence Lim
:
: 513255 513263 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-08-05 11:34 EDT by Juan Quintela
Modified: 2014-03-25 21:00 EDT (History)
7 users (show)

See Also:
Fixed In Version: kvm-83-125.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-03-30 03:57:04 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Use quiet command to have a cleaner command line (5.26 KB, patch)
2009-08-05 11:50 EDT, Juan Quintela
no flags Details | Diff
Remove unused function (1.17 KB, patch)
2009-08-05 11:51 EDT, Juan Quintela
no flags Details | Diff
Remove unused variable (904 bytes, patch)
2009-08-05 11:51 EDT, Juan Quintela
no flags Details | Diff
Right argument number (1.07 KB, patch)
2009-08-05 11:52 EDT, Juan Quintela
no flags Details | Diff
Use right type uint8_t isntead of char (955 bytes, patch)
2009-08-05 11:53 EDT, Juan Quintela
no flags Details | Diff
Use C99 function declaration, not K&R (816 bytes, patch)
2009-08-05 11:54 EDT, Juan Quintela
no flags Details | Diff
Add missing static modifiers (1.37 KB, patch)
2009-08-05 11:57 EDT, Juan Quintela
no flags Details | Diff
Use only one declaration by extern variable (1.39 KB, patch)
2009-08-05 11:57 EDT, Juan Quintela
no flags Details | Diff
Don't redeclare external variable kvm_allowed (1.03 KB, patch)
2009-08-05 11:58 EDT, Juan Quintela
no flags Details | Diff
Put prototype in header (1.56 KB, patch)
2009-08-05 12:01 EDT, Juan Quintela
no flags Details | Diff
Mark another variable static (941 bytes, patch)
2009-08-05 12:02 EDT, Juan Quintela
no flags Details | Diff
mp_state is uint32_t (1.06 KB, patch)
2009-08-05 12:03 EDT, Juan Quintela
no flags Details | Diff
More static functions (938 bytes, patch)
2009-08-05 12:03 EDT, Juan Quintela
no flags Details | Diff
Use uint32_t instead of int (1.07 KB, patch)
2009-08-05 12:05 EDT, Juan Quintela
no flags Details | Diff
Use right type (1.00 KB, patch)
2009-08-05 12:05 EDT, Juan Quintela
no flags Details | Diff
Don't use reason parameter, that don't exist in our version (1.01 KB, patch)
2009-08-05 12:06 EDT, Juan Quintela
no flags Details | Diff
Remove unused variable (1.09 KB, patch)
2009-08-05 12:07 EDT, Juan Quintela
no flags Details | Diff
Another missing prototype (1.72 KB, patch)
2009-08-05 12:08 EDT, Juan Quintela
no flags Details | Diff
var used as uint32_t should be declared as that (981 bytes, patch)
2009-08-05 12:08 EDT, Juan Quintela
no flags Details | Diff
Remove duplicated declaration (927 bytes, patch)
2009-08-05 12:09 EDT, Juan Quintela
no flags Details | Diff
Remove unused variable (910 bytes, patch)
2009-08-05 12:10 EDT, Juan Quintela
no flags Details | Diff
Make local variable static (1.04 KB, patch)
2009-08-05 12:10 EDT, Juan Quintela
no flags Details | Diff
Remove duplicated declaration (915 bytes, patch)
2009-08-05 12:11 EDT, Juan Quintela
no flags Details | Diff
Initialize variable to make gcc happy (2.96 KB, patch)
2009-08-05 12:12 EDT, Juan Quintela
no flags Details | Diff
Use right modifier for time_t (992 bytes, patch)
2009-08-05 12:13 EDT, Juan Quintela
no flags Details | Diff
Remove unused variable (1.11 KB, patch)
2009-08-05 12:13 EDT, Juan Quintela
no flags Details | Diff
Reset handlers have a different type (978 bytes, patch)
2009-08-05 12:14 EDT, Juan Quintela
no flags Details | Diff
Right type nb_sectors (1.03 KB, patch)
2009-08-05 12:15 EDT, Juan Quintela
no flags Details | Diff
Initialize variable to make gcc happy (1.09 KB, patch)
2009-08-05 12:17 EDT, Juan Quintela
no flags Details | Diff
If you change variable types, you also have to change printf (1.18 KB, patch)
2009-08-05 12:18 EDT, Juan Quintela
no flags Details | Diff
Make local variable static (1.70 KB, patch)
2009-08-05 12:19 EDT, Juan Quintela
no flags Details | Diff
Remove unused variable (920 bytes, patch)
2009-08-05 12:20 EDT, Juan Quintela
no flags Details | Diff
perror is defined in <stdio.h> (867 bytes, patch)
2009-08-05 12:21 EDT, Juan Quintela
no flags Details | Diff
Remove duplicated declaration (888 bytes, patch)
2009-08-05 12:22 EDT, Juan Quintela
no flags Details | Diff
Remove duplicated declaration (958 bytes, patch)
2009-08-05 12:24 EDT, Juan Quintela
no flags Details | Diff
Add cast to silence warning (1.18 KB, patch)
2009-08-05 12:26 EDT, Juan Quintela
no flags Details | Diff
Compile qemu with -Werror (941 bytes, patch)
2009-08-05 12:26 EDT, Juan Quintela
no flags Details | Diff
Move several variables after .h that declares them as extern (1.19 KB, patch)
2009-08-05 12:35 EDT, Juan Quintela
no flags Details | Diff


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2010:0271 normal SHIPPED_LIVE Important: kvm security, bug fix and enhancement update 2010-03-29 09:19:48 EDT

  None (edit)
Description Juan Quintela 2009-08-05 11:34:53 EDT
Description of problem:

kvm compilation is too verbose at the moment.  And it introduces lots of warnings.
That makes seeing new warnings when testing/compiling bugs very difficult.  In code inspection for 5.4, I found that one of the warnings was critical and another 3 not very good.  The rest were false positives.

This set of patches fixes all the remaining warnings, and make code inspection/bug fixing/introducing new features easier.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Juan Quintela 2009-08-05 11:50:40 EDT
Created attachment 356335 [details]
Use quiet command to have a cleaner command line
Comment 2 Juan Quintela 2009-08-05 11:51:11 EDT
Created attachment 356336 [details]
Remove unused function
Comment 3 Juan Quintela 2009-08-05 11:51:45 EDT
Created attachment 356337 [details]
Remove unused variable
Comment 4 Juan Quintela 2009-08-05 11:52:52 EDT
Created attachment 356338 [details]
Right argument number
Comment 5 Juan Quintela 2009-08-05 11:53:44 EDT
Created attachment 356339 [details]
Use right type uint8_t isntead of char
Comment 6 Juan Quintela 2009-08-05 11:54:26 EDT
Created attachment 356340 [details]
Use C99 function declaration, not K&R
Comment 7 Juan Quintela 2009-08-05 11:57:06 EDT
Created attachment 356343 [details]
Add missing static modifiers
Comment 8 Juan Quintela 2009-08-05 11:57:54 EDT
Created attachment 356345 [details]
Use only one declaration by extern variable
Comment 9 Juan Quintela 2009-08-05 11:58:59 EDT
Created attachment 356347 [details]
Don't redeclare external variable kvm_allowed
Comment 10 Juan Quintela 2009-08-05 12:01:42 EDT
Created attachment 356348 [details]
Put prototype in header
Comment 11 Juan Quintela 2009-08-05 12:02:26 EDT
Created attachment 356349 [details]
Mark another variable static
Comment 12 Juan Quintela 2009-08-05 12:03:17 EDT
Created attachment 356350 [details]
mp_state is uint32_t
Comment 13 Juan Quintela 2009-08-05 12:03:54 EDT
Created attachment 356351 [details]
More static functions
Comment 14 Juan Quintela 2009-08-05 12:05:28 EDT
Created attachment 356352 [details]
Use uint32_t instead of int
Comment 15 Juan Quintela 2009-08-05 12:05:57 EDT
Created attachment 356353 [details]
Use right type
Comment 16 Juan Quintela 2009-08-05 12:06:48 EDT
Created attachment 356354 [details]
Don't use reason parameter, that don't exist in our version
Comment 17 Juan Quintela 2009-08-05 12:07:32 EDT
Created attachment 356355 [details]
Remove unused variable
Comment 18 Juan Quintela 2009-08-05 12:08:16 EDT
Created attachment 356356 [details]
Another missing prototype
Comment 19 Juan Quintela 2009-08-05 12:08:57 EDT
Created attachment 356357 [details]
var used as uint32_t should be declared as that
Comment 20 Juan Quintela 2009-08-05 12:09:34 EDT
Created attachment 356358 [details]
Remove duplicated declaration
Comment 21 Juan Quintela 2009-08-05 12:10:08 EDT
Created attachment 356359 [details]
Remove unused variable
Comment 22 Juan Quintela 2009-08-05 12:10:46 EDT
Created attachment 356360 [details]
Make local variable static
Comment 23 Juan Quintela 2009-08-05 12:11:29 EDT
Created attachment 356361 [details]
Remove duplicated declaration
Comment 24 Juan Quintela 2009-08-05 12:12:19 EDT
Created attachment 356362 [details]
Initialize variable to make gcc happy
Comment 25 Juan Quintela 2009-08-05 12:13:24 EDT
Created attachment 356363 [details]
Use right modifier for time_t
Comment 26 Juan Quintela 2009-08-05 12:13:57 EDT
Created attachment 356364 [details]
Remove unused variable
Comment 27 Juan Quintela 2009-08-05 12:14:51 EDT
Created attachment 356365 [details]
Reset handlers have a different type
Comment 28 Juan Quintela 2009-08-05 12:15:59 EDT
Created attachment 356366 [details]
Right type nb_sectors
Comment 29 Juan Quintela 2009-08-05 12:17:52 EDT
Created attachment 356368 [details]
Initialize variable to make gcc happy
Comment 30 Juan Quintela 2009-08-05 12:18:35 EDT
Created attachment 356369 [details]
If you change variable types, you also have to change printf
Comment 31 Juan Quintela 2009-08-05 12:19:09 EDT
Created attachment 356370 [details]
Make local variable static
Comment 32 Juan Quintela 2009-08-05 12:20:50 EDT
Created attachment 356371 [details]
Remove unused variable
Comment 33 Juan Quintela 2009-08-05 12:21:33 EDT
Created attachment 356372 [details]
perror is defined in <stdio.h>
Comment 34 Juan Quintela 2009-08-05 12:22:27 EDT
Created attachment 356373 [details]
Remove duplicated declaration
Comment 35 Juan Quintela 2009-08-05 12:24:41 EDT
Created attachment 356374 [details]
Remove duplicated declaration
Comment 36 Juan Quintela 2009-08-05 12:26:13 EDT
Created attachment 356375 [details]
Add cast to silence warning
Comment 37 Juan Quintela 2009-08-05 12:26:54 EDT
Created attachment 356376 [details]
Compile qemu with -Werror
Comment 38 Juan Quintela 2009-08-05 12:35:52 EDT
Created attachment 356378 [details]
Move several variables after .h that declares them as extern
Comment 39 Juan Quintela 2009-09-16 14:27:54 EDT
*** Bug 513255 has been marked as a duplicate of this bug. ***
Comment 40 Juan Quintela 2009-09-16 14:28:31 EDT
*** Bug 513263 has been marked as a duplicate of this bug. ***
Comment 43 Eduardo Habkost 2009-09-22 16:31:35 EDT
Not all warnings were fixed. More patches were posted on virtualist.
Comment 50 Juan Quintela 2010-01-12 08:10:50 EST
Ignore them, please.

That are kvm only parts (not qemu ones) and they are not used anymore on upstream qemu/kvm (they are different).

Thanks for all the tracking.
Comment 53 errata-xmlrpc 2010-03-30 03:57:04 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2010-0271.html

Note You need to log in before you can comment on or make changes to this bug.