From patchwork Wed Jun 16 06:36:58 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Leizhen \(ThunderTown\)" X-Patchwork-Id: 461356 Delivered-To: patch@linaro.org Received: by 2002:a02:735a:0:0:0:0:0 with SMTP id a26csp312861jae; Tue, 15 Jun 2021 23:37:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxcxB5tDVcbVdX9kFvs7JafcTiJ1kfJOaIZ53YOK38g//+D0vDTUgZfLdLhmyDGfOrNJAG9 X-Received: by 2002:a05:6402:885:: with SMTP id e5mr2359502edy.248.1623825477994; Tue, 15 Jun 2021 23:37:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623825477; cv=none; d=google.com; s=arc-20160816; b=BhvxCYBwid9m3Idba3L0ljVvnh37zVucZRbtBm1Rlkir0UMcsLciT3952abX7HLVf2 Eelu/GvkDy7PVMan0QIgpFbCP7Hv6WWRb/4whBgSWfEUU8aquFwqjfT++Yq1BGQD06TY ALcwjM1j1gFi9UwpAKKHM81pA0mqgH4fMDKVREiLajd5oAG9Co/bgztrIfuM756itwk1 vLmc0OSJWFAYVgyTFhm6H/XMT1qsxrE08i04ug9JLz8a1KwnHdNF1/RRA46a7ys+Gjp0 VTbei+aqXxMmSM+QbSGqUjJrO+odIsju7GdOTvgAGfAmOwAeBNOT6xqDrodhlQuAAVr5 HGlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=G21J6JnLifLbR1uduxQdwxTY2nuYrFg9UkgEIhNI4WE=; b=Tiy4jQB8q7MkJg31yGaCfqrYREodxB8UpbsgEedxGlQRl71zfcOktt+xaFVgYnMeQb KrozPHDvJzNzk0ny+x0bSc4LX6Yy52rxkq+G+YmcN2anRxe1MKH1ieCmnJpVpcNcuvRD LNU5ab/YrlRU9JpPHtylZhvJ8Cwm7beXTBY5+Hobo++PojsziRdlWrm3ppIoklrma+1E ekF4WuKgjfDJF4CFPCrMUEhNZdSUThsf3dnzbhlfBRHeNMdLotz8sHE+aoG9razVBCUH T1de1c37fXKcPOjp9qNHZTb/Yi1aORqEOLIER7uw4fwvuoLs3M1Uvb7ijl1wPtVDNjxR U5RA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z16si1386040edb.194.2021.06.15.23.37.57 for ; Tue, 15 Jun 2021 23:37:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-scsi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231344AbhFPGkC (ORCPT ); Wed, 16 Jun 2021 02:40:02 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:4928 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231290AbhFPGkA (ORCPT ); Wed, 16 Jun 2021 02:40:00 -0400 Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4G4b5J08jfz70KQ; Wed, 16 Jun 2021 14:34:44 +0800 (CST) Received: from dggpemm500006.china.huawei.com (7.185.36.236) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 16 Jun 2021 14:37:53 +0800 Received: from thunder-town.china.huawei.com (10.174.179.0) by dggpemm500006.china.huawei.com (7.185.36.236) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 16 Jun 2021 14:37:52 +0800 From: Zhen Lei To: Vishal Bhakta , VMware PV-Drivers , Karan Tilak Kumar , "Sesidhar Baddela" , Nilesh Javali , GR-QLogic-Storage-Upstream , "Adaptec OEM Raid Solutions" , Brian King , Satish Kharat , Hannes Reinecke , "Manish Rangankar" , Adam Radford , "James E . J . Bottomley" , "Martin K . Petersen" , linux-scsi CC: Zhen Lei Subject: [PATCH v2 04/20] scsi: vmw_pvscsi: remove unnecessary oom message Date: Wed, 16 Jun 2021 14:36:58 +0800 Message-ID: <20210616063714.778-5-thunder.leizhen@huawei.com> X-Mailer: git-send-email 2.26.0.windows.1 In-Reply-To: <20210616063714.778-1-thunder.leizhen@huawei.com> References: <20210616063714.778-1-thunder.leizhen@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.174.179.0] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpemm500006.china.huawei.com (7.185.36.236) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Fixes scripts/checkpatch.pl warning: WARNING: Possible unnecessary 'out of memory' message Remove it can help us save a bit of memory. Signed-off-by: Zhen Lei --- drivers/scsi/vmw_pvscsi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) -- 2.26.0.106.g9fadedd diff --git a/drivers/scsi/vmw_pvscsi.c b/drivers/scsi/vmw_pvscsi.c index ce1ba1b936298c7..78102969e9fe692 100644 --- a/drivers/scsi/vmw_pvscsi.c +++ b/drivers/scsi/vmw_pvscsi.c @@ -1304,10 +1304,8 @@ static u32 pvscsi_get_max_targets(struct pvscsi_adapter *adapter) dev = pvscsi_dev(adapter); config_page = dma_alloc_coherent(&adapter->dev->dev, PAGE_SIZE, &configPagePA, GFP_KERNEL); - if (!config_page) { - dev_warn(dev, "vmw_pvscsi: failed to allocate memory for config page\n"); + if (!config_page) goto exit; - } BUG_ON(configPagePA & ~PAGE_MASK); /* Fetch config info from the device. */ @@ -1479,7 +1477,6 @@ static int pvscsi_probe(struct pci_dev *pdev, const struct pci_device_id *id) adapter->cmd_map = kcalloc(adapter->req_depth, sizeof(struct pvscsi_ctx), GFP_KERNEL); if (!adapter->cmd_map) { - printk(KERN_ERR "vmw_pvscsi: failed to allocate memory.\n"); error = -ENOMEM; goto out_reset_adapter; }