<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/include/drm/ttm/ttm_page_alloc.h, branch linux-3.0.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-3.0.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-3.0.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2011-02-23T04:24:01Z</updated>
<entry>
<title>Revert "ttm: Include the 'struct dev' when using the DMA API."</title>
<updated>2011-02-23T04:24:01Z</updated>
<author>
<name>Dave Airlie</name>
<email>airlied@redhat.com</email>
</author>
<published>2011-02-23T04:24:01Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=a2c06ee2fe5b48a71e697bae00c6e7195fc016b6'/>
<id>urn:sha1:a2c06ee2fe5b48a71e697bae00c6e7195fc016b6</id>
<content type='text'>
This reverts commit 5a893fc28f0393adb7c885a871b8c59e623fd528.

This causes a use after free in the ttm free alloc pages path,
when it tries to get the be after the be has been destroyed.

Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
</entry>
<entry>
<title>ttm: Include the 'struct dev' when using the DMA API.</title>
<updated>2011-02-22T18:26:23Z</updated>
<author>
<name>Konrad Rzeszutek Wilk</name>
<email>konrad.wilk@oracle.com</email>
</author>
<published>2011-02-22T18:24:32Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=5a893fc28f0393adb7c885a871b8c59e623fd528'/>
<id>urn:sha1:5a893fc28f0393adb7c885a871b8c59e623fd528</id>
<content type='text'>
This makes the accounting when using 'debug_dma_dump_mappings()'
and CONFIG_DMA_API_DEBUG=y be assigned to the correct device
instead of 'fallback'.

No functional change - just cosmetic.

Signed-off-by: Konrad Rzeszutek Wilk &lt;konrad.wilk@oracle.com&gt;
</content>
</entry>
<entry>
<title>ttm: Introduce a placeholder for DMA (bus) addresses.</title>
<updated>2011-01-27T21:02:31Z</updated>
<author>
<name>Konrad Rzeszutek Wilk</name>
<email>konrad.wilk@oracle.com</email>
</author>
<published>2010-11-29T18:52:18Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=f9820a46dd7888b05a36e81166fb1abcc47dcc3f'/>
<id>urn:sha1:f9820a46dd7888b05a36e81166fb1abcc47dcc3f</id>
<content type='text'>
This is right now limited to only non-pool constructs.

[v2: Fixed indentation issues, add review-by tag]

Reviewed-by: Thomas Hellstrom &lt;thomas@shipmail.org&gt;
Signed-off-by: Konrad Rzeszutek Wilk &lt;konrad.wilk@oracle.com&gt;
Tested-by: Ian Campbell &lt;ian.campbell@citrix.com&gt;
</content>
</entry>
<entry>
<title>drm/ttm: Allocate the page pool manager in the heap.</title>
<updated>2010-07-07T02:14:11Z</updated>
<author>
<name>Francisco Jerez</name>
<email>currojerez@riseup.net</email>
</author>
<published>2010-07-04T02:03:07Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=5870a4d97da136908ca477e3a21bc9f4c2705161'/>
<id>urn:sha1:5870a4d97da136908ca477e3a21bc9f4c2705161</id>
<content type='text'>
Repeated ttm_page_alloc_init/fini fails noisily because the pool
manager kobj isn't zeroed out between uses (we could do just that but
statically allocated kobjects are generally considered a bad thing).
Move it to kzalloc'ed memory.

Note that this patch drops the refcounting behavior of the pool
allocator init/fini functions: it would have led to a race condition
in its current form, and anyway it was never exploited.

This fixes a regression with reloading kms modules at runtime, since
page allocator was introduced.

Signed-off-by: Francisco Jerez &lt;currojerez@riseup.net&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/ttm: Add sysfs interface to control pool allocator.</title>
<updated>2010-04-06T01:36:18Z</updated>
<author>
<name>Pauli Nieminen</name>
<email>suokkos@gmail.com</email>
</author>
<published>2010-04-01T12:45:03Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=c96af79e3463d5d3f865625baa8bb8aa4c0944a0'/>
<id>urn:sha1:c96af79e3463d5d3f865625baa8bb8aa4c0944a0</id>
<content type='text'>
Sysfs interface allows user to configure pool allocator functionality and
change limits for the size of pool.

Signed-off-by: Pauli Nieminen &lt;suokkos@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/ttm: Add debugfs output entry to pool allocator.</title>
<updated>2010-04-06T01:35:45Z</updated>
<author>
<name>Pauli Nieminen</name>
<email>suokkos@gmail.com</email>
</author>
<published>2010-04-01T12:44:58Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=0745866165598b067442c472911280527b08be3e'/>
<id>urn:sha1:0745866165598b067442c472911280527b08be3e</id>
<content type='text'>
ttm_page_alloc_debugfs can be registered to output the state
of pools.

Debugfs file will output number of pages freed from the pool,
number of pages in pool now and the lowes number of pages in
pool since previous shrink.

Signed-off-by: Pauli Nieminen &lt;suokkos@gmail.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/ttm: add pool wc/uc page allocator V3</title>
<updated>2010-04-06T01:35:26Z</updated>
<author>
<name>Pauli Nieminen</name>
<email>suokkos@gmail.com</email>
</author>
<published>2010-04-01T12:44:57Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=1403b1a38e8b19a4cc17e2c158e278628943a436'/>
<id>urn:sha1:1403b1a38e8b19a4cc17e2c158e278628943a436</id>
<content type='text'>
On AGP system we might allocate/free routinely uncached or wc memory,
changing page from cached (wb) to uc or wc is very expensive and involves
a lot of flushing. To improve performance this allocator use a pool
of uc,wc pages.

Pools are protected with spinlocks to allow multiple threads to allocate pages
simultanously. Expensive operations are done outside of spinlock to maximize
concurrency.

Pools are linked lists of pages that were recently freed. mm shrink callback
allows kernel to claim back pages when they are required for something else.

Fixes:
* set_pages_array_wb handles highmem pages so we don't have to remove them
  from pool.
* Add count parameter to ttm_put_pages to avoid looping in free code.
* Change looping from _safe to normal in pool fill error path.
* Initialize sum variable and make the loop prettier in get_num_unused_pages.

* Moved pages_freed reseting inside the loop in ttm_page_pool_free.
* Add warning comment about spinlock context in ttm_page_pool_free.

Based on Jerome Glisse's and Dave Airlie's pool allocator.

Signed-off-by: Jerome Glisse &lt;jglisse@redhat.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
Signed-off-by: Pauli Nieminen &lt;suokkos@gmail.com&gt;
Reviewed-by: Jerome Glisse &lt;jglisse@redhat.com&gt;
Signed-off-by: Dave Airlie &lt;airlied@redhat.com&gt;
</content>
</entry>
</feed>
