diff options
| author | Sowmini Varadhan <sowmini.varadhan@oracle.com> | 2015-04-21 10:30:41 -0400 |
|---|---|---|
| committer | Moyster <oysterized@gmail.com> | 2016-08-26 19:17:17 +0200 |
| commit | 929ff8565b9aa77d8581214fef4884fedc54e7e8 (patch) | |
| tree | 1482d975254493452cf64bb6674c39f27319763a /arch | |
| parent | 6cc98d8e5381a1c4154666c75b5280afb0f8e946 (diff) | |
sparc: Use GFP_ATOMIC in ldc_alloc_exp_dring() as it can be called in softirq context
Upstream commit 671d773297969bebb1732e1cdc1ec03aa53c6be2
Since it is possible for vnet_event_napi to end up doing
vnet_control_pkt_engine -> ... -> vnet_send_attr ->
vnet_port_alloc_tx_ring -> ldc_alloc_exp_dring -> kzalloc()
(i.e., in softirq context), kzalloc() should be called with
GFP_ATOMIC from ldc_alloc_exp_dring.
Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Stefan Guendhoer <stefan@guendhoer.com>
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/sparc/kernel/ldc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sparc/kernel/ldc.c b/arch/sparc/kernel/ldc.c index fa4c900a0..62983d774 100644 --- a/arch/sparc/kernel/ldc.c +++ b/arch/sparc/kernel/ldc.c @@ -2306,7 +2306,7 @@ void *ldc_alloc_exp_dring(struct ldc_channel *lp, unsigned int len, if (len & (8UL - 1)) return ERR_PTR(-EINVAL); - buf = kzalloc(len, GFP_KERNEL); + buf = kzalloc(len, GFP_ATOMIC); if (!buf) return ERR_PTR(-ENOMEM); |
