patch-2.4.15 linux/drivers/char/drm/ati_pcigart.h

Next file: linux/drivers/char/drm/drm_agpsupport.h
Previous file: linux/drivers/char/agp/agpgart_be.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.14/linux/drivers/char/drm/ati_pcigart.h linux/drivers/char/drm/ati_pcigart.h
@@ -36,7 +36,7 @@
 #elif PAGE_SIZE == 4096
 # define ATI_PCIGART_TABLE_ORDER 	3
 # define ATI_PCIGART_TABLE_PAGES 	(1 << 3)
-#elif
+#else
 # error - PAGE_SIZE not 8K or 4K
 #endif
 
@@ -57,7 +57,7 @@
 
 	page = virt_to_page( address );
 
-	for ( i = 0 ; i <= ATI_PCIGART_TABLE_PAGES ; i++, page++ ) {
+	for ( i = 0 ; i < ATI_PCIGART_TABLE_PAGES ; i++, page++ ) {
 		atomic_inc( &page->count );
 		SetPageReserved( page );
 	}
@@ -74,7 +74,7 @@
 
 	page = virt_to_page( address );
 
-	for ( i = 0 ; i <= ATI_PCIGART_TABLE_PAGES ; i++, page++ ) {
+	for ( i = 0 ; i < ATI_PCIGART_TABLE_PAGES ; i++, page++ ) {
 		atomic_dec( &page->count );
 		ClearPageReserved( page );
 	}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)