Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e73f88af authored by Dave Airlie's avatar Dave Airlie
Browse files

drm: add cap bit to denote if dumb ioctl is available or not.



This allows libkms to make an easier decision.

Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent 9f35421e
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -275,6 +275,14 @@ int drm_getcap(struct drm_device *dev, void *data, struct drm_file *file_priv)
	struct drm_get_cap *req = data;

	req->value = 0;
	switch (req->capability) {
	case DRM_CAP_DUMB_BUFFER:
		if (dev->driver->dumb_create)
			req->value = 1;
		break;
	default:
		return -EINVAL;
	}
	return 0;
}

+2 −0
Original line number Diff line number Diff line
@@ -752,6 +752,8 @@ struct drm_event_vblank {
	__u32 reserved;
};

#define DRM_CAP_DUMB_BUFFER 0x1

/* typedef area */
#ifndef __KERNEL__
typedef struct drm_clip_rect drm_clip_rect_t;