mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] AGPGART 2/5: size AGP mem correctly when memory is discontiguous
@ 2002-09-28  4:34 Bjorn Helgaas
  0 siblings, 0 replies; only message in thread
From: Bjorn Helgaas @ 2002-09-28  4:34 UTC (permalink / raw)
  To: marcelo; +Cc: linux-kernel

This removes the agpgart assumption that memory is contiguous.

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
#	           ChangeSet	1.661   -> 1.662  
#	drivers/char/agp/agpgart_be.c	1.35    -> 1.36   
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 02/09/13	bjorn_helgaas@hp.com	1.662
# Fix max AGP memory for machines with discontiguous memory.
# --------------------------------------------
#
diff -Nru a/drivers/char/agp/agpgart_be.c b/drivers/char/agp/agpgart_be.c
--- a/drivers/char/agp/agpgart_be.c	Fri Sep 13 16:50:25 2002
+++ b/drivers/char/agp/agpgart_be.c	Fri Sep 13 16:50:25 2002
@@ -4517,7 +4497,7 @@
 {
 	long memory, index, result;
 
-	memory = virt_to_phys(high_memory) >> 20;
+	memory = (num_physpages << PAGE_SHIFT) >> 20;
 	index = 1;
 
 	while ((memory > maxes_table[index].mem) &&

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-09-28  4:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-28  4:34 [PATCH] AGPGART 2/5: size AGP mem correctly when memory is discontiguous Bjorn Helgaas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®