Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp2032545pxp; Sun, 13 Mar 2022 07:00:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwntXf36Kagn/aBqikr3wgxVvzlznkr8fatS/bpaSo7Eisxjr2tVEjh3yxLXGI5hJH9athQ X-Received: by 2002:a17:90a:5291:b0:1bb:ef4d:947d with SMTP id w17-20020a17090a529100b001bbef4d947dmr31342244pjh.243.1647180051640; Sun, 13 Mar 2022 07:00:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647180051; cv=none; d=google.com; s=arc-20160816; b=xYHtSOjN9jCNy6NvCgtPHMjvKmKjhW0Gu8BrK7j613o06LXl4lXbLPrxATmlZIuo08 ewHGtnlsTMY9snLXwUy8KIa2Ob1nO24x4QeAsfkg5DlF9W64YmNlLmAVvSl5LrCtOCew 4GOef2JIik7lenInioF0JGa1EQILHHTLzi4BsSomrs2Neq7L019OjHrXPedMD8BDK09q DwHPOyBGu7XPiZx4bUH+wBfKng+0fTvVrD3Pv0B5ivZEvVP3W9OG4xYuZNg5O1sZ14BW MfuHYM0gB89SyP5WyQlOsPpsqsZhuRqPBXFtK3lIyvCeekOpcFkAn6j3DIsxXHUUZQSw ZibQ== 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 :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=mJZOcqONdsTivb4Wn89GbBX+1gB39PSN6b6Oumws+LI=; b=qYDS/dHZqVgF5xjfhDZu0vt6e98LjtntZ/QpnQEHImfKlvsj2+aiWQCkgVl9X9+8o6 5RuBjdEW22WQ8nnv3VjdKj0xFmEpvFZet8uEP9I6Wmkpky5UVfCye0LEKMvS8JLwFvf8 gpZmbucNbonL45+w0DRmkyOs3J/HRI3MFZJNozgYZ9HVK1pDNHOfOhXv5Xa6KPAInOzw GBGgyWtE5cAqtc8NI66ZANAw4kcxbHZhNMVD++hwJWUm5Gxynf7oUb5h/qbOfG/s27TU BhUuXf8sHJjLlGECzd1uKQXRTBsLowHTg6PQiu/AeiWK0f69U3kb2FcraTFyMuyX4S91 uUxg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d7-20020a056a0010c700b004f72f321f0asi13751664pfu.147.2022.03.13.07.00.31; Sun, 13 Mar 2022 07:00:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232787AbiCLVqR (ORCPT + 99 others); Sat, 12 Mar 2022 16:46:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41484 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232730AbiCLVqQ (ORCPT ); Sat, 12 Mar 2022 16:46:16 -0500 Received: from relay.hostedemail.com (relay.a.hostedemail.com [64.99.140.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71C496E4D3; Sat, 12 Mar 2022 13:45:10 -0800 (PST) Received: from omf09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 0F8BD20EF6; Sat, 12 Mar 2022 21:45:09 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: joe@perches.com) by omf09.hostedemail.com (Postfix) with ESMTPA id 8F47420028; Sat, 12 Mar 2022 21:45:02 +0000 (UTC) Message-ID: <846e22e76ba9e4c620df159b073bbf4e058a35f0.camel@perches.com> Subject: Re: [PATCH 4/6] scsi: lpfc: use kzalloc From: Joe Perches To: Julia Lawall , James Smart Cc: kernel-janitors@vger.kernel.org, Dick Kennedy , "James E.J. Bottomley" , "Martin K. Petersen" , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Date: Sat, 12 Mar 2022 13:45:01 -0800 In-Reply-To: <20220312102705.71413-5-Julia.Lawall@inria.fr> References: <20220312102705.71413-1-Julia.Lawall@inria.fr> <20220312102705.71413-5-Julia.Lawall@inria.fr> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.40.4-1ubuntu2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Stat-Signature: p6yih6y7q3hu9hsxzjjetq7mn7b659cd X-Rspamd-Server: rspamout07 X-Rspamd-Queue-Id: 8F47420028 X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FORGED_SPF_HELO, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_NONE, T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=no autolearn_force=no version=3.4.6 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Session-ID: U2FsdGVkX19DJWJu0mr74IBHBM/nl8mkWSl5saQ3BR8= X-HE-Tag: 1647121502-545075 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 2022-03-12 at 11:27 +0100, Julia Lawall wrote: > Use kzalloc instead of kmalloc + memset. [] > diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_debugfs.c [] > @@ -6272,10 +6272,8 @@ lpfc_debugfs_initialize(struct lpfc_vport *vport) > phba->hba_debugfs_root, > phba, &lpfc_debugfs_op_slow_ring_trc); > if (!phba->slow_ring_trc) { > - phba->slow_ring_trc = kmalloc( > - (sizeof(struct lpfc_debugfs_trc) * > - lpfc_debugfs_max_slow_ring_trc), > - GFP_KERNEL); > + phba->slow_ring_trc = kzalloc((sizeof(struct lpfc_debugfs_trc) * lpfc_debugfs_max_slow_ring_trc), > + GFP_KERNEL); kcalloc