Skip to content
Browse files

fixed a bug in mem gc

  • Loading branch information...
1 parent c38d96b commit 9a9c75ce113baa9b243905a5a0fa436523992208 @wkbjerry wkbjerry committed Oct 4, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 common/gdev_nvidia_mem.c
View
4 common/gdev_nvidia_mem.c
@@ -233,12 +233,12 @@ void gdev_mem_gc(struct gdev_vas *vas)
struct gdev_mem *mem;
/* device memory. */
- gdev_list_for_each (mem, &vas->mem_list, list_entry_heap) {
+ while((mem = gdev_list_container(gdev_list_head(&vas->mem_list)))) {
gdev_mem_free(mem);
}
/* host DMA memory. */
- gdev_list_for_each (mem, &vas->dma_mem_list, list_entry_heap) {
+ while((mem = gdev_list_container(gdev_list_head(&vas->dma_mem_list)))) {
gdev_mem_free(mem);
}
}

0 comments on commit 9a9c75c

Please sign in to comment.
Something went wrong with that request. Please try again.