[PATCH libdrm 2/2] xf86drm: Handle unrecognized subsystems safely in drmGetDevice[s]()

Emil Velikov emil.l.velikov at gmail.com
Fri Oct 16 15:27:10 PDT 2015


On 16 October 2015 at 23:11, Matt Roper <matthew.d.roper at intel.com> wrote:
> Both drmGetDevice() and drmGetDevices() currently print a warning when
> they encounter an unknown (non-PCI) subsystem type for a device node,
> but they still proceed to assume that the drmDevicePtr was initialized
> and try to add it to the local device array.  Add a 'continue' to the
> error case handling to bypass the rest of the processing for devices we
> can't handle.
>
> Cc: Emil Velikov <emil.l.velikov at gmail.com>
Looks like a left over as I moved the realloc() after the switch statement.

For the series:
Reviewed-by: Emil Velikov <emil.l.velikov at gmail.com>

Out of curiosity did you notice these while going through the code or
do you actually have (work on) platform drm devices ? Can I volunteer
you to add support for them ;-)

Thanks
Emil


More information about the dri-devel mailing list