diff options
author | Alan Cox <alan@linux.intel.com> | 2011-07-15 17:32:13 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-07-15 19:05:06 +0200 |
commit | bd7b9f91ddc2d08381a853bd33b3ce7d0012b1df (patch) | |
tree | 59eeafe297d904397a3ce11bdc002874e4f921dc /drivers/staging/gma500/framebuffer.c | |
parent | c5c44531ad00ed87078e799f0932c220031aa1c9 (diff) |
gma500: Move the 2D operations into DRM
We currently have a test hack framebuffer mode ioctl, turn that into a DRM
interface.
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/gma500/framebuffer.c')
-rw-r--r-- | drivers/staging/gma500/framebuffer.c | 25 |
1 files changed, 1 insertions, 24 deletions
diff --git a/drivers/staging/gma500/framebuffer.c b/drivers/staging/gma500/framebuffer.c index 76b986f4180d..d890a5091cd2 100644 --- a/drivers/staging/gma500/framebuffer.c +++ b/drivers/staging/gma500/framebuffer.c @@ -200,30 +200,7 @@ static int psbfb_mmap(struct fb_info *info, struct vm_area_struct *vma) static int psbfb_ioctl(struct fb_info *info, unsigned int cmd, unsigned long arg) { - struct psb_fbdev *fbdev = info->par; - struct psb_framebuffer *psbfb = &fbdev->pfb; - struct drm_device *dev = psbfb->base.dev; - struct drm_psb_private *dev_priv = dev->dev_private; - u32 __user *p = (u32 __user *)arg; - u32 l; - u32 buf[32]; - switch (cmd) { - case 0x12345678: - if (!capable(CAP_SYS_RAWIO)) - return -EPERM; - if (!dev_priv->ops->accel_2d) - return -EOPNOTSUPP; - if (get_user(l, p)) - return -EFAULT; - if (l > 32) - return -EMSGSIZE; - if (copy_from_user(buf, p + 1, l * sizeof(u32))) - return -EFAULT; - psbfb_2d_submit(dev_priv, buf, l); - return 0; - default: - return -ENOTTY; - } + return -ENOTTY; } static struct fb_ops psbfb_ops = { |