Bug 499947 - [r300] Uninitialized bytes during setup
Summary: [r300] Uninitialized bytes during setup
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: mesa
Version: 11
Hardware: x86_64
OS: Linux
low
low
Target Milestone: ---
Assignee: Adam Jackson
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-05-09 12:04 UTC by Thomas Zimmermann
Modified: 2018-04-11 07:11 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-06-28 12:27:54 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Fixes valgrind warning (480 bytes, patch)
2009-05-09 12:04 UTC, Thomas Zimmermann
no flags Details | Diff

Description Thomas Zimmermann 2009-05-09 12:04:51 UTC
Created attachment 343205 [details]
Fixes valgrind warning

Description of problem:

Valgrind complains about uninitalized bytes during the driver is initialized. The warning reads something like 

==9224== Syscall param ioctl(generic) points to uninitialised byte(s)
==9224==    at 0x3970AD87B7: ioctl (in /lib64/libc-2.9.90.so)
==9224==    by 0x3993203102: drmIoctl (in /usr/lib64/libdrm.so.2.4.0)
==9224==    by 0x399320334B: drmCommandWriteRead (in /usr/lib64/libdrm.so.2.4.0)
==9224==    by 0x52AE410: radeonGetParam (radeon_screen.c:272)
==9224==    by 0x52AF1D9: radeonInitDriver (radeon_screen.c:798)
==9224==    by 0x52AF9CD: radeonInitScreen (radeon_screen.c:1428)
==9224==    by 0x52AA42B: driCreateNewScreen (dri_util.c:743)
==9224==    by 0x4C5C438: driCreateScreen (dri_glx.c:387)
==9224==    by 0x4C41DC0: __glXInitialize (glxext.c:619)
==9224==    by 0x4C3E29C: GetGLXPrivScreenConfig (glxcmds.c:183)
==9224==    by 0x4C3EDF6: glXChooseVisual (glxcmds.c:1304)
==9224==    by 0x401ACF: make_window.clone.0 (glxgears.c:515)
==9224==  Address 0x7fefffa24 is on thread 1's stack
==9224==  Uninitialised value was created by a stack allocation
==9224==    at 0x52AE3A8: radeonGetParam (radeon_screen.c:250)
==9224== Warning: set address range perms: large range [0x5ae2000, 0x15ad2000) (noaccess)

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

mesa-dri-drivers-7.5-0.9.fc11

How reproducible:

This should happen with every GL application on X86-64.

Steps to Reproduce:
1. valgrind --track-origins=yes glxgears
  
Actual results:

The warning shown above.

Expected results:

No warning.

Additional info:

These uninitialized bytes come from padding within struct drm_radeon_getparam_t from libdrm. pahole says

struct drm_radeon_getparam {
        int                        param;                /*     0     4 */
        /* XXX 4 bytes hole, try to pack */
        void *                     value;                /*     8     8 */

        /* size: 16, cachelines: 1, members: 2 */
        /* sum members: 12, holes: 1, sum holes: 4 */
        /* last cacheline: 16 bytes */
};      /* definitions: 3 */

A patch is attached which simply memsets all bytes to 0. However if someone is ever going to break the ABI of libdrm, it might might be a good idea to rearrange the structures layout as well.

Comment 1 Bug Zapper 2009-06-09 15:31:44 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle.
Changing version to '11'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 2 Matěj Cepl 2009-11-05 18:28:56 UTC
Since this bugzilla report was filed, there have been several major updates in various components of the Xorg system, which may have resolved this issue. Users who have experienced this problem are encouraged to upgrade their system to the latest version of their packages. For packages from updates-testing repository you can use command

yum upgrade --enablerepo='*-updates-testing'

Alternatively, you can also try to test whether this bug is reproducible with the upcoming Fedora 12 distribution by downloading LiveMedia of F12 Beta available at http://alt.fedoraproject.org/pub/alt/nightly-composes/ . By using that you get all the latest packages without need to install anything on your computer. For more information on using LiveMedia take a look at https://fedoraproject.org/wiki/FedoraLiveCD .

Please, if you experience this problem on the up-to-date system, let us now in the comment for this bug, or whether the upgraded system works for you.

If you won't be able to reply in one month, I will have to close this bug as INSUFFICIENT_DATA. Thank you.

[This is a bulk message for all open Fedora Rawhide Xorg-related bugs. I'm adding myself to the CC list for each bug, so I'll see any comments you make after this and do my best to make sure every issue gets proper attention.]

Comment 3 Matěj Cepl 2010-02-26 12:21:06 UTC
Could you please reply to the previous question? If you won't reply in one month, I will have to close this bug as INSUFFICIENT_DATA. Thank you.

[Note please, that this is machine generated comment for large amount of bugs; due to some technical issues, it is possible we've missed some of the responses -- it is happens, please, just a make a comment about that; that we will see. Thank you]

Comment 4 Ray Strode [halfline] 2010-04-13 16:31:50 UTC
This isn't fixed yet.  Cleanup patch should probably get moved upstream.

Comment 5 Bug Zapper 2010-04-27 14:14:37 UTC
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 6 Bug Zapper 2010-06-28 12:27:54 UTC
Fedora 11 changed to end-of-life (EOL) status on 2010-06-25. Fedora 11 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


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