Received: by 10.192.165.156 with SMTP id m28csp1414160imm; Wed, 11 Apr 2018 19:20:05 -0700 (PDT) X-Google-Smtp-Source: AIpwx4//6MiUODybUehgVhNKH+jr07N9F2kTsPc9vW6pyQ0/sn5gtnAnkBPwVmFBgK4qcF0bg8bQ X-Received: by 10.98.10.156 with SMTP id 28mr6045852pfk.33.1523499605706; Wed, 11 Apr 2018 19:20:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523499605; cv=none; d=google.com; s=arc-20160816; b=bxEKfsl2bFwF3mLH2GlYP9Rj3jE9aaWv3X5rdhmU1WG2Yk5ehFOdE3S2mzToMEG/pW YZrIXSZ9zBr69nUnFqJRvxAXARN3P4nBCqGX7+X1SAJevPoMdvKFxkYHsNfXjHPfUxOi YRwfV54UXc2L5a+xIqwxGr6OEOfkyZLULM2+Hs2ypLcRiJpcjyv5u5T7Xk/O3p8VpKQH RVew0npqutRkKcc1ZzOBzoKkp11Wu8jkvQHgbIrUbKoXvChnv29XUKF9eTXclAPEm46Y 9USPd+v7D5gdWGmQmMEGUCG8p52pqCrRfJcNQh1qBzD5StQWHN5ZI4Pq4C/YdRSEvxmD TfHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=9ymb+8zJQVzyqsVPop1wC11LQVJkmWdXIb0disCzzFg=; b=Gv6LIeNPNu79c4QwfxwpmHGMwbL5FOTCmuA9eBDWapXjrKTSmVHEGUhfeYLG6YuJXz p8XYU/UQ3CU8o8izszoZMMd9F/Zs/nm75lFzQ3W/sKVRJ+9qEaWYyG7rJrdE+KWDvA4z LlZBtBW+Mwf3+1bf+udYTrFEENTcmtJosoLnxgJOmHH+YiHtC+4eFVgC4ur/tUCV52wJ knr0yVDyoRzLtYwfSNbs36lKu05ehZYjpWBSJSmoYZt5cDS0jTj/uC44wD+zOZOoqO0S 3METzCwuGCwjWjfhfXOmTYMWolpPz9J0KUtIud4m8u9Ht+iLQ5XDYhFZac1kKO/VxCBq uLaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2017-10-26 header.b=gopCVyPY; 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=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s10si1626603pgc.129.2018.04.11.19.19.28; Wed, 11 Apr 2018 19:20:05 -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=@oracle.com header.s=corp-2017-10-26 header.b=gopCVyPY; 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=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752272AbeDLCQX (ORCPT + 99 others); Wed, 11 Apr 2018 22:16:23 -0400 Received: from aserp2130.oracle.com ([141.146.126.79]:51550 "EHLO aserp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751633AbeDLCQW (ORCPT ); Wed, 11 Apr 2018 22:16:22 -0400 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w3C2GBmT165034; Thu, 12 Apr 2018 02:16:16 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2017-10-26; bh=9ymb+8zJQVzyqsVPop1wC11LQVJkmWdXIb0disCzzFg=; b=gopCVyPY+jsal91gBca13NrcVTewUfB4qQV9bS7tQl8UIGyieGUmIGL3GBRna47XA1cT wGWuDSrY4CQCcQ7KGxJuRNJp9YfZCpw7Bj7eAmWXSzbFNJMhyjagp0WJ6YcXUongdc4h iUhtJLiXOFckOPs3ACJZe+yr9vCCqKzn/PyrJC9UqS+4NI5twNswzUygJRil3YYrSQvO xQ+ts/M9Wvdlunhk5XNWt1Z93Zkz6LQNpDISYpFxja629NyR9y9jm3vteNnCpZRxBdJr bHNFfnad/YWk341j7JlV04LJzCcUK8SZgHbOhzPhCul6meWzCv3Q3QiDpa8uhtcV5z/7 BA== Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp2130.oracle.com with ESMTP id 2h6kgtj04q-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 12 Apr 2018 02:16:16 +0000 Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by aserv0021.oracle.com (8.14.4/8.14.4) with ESMTP id w3C2GFnD031603 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 12 Apr 2018 02:16:15 GMT Received: from abhmp0017.oracle.com (abhmp0017.oracle.com [141.146.116.23]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id w3C2GEIX022976; Thu, 12 Apr 2018 02:16:14 GMT Received: from [10.39.212.185] (/10.39.212.185) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 11 Apr 2018 19:16:14 -0700 Subject: Re: [PATCH 1/4] xen: xen-pciback: Replace GFP_ATOMIC with GFP_KERNEL in pcistub_probe To: Jia-Ju Bai , jgross@suse.com, gregkh@linuxfoundation.org Cc: xen-devel@lists.xenproject.org, linux-kernel@vger.kernel.org References: <1523286216-26345-1-git-send-email-baijiaju1990@gmail.com> From: Boris Ostrovsky Message-ID: <7096e165-3f2b-3c81-f59a-c9a96cef22ef@oracle.com> Date: Wed, 11 Apr 2018 22:16:12 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <1523286216-26345-1-git-send-email-baijiaju1990@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8860 signatures=668698 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1804120022 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/09/2018 11:03 AM, Jia-Ju Bai wrote: > pcistub_probe() is never called in atomic context. > This function is only set as ".probe" in struct pci_driver. > > Despite never getting called from atomic context, > pcistub_probe() calls kmalloc() with GFP_ATOMIC, > which does not sleep for allocation. > GFP_ATOMIC is not necessary and can be replaced with GFP_KERNEL, > which can sleep and improve the possibility of sucessful allocation. > > This is found by a static analysis tool named DCNS written by myself. > And I also manually check it. > > Signed-off-by: Jia-Ju Bai For all 5 patches: Reviewed-by: Boris Ostrovsky