2.6 patches for larger dev_t

main
Dave Airlie 2004-04-08 12:22:22 +00:00
parent 3e0f3c1fbb
commit 9cff4b45e7
2 changed files with 6 additions and 6 deletions

View File

@ -790,7 +790,7 @@ int DRM(open)( struct inode *inode, struct file *filp )
int i; int i;
for (i = 0; i < DRM(numdevs); i++) { for (i = 0; i < DRM(numdevs); i++) {
if (minor(inode->i_rdev) == DRM(device)[i].minor) { if (iminor(inode) == DRM(device)[i].minor) {
dev = &(DRM(device)[i]); dev = &(DRM(device)[i]);
break; break;
} }
@ -843,7 +843,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) &&
@ -998,7 +998,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 ) {

View File

@ -790,7 +790,7 @@ int DRM(open)( struct inode *inode, struct file *filp )
int i; int i;
for (i = 0; i < DRM(numdevs); i++) { for (i = 0; i < DRM(numdevs); i++) {
if (minor(inode->i_rdev) == DRM(device)[i].minor) { if (iminor(inode) == DRM(device)[i].minor) {
dev = &(DRM(device)[i]); dev = &(DRM(device)[i]);
break; break;
} }
@ -843,7 +843,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) &&
@ -998,7 +998,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 ) {