diff options
Diffstat (limited to 'drivers/gpu/drm/ttm/ttm_page_alloc.c')
-rw-r--r-- | drivers/gpu/drm/ttm/ttm_page_alloc.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_page_alloc.c b/drivers/gpu/drm/ttm/ttm_page_alloc.c index d948575717bf..170e751c283e 100644 --- a/drivers/gpu/drm/ttm/ttm_page_alloc.c +++ b/drivers/gpu/drm/ttm/ttm_page_alloc.c | |||
@@ -355,7 +355,7 @@ restart: | |||
355 | if (nr_free) | 355 | if (nr_free) |
356 | goto restart; | 356 | goto restart; |
357 | 357 | ||
358 | /* Not allowed to fall tough or break because | 358 | /* Not allowed to fall through or break because |
359 | * following context is inside spinlock while we are | 359 | * following context is inside spinlock while we are |
360 | * outside here. | 360 | * outside here. |
361 | */ | 361 | */ |
@@ -556,7 +556,7 @@ out: | |||
556 | } | 556 | } |
557 | 557 | ||
558 | /** | 558 | /** |
559 | * Fill the given pool if there isn't enough pages and requested number of | 559 | * Fill the given pool if there aren't enough pages and the requested number of |
560 | * pages is small. | 560 | * pages is small. |
561 | */ | 561 | */ |
562 | static void ttm_page_pool_fill_locked(struct ttm_page_pool *pool, | 562 | static void ttm_page_pool_fill_locked(struct ttm_page_pool *pool, |
@@ -576,8 +576,8 @@ static void ttm_page_pool_fill_locked(struct ttm_page_pool *pool, | |||
576 | 576 | ||
577 | pool->fill_lock = true; | 577 | pool->fill_lock = true; |
578 | 578 | ||
579 | /* If allocation request is small and there is not enough | 579 | /* If allocation request is small and there are not enough |
580 | * pages in pool we fill the pool first */ | 580 | * pages in a pool we fill the pool up first. */ |
581 | if (count < _manager->options.small | 581 | if (count < _manager->options.small |
582 | && count > pool->npages) { | 582 | && count > pool->npages) { |
583 | struct list_head new_pages; | 583 | struct list_head new_pages; |
@@ -614,9 +614,9 @@ static void ttm_page_pool_fill_locked(struct ttm_page_pool *pool, | |||
614 | } | 614 | } |
615 | 615 | ||
616 | /** | 616 | /** |
617 | * Cut count nubmer of pages from the pool and put them to return list | 617 | * Cut 'count' number of pages from the pool and put them on the return list. |
618 | * | 618 | * |
619 | * @return count of pages still to allocate to fill the request. | 619 | * @return count of pages still required to fulfill the request. |
620 | */ | 620 | */ |
621 | static unsigned ttm_page_pool_get_pages(struct ttm_page_pool *pool, | 621 | static unsigned ttm_page_pool_get_pages(struct ttm_page_pool *pool, |
622 | struct list_head *pages, int ttm_flags, | 622 | struct list_head *pages, int ttm_flags, |
@@ -637,7 +637,7 @@ static unsigned ttm_page_pool_get_pages(struct ttm_page_pool *pool, | |||
637 | goto out; | 637 | goto out; |
638 | } | 638 | } |
639 | /* find the last pages to include for requested number of pages. Split | 639 | /* find the last pages to include for requested number of pages. Split |
640 | * pool to begin and halves to reduce search space. */ | 640 | * pool to begin and halve it to reduce search space. */ |
641 | if (count <= pool->npages/2) { | 641 | if (count <= pool->npages/2) { |
642 | i = 0; | 642 | i = 0; |
643 | list_for_each(p, &pool->list) { | 643 | list_for_each(p, &pool->list) { |
@@ -651,7 +651,7 @@ static unsigned ttm_page_pool_get_pages(struct ttm_page_pool *pool, | |||
651 | break; | 651 | break; |
652 | } | 652 | } |
653 | } | 653 | } |
654 | /* Cut count number of pages from pool */ | 654 | /* Cut 'count' number of pages from the pool */ |
655 | list_cut_position(pages, &pool->list, p); | 655 | list_cut_position(pages, &pool->list, p); |
656 | pool->npages -= count; | 656 | pool->npages -= count; |
657 | count = 0; | 657 | count = 0; |