patch-2.4.20 linux-2.4.20/drivers/char/drm/drm_bufs.h
Next file: linux-2.4.20/drivers/char/drm/drm_context.h
Previous file: linux-2.4.20/drivers/char/drm/drm_auth.h
Back to the patch index
Back to the overall index
- Lines: 55
- Date:
Thu Nov 28 15:53:12 2002
- Orig file:
linux-2.4.19/drivers/char/drm/drm_bufs.h
- Orig date:
Thu Nov 22 11:46:37 2001
diff -urN linux-2.4.19/drivers/char/drm/drm_bufs.h linux-2.4.20/drivers/char/drm/drm_bufs.h
@@ -29,7 +29,6 @@
* Gareth Hughes <gareth@valinux.com>
*/
-#define __NO_VERSION__
#include <linux/vmalloc.h>
#include "drmP.h"
@@ -229,11 +228,7 @@
DRM(free)(list, sizeof(*list), DRM_MEM_MAPS);
for (pt = dev->vmalist, prev = NULL; pt; prev = pt, pt = pt->next) {
-#if LINUX_VERSION_CODE >= 0x020300
if (pt->vma->vm_private_data == map) found_maps++;
-#else
- if (pt->vma->vm_pte == map) found_maps++;
-#endif
}
if(!found_maps) {
@@ -1063,34 +1058,18 @@
goto done;
}
-#if LINUX_VERSION_CODE <= 0x020402
- down( ¤t->mm->mmap_sem );
-#else
down_write( ¤t->mm->mmap_sem );
-#endif
virtual = do_mmap( filp, 0, map->size,
PROT_READ | PROT_WRITE,
MAP_SHARED,
(unsigned long)map->offset );
-#if LINUX_VERSION_CODE <= 0x020402
- up( ¤t->mm->mmap_sem );
-#else
up_write( ¤t->mm->mmap_sem );
-#endif
} else {
-#if LINUX_VERSION_CODE <= 0x020402
- down( ¤t->mm->mmap_sem );
-#else
down_write( ¤t->mm->mmap_sem );
-#endif
virtual = do_mmap( filp, 0, dma->byte_count,
PROT_READ | PROT_WRITE,
MAP_SHARED, 0 );
-#if LINUX_VERSION_CODE <= 0x020402
- up( ¤t->mm->mmap_sem );
-#else
up_write( ¤t->mm->mmap_sem );
-#endif
}
if ( virtual > -1024UL ) {
/* Real error */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)