Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp416932imm; Thu, 28 Jun 2018 23:28:48 -0700 (PDT) X-Google-Smtp-Source: ADUXVKJi2AgIjqjvd+ELyo8ALjMYjQn+uU5SQB26CpRIxz+Eu6SOVzCpD8UoiPc6lCCfPpRk8Ixe X-Received: by 2002:a17:902:2f84:: with SMTP id t4-v6mr13602858plb.24.1530253728467; Thu, 28 Jun 2018 23:28:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530253728; cv=none; d=google.com; s=arc-20160816; b=ehtU8UyQFWp0C8SjQ8uz3MMhudO/FZ/vu+To5Wd7wrNLKZT95a3WPEbh+efWcPqB8R U94yjEqnZhPZNfD9OfAdPgU3vmKaBtxMOAoE7syKHNhOs0tVYLhfxKzkXrKAoeQ17CSi YI79AV9aKde5Pv/2wcqFUtiJYJfErKceCyDHotypDaBgrRLHTUppv0sZzI5nqwbPRug2 7GYeDnYKCvuzIj4YPjrbgeBHviURVJMptjoSO96XA9GO6slrxfOglcDhV7JVgGU0AWPo 3S2aMZJ9kvGhrPggGdIh062PGBJgoPM9nII5qM5DRGUlLRLJXo3aBJVzXH5eSCZViVeL h7Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=jJ0HvTuii/tj87M4Greg6e4RuT0tIJ3zCHzr8ED8vI8=; b=r9NePMllHEKW3UuHpGNwqki5E/Mc7OxvbUc5PKVtKAk4eWc3fNTh1uwwGeoBAbbS0m X7g/dB0KBKy5h2pm0+UtpEZprgQLY9dYC5qNY9xNftW+X5VGm/Ii8PWL5JJfIhc6f8yq ODDocNROTLI5isbwpF9EdJNS1PYoQGoaPIhS+3daJlK/c/5HbwLHq8c65ohxiNJog7/f 9Ace3h3O54QPyxokLYtim+fTijY1czxzYpATcYtAj9YFSmVLVvAxASwQCHzY2zU5xmW7 rzbjXHaubWcgxf4IMLLKWi/e2fx7gFjqb9ZCg2wMLqekZnuVJOrAytDGYUWcFapvMfaH p3+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=vOPJMIjI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m4-v6si7181147pgp.512.2018.06.28.23.28.34; Thu, 28 Jun 2018 23:28:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=vOPJMIjI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S967344AbeF1XvW (ORCPT + 99 others); Thu, 28 Jun 2018 19:51:22 -0400 Received: from mail-wm0-f66.google.com ([74.125.82.66]:36724 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S967125AbeF1XvT (ORCPT ); Thu, 28 Jun 2018 19:51:19 -0400 Received: by mail-wm0-f66.google.com with SMTP id u18-v6so244344wmc.1; Thu, 28 Jun 2018 16:51:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=jJ0HvTuii/tj87M4Greg6e4RuT0tIJ3zCHzr8ED8vI8=; b=vOPJMIjIxgYysNTA4DOcMDN5aUk8U14J7pxvIZhR5tMzEB76KmvOoVsz9T9fT2zGrm FT7Woh5jPK2YyZHuWAesV6cddtR6nw/QSH7CGevDGG9e2V+1CflsntKLxH9t6IJls+J3 Neft3JT18W4djrVnU4H+kpyWCqhtCDoJR7q56KwhL0uIOCwZtU/P4Lo9prOVjBo0dEML R7IRlQOsfAvEy7b1lkarnjWFfbs0MPdOyN3D5fKPB7NVSwN57ySWrNTxYfT8xzndGdPz INdxIUkvB8RWuOAfRxez9QabPfwsK0o0R6f9miV4rDt0mUF7Qf1QVQp9Z1G1v3uaHyCv Efpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=jJ0HvTuii/tj87M4Greg6e4RuT0tIJ3zCHzr8ED8vI8=; b=reDhrysMfS/DrX5hRurQF3aEyR7XMP0RiAp+L7qt+XUpBwanZJP6SAORRwxhrlO69H AMgoGsUS+Xel8wlZbmVK6Z75V+G/OPYo1m9lKzZEblxHl5GK9alAhKgWcc9/qV9DW0We VEeKliKid6nR68KrkCfvx45ZDujQNpOaFf7gvylJUapXb65piO8OdjbTnVt3iDUwvLu/ tTIqJStKphUQf0LeNYNL8ZXPeH1eAg4c17jGwucLRbMPH2B91PwS7uRN5FnGXf4GA2jX m2hDpZFf6YAsIkjGOaE1ZUBzKexAZXXX2h53IlzPvw1lPCw2NqTnTSAoKrXvUx29G48S gabQ== X-Gm-Message-State: APt69E37kjd46YqplSI4/8Ktk4IhDxXVGg6HsLLYdKgTEO6DsYRj76pK +kmHCpOo0nt4ZUwRIlOIv1c= X-Received: by 2002:a1c:7fc1:: with SMTP id a184-v6mr14065wmd.161.1530229878542; Thu, 28 Jun 2018 16:51:18 -0700 (PDT) Received: from localhost.localdomain ([156.219.234.99]) by smtp.gmail.com with ESMTPSA id z14-v6sm9561863wrm.49.2018.06.28.16.51.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 28 Jun 2018 16:51:17 -0700 (PDT) From: Karim Eshapa To: lars@metafoo.de Cc: Michael.Hennerich@analog.com, jic23@kernel.org, knaack.h@gmx.de, pmeerw@pmeerw.net, gregkh@linuxfoundation.org, linux-iio@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, Karim Eshapa Subject: [PATCH] staging:iio:adc:ad7280a: Use GFP_ATOMIC in interrupt handler Date: Fri, 29 Jun 2018 01:51:00 +0200 Message-Id: <20180628235100.4294-1-karim.eshapa@gmail.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use GFP_ATOMIC rather GFP_KERNEL in interrupt handler, as GFP_KERNEL may sleep according to slab allocator. Signed-off-by: Karim Eshapa --- drivers/staging/iio/adc/ad7280a.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/iio/adc/ad7280a.c b/drivers/staging/iio/adc/ad7280a.c index b736275c10f5..25c4fbc303f7 100644 --- a/drivers/staging/iio/adc/ad7280a.c +++ b/drivers/staging/iio/adc/ad7280a.c @@ -692,7 +692,7 @@ static irqreturn_t ad7280_event_handler(int irq, void *private) unsigned int *channels; int i, ret; - channels = kcalloc(st->scan_cnt, sizeof(*channels), GFP_KERNEL); + channels = kcalloc(st->scan_cnt, sizeof(*channels), GFP_ATOMIC); if (!channels) return IRQ_HANDLED; -- 2.17.1