Re: [PATCH] drm/radeon: Update radeon_get_vblank_counter_kms()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 17, 2015 at 03:35:50PM +0900, Michel Dänzer wrote:
> On 16.12.2015 23:31, Thierry Reding wrote:
> > 
> > -	if (crtc < 0 || crtc >= rdev->num_crtc) {
> > -		DRM_ERROR("Invalid crtc %d\n", crtc);
> > +	if (pipe < 0 || pipe >= rdev->num_crtc) {
> > +		DRM_ERROR("Invalid crtc %u\n", pipe);
> 
> Does it still make sense to test for < 0? Doesn't that generate a
> compiler warning?

I didn't see a compiler warning in my build tests, but you're right,
it's not necessary to check for that because it can't be true. I'll
respin with that fixed up.

> Also, I don't really get the point of the crtc => pipe rename here...

This is primarily for consistency. That way we can reserve "pipe" for
the unsigned integers that denote the DRM index of the CRTC, and keep
"crtc" for cases where we deal with struct drm_crtc objects.

Thierry

Attachment: signature.asc
Description: PGP signature

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel

[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux