summaryrefslogtreecommitdiff
AgeCommit message (Expand)Author
2006-01-02make max minor more rationalDave Airlie
2006-01-02use drm_cards_limit instead of cards_limitDave Airlie
2006-01-02use common read/write routinesDave Airlie
2006-01-02sparse cleanupsDave Airlie
2006-01-02The radeon DRM wasn't passing sparse checking in the kernel, this fixes itDave Airlie
2006-01-02align spacing with kernelDave Airlie
2006-01-02whitespace cleanup/aligment with kernelDave Airlie
2006-01-02some fixes from linux kernelDave Airlie
2006-01-02complete fix for historic attributionDave Airlie
2006-01-02complete fix for attributionDave Airlie
2006-01-02Realign via driver with changes in Linux kernel (mainly whitespace)Dave Airlie
2005-12-31Initialize sv.drm_dd_minor to "don't care" along with dd_major, to appeaseEric Anholt
2005-12-30Merge patch from jhb to catch up with FreeBSD-current vgapci master deviceEric Anholt
2005-12-29add radeon card type get param so userspace can avoid walking PCIDave Airlie
2005-12-28Add vblank support to i915 DRM..Dave Airlie
2005-12-28step back one reported bugs against that patchDave Airlie
2005-12-16fix radeon memory mapping from Ben HerrenschmidtDave Airlie
2005-12-16Lindent some via filesDave Airlie
2005-12-05Remove driver.device_is_agp code duplicated in drm_device_find_capability,Eric Anholt
2005-12-05add texrect support for r300Dave Airlie
2005-12-04Fix from SuSE for issue with context creation failureDave Airlie
2005-12-02Add RV410 X700PRO PCI IDEric Anholt
2005-12-02Finish the last bits necessary to get the i915 DRM port working on FreeBSDEric Anholt
2005-12-02FreeBSD PR kern/85479: Restore the enabling of debugging by default by theEric Anholt
2005-11-30Bump package and DSO numbers to 2.0 to reflect 32/64 ABI changeAdam Jackson
2005-11-30Resync from Xorg head: conditional include of xorg-config.hAdam Jackson
2005-11-30Resync from Xorg head (Bug #3815, GNU/kFreeBSD hack)Adam Jackson
2005-11-29Add TODO based on my email from a while agoAdam Jackson
2005-11-29Remove redundant #ifdef stanzaAdam Jackson
2005-11-29Error checking for drmStrdup (Tilman Sauerbeck)Adam Jackson
2005-11-29fixup xf86drm.c for new headersDave Airlie
2005-11-29Fix from Hugh Dickins for consistent mappingDave Airlie
2005-11-29fixes from Egbert for 64bitDave Airlie
2005-11-28Assert an MIT copyright on sis_drm.h, since one was lacking and I createdEric Anholt
2005-11-28remove xf86drmCompat.*, unused since about XFree86 4.2.Adam Jackson
2005-11-28Fix AGP support guessing: Implement the same bridge checking in the MGAEric Anholt
2005-11-28fix mem leak in HashHash() (bug 5171)Brian Paul
2005-11-16Fixed long standing 64-bit bug in via memory manager. Bumped via date andThomas Hellstrom
2005-11-15Loosen via dmablit alignment checks somewhat. Adapt stride check to maximumThomas Hellstrom
2005-11-15Fix compiling and reenable build of i915 driver.Eric Anholt
2005-11-15Fix Savage DRI without ShadowStatus NO by allowing the shadow area to beEric Anholt
2005-11-11enable i915 32/64 bit ioctlsDave Airlie
2005-11-11RV200 < R200Dave Airlie
2005-11-11i810 should be fine with i810.. no idea what this crack is ..Dave Airlie
2005-11-11fix up radeon whitespaceDave Airlie
2005-11-11Fix breakage from the move of driver ioctl externs to header files.Eric Anholt
2005-11-11whitespace align with kernelDave Airlie
2005-11-11mixing breaks in r128 driver.. fixed in kernelDave Airlie
2005-11-11copy correct KconfigDave Airlie
2005-11-11realign whitespace with kernelDave Airlie
hl opt">.devnum, p.funcnum, p.irq); if (copy_to_user((drm_irq_busid_t *)arg, &p, sizeof(p))) return -EFAULT; return 0; } int DRM(getunique)(struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg) { drm_file_t *priv = filp->private_data; drm_device_t *dev = priv->dev; drm_unique_t u; if (copy_from_user(&u, (drm_unique_t *)arg, sizeof(u))) return -EFAULT; if (u.unique_len >= dev->unique_len) { if (copy_to_user(u.unique, dev->unique, dev->unique_len)) return -EFAULT; } u.unique_len = dev->unique_len; if (copy_to_user((drm_unique_t *)arg, &u, sizeof(u))) return -EFAULT; return 0; } int DRM(setunique)(struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg) { drm_file_t *priv = filp->private_data; drm_device_t *dev = priv->dev; drm_unique_t u; if (dev->unique_len || dev->unique) return -EBUSY; if (copy_from_user(&u, (drm_unique_t *)arg, sizeof(u))) return -EFAULT; if (!u.unique_len || u.unique_len > 1024) return -EINVAL; dev->unique_len = u.unique_len; dev->unique = DRM(alloc)(u.unique_len + 1, DRM_MEM_DRIVER); if(!dev->unique) return -ENOMEM; if (copy_from_user(dev->unique, u.unique, dev->unique_len)) return -EFAULT; dev->unique[dev->unique_len] = '\0'; dev->devname = DRM(alloc)(strlen(dev->name) + strlen(dev->unique) + 2, DRM_MEM_DRIVER); if(!dev->devname) { DRM(free)(dev->devname, sizeof(*dev->devname), DRM_MEM_DRIVER); return -ENOMEM; } sprintf(dev->devname, "%s@%s", dev->name, dev->unique); do { struct pci_dev *pci_dev; int b, d, f; char *p; for(p = dev->unique; p && *p && *p != ':'; p++); if (!p || !*p) break; b = (int)simple_strtoul(p+1, &p, 10); if (*p != ':') break; d = (int)simple_strtoul(p+1, &p, 10); if (*p != ':') break; f = (int)simple_strtoul(p+1, &p, 10); if (*p) break; pci_dev = pci_find_slot(b, PCI_DEVFN(d,f)); if (pci_dev) { dev->pdev = pci_dev; #ifdef __alpha__ dev->hose = pci_dev->sysdata; #endif } } while(0); return 0; } int DRM(getmap)( struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg ) { drm_file_t *priv = filp->private_data; drm_device_t *dev = priv->dev; drm_map_t map; drm_map_list_t *r_list = NULL; struct list_head *list; int idx; int i; if (copy_from_user(&map, (drm_map_t *)arg, sizeof(map))) return -EFAULT; idx = map.offset; down(&dev->struct_sem); if (idx < 0 || idx >= dev->map_count) { up(&dev->struct_sem); return -EINVAL; } i = 0; list_for_each(list, &dev->maplist->head) { if(i == idx) { r_list = (drm_map_list_t *)list; break; } i++; } if(!r_list || !r_list->map) { up(&dev->struct_sem); return -EINVAL; } map.offset = r_list->map->offset; map.size = r_list->map->size; map.type = r_list->map->type; map.flags = r_list->map->flags; map.handle = r_list->map->handle; map.mtrr = r_list->map->mtrr; up(&dev->struct_sem); if (copy_to_user((drm_map_t *)arg, &map, sizeof(map))) return -EFAULT; return 0; } int DRM(getclient)( struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg ) { drm_file_t *priv = filp->private_data; drm_device_t *dev = priv->dev; drm_client_t client; drm_file_t *pt; int idx; int i; if (copy_from_user(&client, (drm_client_t *)arg, sizeof(client))) return -EFAULT; idx = client.idx; down(&dev->struct_sem); for (i = 0, pt = dev->file_first; i < idx && pt; i++, pt = pt->next) ; if (!pt) { up(&dev->struct_sem); return -EINVAL; } client.auth = pt->authenticated; client.pid = pt->pid; client.uid = pt->uid; client.magic = pt->magic; client.iocs = pt->ioctl_count; up(&dev->struct_sem); if (copy_to_user((drm_client_t *)arg, &client, sizeof(client))) return -EFAULT; return 0; } int DRM(getstats)( struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg ) { drm_file_t *priv = filp->private_data;