diff options
author | Émeric Maschino <emeric.maschino@gmail.com> | 2011-08-23 15:48:23 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2011-08-23 16:31:59 -0400 |
commit | fc000154d7a63dee209aab1c13f2c19abdcf6b59 (patch) | |
tree | 1f76e42f6289fadb195e898eefec96d98017f329 /drivers/char | |
parent | d5d4e02874537d65ed2f431d39bf2f6d2967bd1b (diff) |
[IA64] agp/hp-agp: Allow binding user memory to the AGP GART
dmesg reports:
[ 29.365973] [TTM] AGP Bind memory failed.
[ 29.366015] radeon 0000:80:00.0: object_init failed for (4096, 0x00000002)
[ 29.366052] radeon 0000:80:00.0: (-22) create WB bo failed
[ 29.366087] radeon 0000:80:00.0: Disabling GPU acceleration
[ 29.366124] [drm] radeon: cp finalized
[ 29.366168] [drm] radeon: cp finalized
[ 29.366210] [TTM] Finalizing pool allocator.
[ 29.366924] [TTM] Zone kernel: Used memory at exit: 0 kiB.
[ 29.366961] [TTM] Zone dma32: Used memory at exit: 0 kiB.
[ 29.366996] [drm] radeon: ttm finalized
[ 29.367030] [drm] Forcing AGP to PCI mode
This patch allows binding user memory to the AGP GART on zx1-based
systems. dmesg thus no more complains about AGP bind memory failure,
disabled GPU acceleration or AGP mode forced to PCI.
Original work from Francisco Jerez in agp/amd-k7
(https://lkml.org/lkml/2010/10/15/469).
Tested-by: Émeric Maschino <emeric.maschino@gmail.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/agp/hp-agp.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/char/agp/hp-agp.c b/drivers/char/agp/hp-agp.c index 056b289a1e89..3695773ce7c3 100644 --- a/drivers/char/agp/hp-agp.c +++ b/drivers/char/agp/hp-agp.c | |||
@@ -336,7 +336,8 @@ hp_zx1_insert_memory (struct agp_memory *mem, off_t pg_start, int type) | |||
336 | off_t j, io_pg_start; | 336 | off_t j, io_pg_start; |
337 | int io_pg_count; | 337 | int io_pg_count; |
338 | 338 | ||
339 | if (type != 0 || mem->type != 0) { | 339 | if (type != mem->type || |
340 | agp_bridge->driver->agp_type_to_mask_type(agp_bridge, type)) { | ||
340 | return -EINVAL; | 341 | return -EINVAL; |
341 | } | 342 | } |
342 | 343 | ||
@@ -380,7 +381,8 @@ hp_zx1_remove_memory (struct agp_memory *mem, off_t pg_start, int type) | |||
380 | struct _hp_private *hp = &hp_private; | 381 | struct _hp_private *hp = &hp_private; |
381 | int i, io_pg_start, io_pg_count; | 382 | int i, io_pg_start, io_pg_count; |
382 | 383 | ||
383 | if (type != 0 || mem->type != 0) { | 384 | if (type != mem->type || |
385 | agp_bridge->driver->agp_type_to_mask_type(agp_bridge, type)) { | ||
384 | return -EINVAL; | 386 | return -EINVAL; |
385 | } | 387 | } |
386 | 388 | ||