diff options
author | Jeff Hartmann <jhartmann@valinux.com> | 2001-08-07 18:15:10 +0000 |
---|---|---|
committer | Jeff Hartmann <jhartmann@valinux.com> | 2001-08-07 18:15:10 +0000 |
commit | 51e38d96ead5700c25c4fddd8017dc7992e96f5a (patch) | |
tree | 0f0372afa73a701c1be0e9f9b6b65106817d14a6 /linux/r128_state.c | |
parent | 56bd9c207770d41a497f3e8237a1099dd9d4cd91 (diff) |
Lots of DRM fixes: added new pieces of template code so the ffb driver can
be ported, rolled back r128 and i810 version bumps so 4.1.0 works with
cvs kernel modules, added Config.in and updated Makefile.kernel,
incorporated lots of drm fixes inspired by patches sent by Redhat, made
DRM(realloc) usage check for NULL allocations, restructure driver init
routines to export dev_priv only when initialized and to check for all
error conditions.
Diffstat (limited to 'linux/r128_state.c')
-rw-r--r-- | linux/r128_state.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/linux/r128_state.c b/linux/r128_state.c index 7eafd72d..66af5c45 100644 --- a/linux/r128_state.c +++ b/linux/r128_state.c @@ -910,7 +910,7 @@ static int r128_cce_dispatch_write_span( drm_device_t *dev, return -EFAULT; } - buffer = kmalloc( depth->n * sizeof(u32), 0 ); + buffer = kmalloc( depth->n * sizeof(u32), GFP_KERNEL ); if ( buffer == NULL ) return -ENOMEM; if ( copy_from_user( buffer, depth->buffer, @@ -920,7 +920,7 @@ static int r128_cce_dispatch_write_span( drm_device_t *dev, } if ( depth->mask ) { - mask = kmalloc( depth->n * sizeof(u8), 0 ); + mask = kmalloc( depth->n * sizeof(u8), GFP_KERNEL ); if ( mask == NULL ) { kfree( buffer ); return -ENOMEM; @@ -997,11 +997,11 @@ static int r128_cce_dispatch_write_pixels( drm_device_t *dev, count = depth->n; - x = kmalloc( count * sizeof(*x), 0 ); + x = kmalloc( count * sizeof(*x), GFP_KERNEL ); if ( x == NULL ) { return -ENOMEM; } - y = kmalloc( count * sizeof(*y), 0 ); + y = kmalloc( count * sizeof(*y), GFP_KERNEL ); if ( y == NULL ) { kfree( x ); return -ENOMEM; @@ -1017,7 +1017,7 @@ static int r128_cce_dispatch_write_pixels( drm_device_t *dev, return -EFAULT; } - buffer = kmalloc( depth->n * sizeof(u32), 0 ); + buffer = kmalloc( depth->n * sizeof(u32), GFP_KERNEL ); if ( buffer == NULL ) { kfree( x ); kfree( y ); @@ -1032,7 +1032,7 @@ static int r128_cce_dispatch_write_pixels( drm_device_t *dev, } if ( depth->mask ) { - mask = kmalloc( depth->n * sizeof(u8), 0 ); + mask = kmalloc( depth->n * sizeof(u8), GFP_KERNEL ); if ( mask == NULL ) { kfree( x ); kfree( y ); @@ -1157,11 +1157,11 @@ static int r128_cce_dispatch_read_pixels( drm_device_t *dev, count = dev_priv->depth_pitch; } - x = kmalloc( count * sizeof(*x), 0 ); + x = kmalloc( count * sizeof(*x), GFP_KERNEL ); if ( x == NULL ) { return -ENOMEM; } - y = kmalloc( count * sizeof(*y), 0 ); + y = kmalloc( count * sizeof(*y), GFP_KERNEL ); if ( y == NULL ) { kfree( x ); return -ENOMEM; |