Commit 2c655bdf authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] prepare for 32-bit dev_t: drm debugging printks

	added old_encode_dev() in drm debugging printks, so they won't change
when we go for bigger dev_t.
parent 845602f8
...@@ -848,7 +848,7 @@ int DRM(release)( struct inode *inode, struct file *filp ) ...@@ -848,7 +848,7 @@ int DRM(release)( struct inode *inode, struct file *filp )
*/ */
DRM_DEBUG( "pid = %d, device = 0x%lx, open_count = %d\n", 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 );
if ( priv->lock_count && dev->lock.hw_lock && if ( priv->lock_count && dev->lock.hw_lock &&
_DRM_LOCK_IS_HELD(dev->lock.hw_lock->lock) && _DRM_LOCK_IS_HELD(dev->lock.hw_lock->lock) &&
...@@ -983,7 +983,7 @@ int DRM(ioctl)( struct inode *inode, struct file *filp, ...@@ -983,7 +983,7 @@ int DRM(ioctl)( struct inode *inode, struct file *filp,
++priv->ioctl_count; ++priv->ioctl_count;
DRM_DEBUG( "pid=%d, cmd=0x%02x, nr=0x%02x, dev 0x%lx, auth=%d\n", DRM_DEBUG( "pid=%d, cmd=0x%02x, nr=0x%02x, dev 0x%lx, auth=%d\n",
current->pid, cmd, nr, (long)dev->device, current->pid, cmd, nr, (long)old_encode_dev(dev->device),
priv->authenticated ); priv->authenticated );
if ( nr >= DRIVER_IOCTL_COUNT ) { if ( nr >= DRIVER_IOCTL_COUNT ) {
......
...@@ -111,7 +111,7 @@ int DRM(flush)(struct file *filp) ...@@ -111,7 +111,7 @@ int DRM(flush)(struct file *filp)
drm_device_t *dev = priv->dev; drm_device_t *dev = priv->dev;
DRM_DEBUG("pid = %d, device = 0x%lx, open_count = %d\n", 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; return 0;
} }
...@@ -122,7 +122,7 @@ int DRM(fasync)(int fd, struct file *filp, int on) ...@@ -122,7 +122,7 @@ int DRM(fasync)(int fd, struct file *filp, int on)
drm_device_t *dev = priv->dev; drm_device_t *dev = priv->dev;
int retcode; 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); retcode = fasync_helper(fd, filp, on, &dev->buf_async);
if (retcode < 0) return retcode; if (retcode < 0) return retcode;
return 0; return 0;
......
...@@ -184,9 +184,9 @@ static int DRM(name_info)(char *buf, char **start, off_t offset, int request, ...@@ -184,9 +184,9 @@ static int DRM(name_info)(char *buf, char **start, off_t offset, int request,
if (dev->unique) { if (dev->unique) {
DRM_PROC_PRINT("%s 0x%lx %s\n", 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 { } 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; if (len > request + offset) return request;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment