summaryrefslogtreecommitdiff
path: root/shared-core
AgeCommit message (Expand)Author
2007-12-15Revert "nouveau: nv30: missing ramin init, does it brake other hw?"Patrice Mandin
2007-12-13Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into mode...Alan Hourihane
2007-12-11Make relocation validate client computed values when debuggingKeith Packard
2007-12-11i915: wait for buffer idle before writing relocationsKeith Packard
2007-12-11Bump driver minor for relocation optimzationsKeith Packard
2007-12-11Allow relocation to be skipped when buffers don't move.Keith Packard
2007-12-11Merge branch 'master' of ssh://git.freedesktop.org/git/mesa/drm into modesett...Dave Airlie
2007-12-11modesetting: fixup property setting and add connector propertyDave Airlie
2007-12-11modesetting: add dpms property and initial settable property ioctlDave Airlie
2007-12-10Merge branch 'master' into r500-supportDave Airlie
2007-12-08mach64: comment bus master / ring buffer behavior and securityJosé Fonseca
2007-12-08radeon_ms: fix pll computation to follow hw constraintJerome Glisse
2007-12-07Fix pipe<->plane mapping vs. vblank handling (again)Jesse Barnes
2007-12-06radeon_ms: update to lastest fb changeJerome Glisse
2007-12-06Merge commit 'origin/modesetting-101' into modesetting-radeonJerome Glisse
2007-12-06radeon_ms: avoid to unintialize things which haven't been initializedJerome Glisse
2007-12-06add property blobs and edid reporting supportDave Airlie
2007-12-05mach64: make buffer emission macros normal functionsJosé Fonseca
2007-12-05mach64: use utf-8José Fonseca
2007-12-05Remove references to the sarea_priv perf_boxes field.Kristian Høgsberg
2007-12-05more WIP on blobs..Dave Airlie
2007-12-05arrgggh.. make all ioctl structs 32/64-bit compatible hopefully.Dave Airlie
2007-12-04radeon_ms: radeon modesetting first commit.Jerome Glisse
2007-12-03finish of mode add/remove, just have attach/detach modesDave Airlie
2007-12-03modesetting API change for removing mode ids and making modes per output.Dave Airlie
2007-12-02bsd: Replace other occurrences of msleep with mtx_sleepRobert Noland
2007-12-01Clarify order of operationsRobert Noland
2007-12-01DRM_DEBUG already prints the function name.Robert Noland
2007-12-01drm: Add _DRM_DRIVER map flag.Robert Noland
2007-11-30nouveau: Properly identify NV40 and NV44 generation.Maarten Maathuis
2007-11-29Beside the emitted warning, the added cast (u64 -> unsigned) strips outJiri Slaby
2007-11-29drm: more cleanupsDave Airlie
2007-11-28i965: oops force mi batchbuffer startDave Airlie
2007-11-27drm/modesetting: add initial gettable properites code.Dave Airlie
2007-11-27r500: add a bunch of all r5xx pci ids..Dave Airlie
2007-11-22Merge branch 'origin' into modesetting-101Dave Airlie
2007-11-22drm: major whitespace/coding style realignment with kernelDave Airlie
2007-11-22i915: add context handle to superioctl structDave Airlie
2007-11-22r500: add pci id for X1650Dave Airlie
2007-11-21r500: suggestion from glisse to not add cliprect offset on r5xxDave Airlie
2007-11-20radeon: add initial r5xx supportDave Airlie
2007-11-19Fix capitalization of __linux__ define.Eric Anholt
2007-11-18Bug #13233: Fix build on FreeBSD.Robert Noland
2007-11-18radeon: refactor out the fb/agp location read/write.Dave Airlie
2007-11-16nouveau: also mention the number of succcessfully copied bios bytes.Stephane Marchesin
2007-11-15nouveau: be verbose about PPC bios for now.Stephane Marchesin
2007-11-15nouveau: revert the nv34 context size change, it was not the culprit after all.Stephane Marchesin
2007-11-15nouveau: use get_property instead of of_get_property on pre-2.6.22 kernels.Stephane Marchesin
2007-11-15modes: pass type to userspace for preferred showingDave Airlie
2007-11-15Merge branch 'master' into modesetting-101Dave Airlie
opt">) || __put_user(batchbuffer32.num_cliprects, &batchbuffer->num_cliprects) || __put_user((int __user *)(unsigned long)batchbuffer32.cliprects, &batchbuffer->cliprects)) return -EFAULT; return drm_ioctl(file->f_dentry->d_inode, file, DRM_IOCTL_I915_BATCHBUFFER, (unsigned long) batchbuffer); } typedef struct _drm_i915_cmdbuffer32 { u32 buf; /* pointer to userspace command buffer */ int sz; /* nr bytes in buf */ int DR1; /* hw flags for GFX_OP_DRAWRECT_INFO */ int DR4; /* window origin for GFX_OP_DRAWRECT_INFO */ int num_cliprects; /* mulitpass with multiple cliprects? */ u32 cliprects; /* pointer to userspace cliprects */ } drm_i915_cmdbuffer32_t; static int compat_i915_cmdbuffer(struct file *file, unsigned int cmd, unsigned long arg) { drm_i915_cmdbuffer32_t cmdbuffer32; drm_i915_cmdbuffer_t __user *cmdbuffer; if (copy_from_user (&cmdbuffer32, (void __user *)arg, sizeof(cmdbuffer32))) return -EFAULT; cmdbuffer = compat_alloc_user_space(sizeof(*cmdbuffer)); if (!access_ok(VERIFY_WRITE, cmdbuffer, sizeof(*cmdbuffer)) || __put_user((int __user *)(unsigned long)cmdbuffer32.buf, &cmdbuffer->buf) || __put_user(cmdbuffer32.sz, &cmdbuffer->sz) || __put_user(cmdbuffer32.DR1, &cmdbuffer->DR1) || __put_user(cmdbuffer32.DR4, &cmdbuffer->DR4) || __put_user(cmdbuffer32.num_cliprects, &cmdbuffer->num_cliprects) || __put_user((int __user *)(unsigned long)cmdbuffer32.cliprects, &cmdbuffer->cliprects)) return -EFAULT; return drm_ioctl(file->f_dentry->d_inode, file, DRM_IOCTL_I915_CMDBUFFER, (unsigned long) cmdbuffer); } typedef struct drm_i915_irq_emit32 { u32 irq_seq; } drm_i915_irq_emit32_t; static int compat_i915_irq_emit(struct file *file, unsigned int cmd, unsigned long arg) { drm_i915_irq_emit32_t req32; drm_i915_irq_emit_t __user *request; if (copy_from_user(&req32, (void __user *) arg, sizeof(req32))) return -EFAULT; request = compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user((int __user *)(unsigned long)req32.irq_seq, &request->irq_seq)) return -EFAULT; return drm_ioctl(file->f_dentry->d_inode, file, DRM_IOCTL_I915_IRQ_EMIT, (unsigned long) request); } typedef struct drm_i915_getparam32 { int param; u32 value; } drm_i915_getparam32_t; static int compat_i915_getparam(struct file *file, unsigned int cmd, unsigned long arg) { drm_i915_getparam32_t req32; drm_i915_getparam_t __user *request; if (copy_from_user(&req32, (void __user *) arg, sizeof(req32))) return -EFAULT; request = compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user(req32.param, &request->param) || __put_user((void __user *)(unsigned long)req32.value, &request->value)) return -EFAULT; return drm_ioctl(file->f_dentry->d_inode, file, DRM_IOCTL_I915_GETPARAM, (unsigned long) request); } typedef struct drm_i915_mem_alloc32 { int region; int alignment; int size; u32 region_offset; /* offset from start of fb or agp */ } drm_i915_mem_alloc32_t; static int compat_i915_alloc(struct file *file, unsigned int cmd, unsigned long arg) { drm_i915_mem_alloc32_t req32; drm_i915_mem_alloc_t __user *request; if (copy_from_user(&req32, (void __user *) arg, sizeof(req32))) return -EFAULT; request = compat_alloc_user_space(sizeof(*request)); if (!access_ok(VERIFY_WRITE, request, sizeof(*request)) || __put_user(req32.region, &request->region) || __put_user(req32.alignment, &request->alignment) || __put_user(req32.size, &request->size) || __put_user((void __user *)(unsigned long)req32.region_offset, &request->region_offset)) return -EFAULT; return drm_ioctl(file->f_dentry->d_inode, file, DRM_IOCTL_I915_ALLOC, (unsigned long) request); } drm_ioctl_compat_t *i915_compat_ioctls[] = { [DRM_I915_BATCHBUFFER] = compat_i915_batchbuffer, [DRM_I915_CMDBUFFER] = compat_i915_cmdbuffer, [DRM_I915_GETPARAM] = compat_i915_getparam, [DRM_I915_IRQ_EMIT] = compat_i915_irq_emit, [DRM_I915_ALLOC] = compat_i915_alloc }; /** * Called whenever a 32-bit process running under a 64-bit kernel * performs an ioctl on /dev/dri/card<n>. * * \param filp file pointer. * \param cmd command. * \param arg user argument. * \return zero on success or negative number on failure. */ long i915_compat_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) { unsigned int nr = DRM_IOCTL_NR(cmd); drm_ioctl_compat_t *fn = NULL; int ret; if (nr < DRM_COMMAND_BASE) return drm_compat_ioctl(filp, cmd, arg); if (nr < DRM_COMMAND_BASE + DRM_ARRAY_SIZE(i915_compat_ioctls)) fn = i915_compat_ioctls[nr - DRM_COMMAND_BASE]; lock_kernel(); /* XXX for now */ if (fn != NULL) ret = (*fn)(filp, cmd, arg); else ret = drm_ioctl(filp->f_dentry->d_inode, filp, cmd, arg); unlock_kernel(); return ret; }