Page MenuHomeFreeBSD

Remove dead code from radeonkms.
ClosedPublic

Authored by markj on Dec 11 2018, 8:21 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Nov 20, 6:10 PM
Unknown Object (File)
Mon, Nov 18, 3:30 AM
Unknown Object (File)
Sun, Nov 17, 6:25 PM
Unknown Object (File)
Oct 14 2024, 5:55 PM
Unknown Object (File)
Oct 11 2024, 9:13 PM
Unknown Object (File)
Oct 5 2024, 8:52 AM
Unknown Object (File)
Sep 19 2024, 7:21 PM
Unknown Object (File)
Sep 10 2024, 1:28 PM
Subscribers

Details

Summary

This is effectively the closure of the ioctl handler table in
radeon_cp.c. That ioctl table is unused (we use the radeon_kms ioctl
table instead), so there is no way for any of the functions referenced
by the table to be called.

This was motivated by a report of an integer overflow vulnerability in
r600_cp_dispatch_texture() (the multiplication of tex->height and
tex->pitch, which are user-controlled). However, I believe the code
in question cannot get invoked.

Test Plan

I verified that radeonkms.ko still loads (i.e., no missing symbols).

Initially, my test was to simply comment out the radeon_ioctls[] table
and kldload, verifying that the ioctl handlers are indeed dead code.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

markj edited the test plan for this revision. (Show Details)
markj added a reviewer: dumbbell.

Hi!

I suppose the int2float() function comes from one of the removed file, is that right? If yes, could you please add a comment indicating the initial source filename?

This revision now requires changes to proceed.Dec 17 2018, 8:17 AM
  • Add comment indicating the origin of int2float().

Hi!

I suppose the int2float() function comes from one of the removed file, is that right? If yes, could you please add a comment indicating the initial source filename?

Indeed, r600_blit.c. I added a comment.

This revision is now accepted and ready to land.Dec 17 2018, 4:33 PM
This revision was automatically updated to reflect the committed changes.