Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp1486889ybh; Mon, 13 Jul 2020 21:59:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyW3irzZa6eDKAEdU+l85e16muJOnuP765IwhrLAVNP1RQFiW7dHXRIXOiiRRl4rldpyJNh X-Received: by 2002:a17:906:b2c8:: with SMTP id cf8mr2910705ejb.132.1594702798405; Mon, 13 Jul 2020 21:59:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594702798; cv=none; d=google.com; s=arc-20160816; b=zr+hUjFbttxqqx0DmlWKgKZxMRWa26hPy2FUalvgL1Nwc3VBkkNjevY0IyIT5/GSR/ RN7bnJOY1g5L8JYiNR4DgW7A+V9FTUibMLSCsCoLCkXp4HoU9Zg54KVdKQm5sc8ycPi5 zfty2XAGSqzxe8ZGRGySrnF0/EE43YQWoJRl/n/dORrjYBCz0IwgyaoBRGFLkG9tb6/0 /L+EQrcJbrnS4/3lYPXhdNf37BGPZVBV8ogbpOghzBRIUw6Bz/c/m+jK5azbmtU3Twnd PlxjnAkckVxzkYm9up9rUu+4Xr1zd1e0LAdajTNRjoKYQocNsJ6kRDpt8/ptqfV/iZrk cpYg== 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:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=8OamBc93tsElgQQ1UHHoc9Ay6yPCeE9e643okWZufPE=; b=EMysI9weOAIFhQeY0hKodkRM53Hc5OK2EN9fsbcC27hyJ3DCxSZeuW+0RBwca1NqDC B8vxgtwS3AaZEcJ5o01r6UanJUW8d5e8UCDRmeGVwIf6r8RfPwbgaqE77eJHQ8z/dayv pG/yEQJkxM3CZr55sIezMUTKQC8teysFCo6RpPXJPNdZFpZooeApyB9Yo1fkdt0FMfLX M8Z324V48LELRN6upyrWirPhZ/pz+kzgnG/O9jpE4oW1fYMJKh8jOO+ulfCh+qnPHAbW m5ufd+K898eGMGjR3eO9a22XfoKqPXItfYlYSQSTTWT4ga6b0UbgDfn0BFkc5lXNXq/6 ZQ6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=RcQ8N4yE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id l12si11570603edk.328.2020.07.13.21.59.35; Mon, 13 Jul 2020 21:59:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=RcQ8N4yE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1726619AbgGNE7S (ORCPT + 99 others); Tue, 14 Jul 2020 00:59:18 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:37726 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725884AbgGNE7R (ORCPT ); Tue, 14 Jul 2020 00:59:17 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 06E4utuQ172701; Tue, 14 Jul 2020 04:59:01 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=corp-2020-01-29; bh=8OamBc93tsElgQQ1UHHoc9Ay6yPCeE9e643okWZufPE=; b=RcQ8N4yE75AJIagGybBj1DOtp5WeLXeVMtnLPD7qSA1s9F8HbroJ3EngD0TfjMpAWiL5 bEklOkbecflIy1SNslBC8cOi2ixycHJaUezl+e56jtcDbOPKFloEvpG61tHxbi7LFBkS nICuMdIbIJ53L52lKTOizUedA+Ky6g65LdPWbAUBqJllz8LIDmJUR5vHbS0nk3DFdyuT wAI0q9Cwp3w/kO5lZUKSzfhV/ApSg74ldxDoXt48oBkWaxQrKklt7/oen8IICsN3A+DX VMoXc3mJVH3gLonR22yKfXRFGULbH11pQti19gK2zWrTOjQyh0xljI0yk+O1f7JAWZsj mA== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by aserp2120.oracle.com with ESMTP id 3275cm2x3c-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 14 Jul 2020 04:59:01 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 06E4vXKT174023; Tue, 14 Jul 2020 04:59:01 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3020.oracle.com with ESMTP id 327qb2nuud-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 14 Jul 2020 04:59:01 +0000 Received: from abhmp0019.oracle.com (abhmp0019.oracle.com [141.146.116.25]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 06E4wxg2025076; Tue, 14 Jul 2020 04:58:59 GMT Received: from ca-mkp.ca.oracle.com (/10.156.108.201) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 13 Jul 2020 21:58:59 -0700 From: "Martin K. Petersen" To: mst@redhat.com, pbonzini@redhat.com, jasowang@redhat.com, Xianting Tian , jejb@linux.ibm.com, stefanha@redhat.com Cc: "Martin K . Petersen" , virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org Subject: Re: [PATCH] scsi: virtio_scsi: remove unnecessary condition check Date: Tue, 14 Jul 2020 00:58:47 -0400 Message-Id: <159470266467.11195.10910825066875185491.b4-ty@oracle.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <1594307167-8807-1-git-send-email-xianting_tian@126.com> References: <1594307167-8807-1-git-send-email-xianting_tian@126.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9681 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=998 malwarescore=0 mlxscore=0 spamscore=0 phishscore=0 suspectscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2007140037 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9681 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 priorityscore=1501 bulkscore=0 adultscore=0 lowpriorityscore=0 phishscore=0 spamscore=0 impostorscore=0 malwarescore=0 mlxlogscore=999 clxscore=1011 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2007140037 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 9 Jul 2020 11:06:07 -0400, Xianting Tian wrote: > kmem_cache_destroy and mempool_destroy can correctly handle > null pointer parameter, so there is no need to check if the > parameter is null before calling kmem_cache_destroy and > mempool_destroy. Applied to 5.9/scsi-queue, thanks! [1/1] scsi: virtio_scsi: Remove unnecessary condition check https://git.kernel.org/mkp/scsi/c/92e8d0323a51 -- Martin K. Petersen Oracle Linux Engineering