Commit 714c9108 authored by Julian Wiedmann's avatar Julian Wiedmann Committed by David S. Miller

s390/qeth: use memory reserves to back RX buffers

Use dev_alloc_page() for backing the RX buffers with pages. This way we
pick up __GFP_MEMALLOC.
Signed-off-by: default avatarJulian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a58741ef
...@@ -244,7 +244,7 @@ static struct qeth_buffer_pool_entry *qeth_alloc_pool_entry(unsigned int pages) ...@@ -244,7 +244,7 @@ static struct qeth_buffer_pool_entry *qeth_alloc_pool_entry(unsigned int pages)
return NULL; return NULL;
for (i = 0; i < pages; i++) { for (i = 0; i < pages; i++) {
entry->elements[i] = alloc_page(GFP_KERNEL); entry->elements[i] = __dev_alloc_page(GFP_KERNEL);
if (!entry->elements[i]) { if (!entry->elements[i]) {
qeth_free_pool_entry(entry); qeth_free_pool_entry(entry);
...@@ -2654,7 +2654,7 @@ static struct qeth_buffer_pool_entry *qeth_find_free_buffer_pool_entry( ...@@ -2654,7 +2654,7 @@ static struct qeth_buffer_pool_entry *qeth_find_free_buffer_pool_entry(
struct qeth_buffer_pool_entry, list); struct qeth_buffer_pool_entry, list);
for (i = 0; i < QETH_MAX_BUFFER_ELEMENTS(card); ++i) { for (i = 0; i < QETH_MAX_BUFFER_ELEMENTS(card); ++i) {
if (page_count(entry->elements[i]) > 1) { if (page_count(entry->elements[i]) > 1) {
struct page *page = alloc_page(GFP_ATOMIC); struct page *page = dev_alloc_page();
if (!page) if (!page)
return NULL; return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment