[<prev] [next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.20.1708052328140.2025@hadrien>
Date: Sat, 5 Aug 2017 23:32:37 +0200 (CEST)
From: Julia Lawall <julia.lawall@...6.fr>
To: Brendan Higgins <brendanhiggins@...gle.com>
cc: corbet@....net, kbuild-all@...org, robh+dt@...nel.org,
mark.rutland@....com, arnd@...db.de, gregkh@...uxfoundation.org,
minyard@....org, joel@....id.au, benh@...nel.crashing.org,
benjaminfair@...gle.com, linux-doc@...r.kernel.org,
devicetree@...r.kernel.org,
openipmi-developer@...ts.sourceforge.net, openbmc@...ts.ozlabs.org,
linux-kernel@...r.kernel.org,
Brendan Higgins <brendanhiggins@...gle.com>
Subject: [PATCH] ipmi: bt-i2c: fix call_kern.cocci warnings
Function handle_request called from bt_i2c_slave_cb with bt_slave->lock
held but uses GFP_KERNEL. Replace GFP_KERNEL by GFP_ATOMIC.
Generated by: scripts/coccinelle/locks/call_kern.cocci
Fixes: acd0208e3557 ("ipmi: bt-i2c: added IPMI Block Transfer over I2C BMC side")
CC: Brendan Higgins <brendanhiggins@...gle.com>
Signed-off-by: Julia Lawall <julia.lawall@...6.fr>
Signed-off-by: Fengguang Wu <fengguang.wu@...el.com>
---
url:
https://github.com/0day-ci/linux/commits/Brendan-Higgins/ipmi-bt-i2c-added-IPMI-Block-Transfer-over-I2C/20170806-034713
ipmi_bmc_bt_i2c.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/char/ipmi_bmc/ipmi_bmc_bt_i2c.c
+++ b/drivers/char/ipmi_bmc/ipmi_bmc_bt_i2c.c
@@ -201,7 +201,7 @@ static int handle_request(struct bt_i2c_
if (atomic_read(&bt_slave->request_queue_len) >= request_queue_max_len)
return -EFAULT;
- queue_elem = kmalloc(sizeof(*queue_elem), GFP_KERNEL);
+ queue_elem = kmalloc(sizeof(*queue_elem), GFP_ATOMIC);
if (!queue_elem)
return -ENOMEM;
memcpy(&queue_elem->request, &bt_slave->request, sizeof(struct bt_msg));
Powered by blists - more mailing lists