mirror of
https://gitlab.freedesktop.org/mesa/drm.git
synced 2025-12-24 21:50:20 +01:00
long dev_t patches from 2.6 tree
This commit is contained in:
parent
9cff4b45e7
commit
c3e2685e82
6 changed files with 12 additions and 12 deletions
|
|
@ -52,7 +52,7 @@
|
|||
*/
|
||||
int DRM(open_helper)(struct inode *inode, struct file *filp, drm_device_t *dev)
|
||||
{
|
||||
int minor = minor(inode->i_rdev);
|
||||
int minor = iminor(inode);
|
||||
drm_file_t *priv;
|
||||
|
||||
if (filp->f_flags & O_EXCL) return -EBUSY; /* No exclusive opens */
|
||||
|
|
@ -114,7 +114,7 @@ int DRM(flush)(struct file *filp)
|
|||
drm_device_t *dev = priv->dev;
|
||||
|
||||
DRM_DEBUG("pid = %d, device = 0x%lx, open_count = %d\n",
|
||||
current->pid, (long)dev->device, dev->open_count);
|
||||
current->pid, (long)old_encode_dev(dev->device), dev->open_count);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -125,7 +125,7 @@ int DRM(fasync)(int fd, struct file *filp, int on)
|
|||
drm_device_t *dev = priv->dev;
|
||||
int retcode;
|
||||
|
||||
DRM_DEBUG("fd = %d, device = 0x%lx\n", fd, (long)dev->device);
|
||||
DRM_DEBUG("fd = %d, device = 0x%lx\n", fd, (long)old_encode_dev(dev->device));
|
||||
retcode = fasync_helper(fd, filp, on, &dev->buf_async);
|
||||
if (retcode < 0) return retcode;
|
||||
return 0;
|
||||
|
|
|
|||
|
|
@ -185,9 +185,9 @@ static int DRM(name_info)(char *buf, char **start, off_t offset, int request,
|
|||
|
||||
if (dev->unique) {
|
||||
DRM_PROC_PRINT("%s 0x%lx %s\n",
|
||||
dev->name, (long)dev->device, dev->unique);
|
||||
dev->name, (long)old_encode_dev(dev->device), dev->unique);
|
||||
} else {
|
||||
DRM_PROC_PRINT("%s 0x%lx\n", dev->name, (long)dev->device);
|
||||
DRM_PROC_PRINT("%s 0x%lx\n", dev->name, (long)old_encode_dev(dev->device));
|
||||
}
|
||||
|
||||
if (len > request + offset) return request;
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ static struct drm_stub_info {
|
|||
*/
|
||||
static int DRM(stub_open)(struct inode *inode, struct file *filp)
|
||||
{
|
||||
int minor = minor(inode->i_rdev);
|
||||
int minor = iminor(inode);
|
||||
int err = -ENODEV;
|
||||
struct file_operations *old_fops;
|
||||
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@
|
|||
*/
|
||||
int DRM(open_helper)(struct inode *inode, struct file *filp, drm_device_t *dev)
|
||||
{
|
||||
int minor = minor(inode->i_rdev);
|
||||
int minor = iminor(inode);
|
||||
drm_file_t *priv;
|
||||
|
||||
if (filp->f_flags & O_EXCL) return -EBUSY; /* No exclusive opens */
|
||||
|
|
@ -114,7 +114,7 @@ int DRM(flush)(struct file *filp)
|
|||
drm_device_t *dev = priv->dev;
|
||||
|
||||
DRM_DEBUG("pid = %d, device = 0x%lx, open_count = %d\n",
|
||||
current->pid, (long)dev->device, dev->open_count);
|
||||
current->pid, (long)old_encode_dev(dev->device), dev->open_count);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -125,7 +125,7 @@ int DRM(fasync)(int fd, struct file *filp, int on)
|
|||
drm_device_t *dev = priv->dev;
|
||||
int retcode;
|
||||
|
||||
DRM_DEBUG("fd = %d, device = 0x%lx\n", fd, (long)dev->device);
|
||||
DRM_DEBUG("fd = %d, device = 0x%lx\n", fd, (long)old_encode_dev(dev->device));
|
||||
retcode = fasync_helper(fd, filp, on, &dev->buf_async);
|
||||
if (retcode < 0) return retcode;
|
||||
return 0;
|
||||
|
|
|
|||
|
|
@ -185,9 +185,9 @@ static int DRM(name_info)(char *buf, char **start, off_t offset, int request,
|
|||
|
||||
if (dev->unique) {
|
||||
DRM_PROC_PRINT("%s 0x%lx %s\n",
|
||||
dev->name, (long)dev->device, dev->unique);
|
||||
dev->name, (long)old_encode_dev(dev->device), dev->unique);
|
||||
} else {
|
||||
DRM_PROC_PRINT("%s 0x%lx\n", dev->name, (long)dev->device);
|
||||
DRM_PROC_PRINT("%s 0x%lx\n", dev->name, (long)old_encode_dev(dev->device));
|
||||
}
|
||||
|
||||
if (len > request + offset) return request;
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ static struct drm_stub_info {
|
|||
*/
|
||||
static int DRM(stub_open)(struct inode *inode, struct file *filp)
|
||||
{
|
||||
int minor = minor(inode->i_rdev);
|
||||
int minor = iminor(inode);
|
||||
int err = -ENODEV;
|
||||
struct file_operations *old_fops;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue