Received: by 2002:ab2:3141:0:b0:1ed:23cc:44d1 with SMTP id i1csp1713954lqg; Mon, 4 Mar 2024 01:06:46 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUjYCi84QIuiIq9LhT8RCr+j3jCc+XFurc1bIuv6QnVIIQ5D0XBNRvDimqLfuNlyLJolZfUE9P3azNZfp/JyEEihjiK2mHr/uaQmn4wHA== X-Google-Smtp-Source: AGHT+IHjYftvkQHqX7wieqH2ADk/NjKvN6sI3WZu2ilpuHvNrhRQK15R0F8Vqqm7GEMbjyBShOFa X-Received: by 2002:ac8:5d93:0:b0:42e:7e4d:9b68 with SMTP id d19-20020ac85d93000000b0042e7e4d9b68mr19831459qtx.18.1709543205680; Mon, 04 Mar 2024 01:06:45 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709543205; cv=pass; d=google.com; s=arc-20160816; b=whSfwDvLZs1G2kdoMHHZ6tjeqi2res86gDyqVRTDMktMNeXmlmARPXnGIIGTMFP/Ec mPNzdzfokP8bcIb/n24Fcj99mlQGJ70ejshfbWxeKvHYV8DRevsyrMJA/7iR6I9/AAmD vNpQVOcNH1cxjuW4hZ7tqST0u6cRusMlDtGUHbYZcOrLUAMN68NvPwj+s0krIY4HXb6T dPrHoy4UHpXnhCfa2CpV1OPTMzJ2AlvPyVfKERFuul+gKjhhDjnxQ9rIm60dq4nUlzi+ 1FnlQGGDNBJ3pjsZFya0zprqCmZGdYZX+DzQGnTVesx0/cT5NYnUG83frAv4Wx/wOrY7 2tZQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=uFv19ktCsgkd4P3lQ6Fotxm9cL6+Yn5nRM/MlIHO8RA=; fh=KjgQo1wrCvZYydXzDdCwRCQBa3U7cwe/h3vhSPRQBtI=; b=0m1DWJxZ6oojC+u+GuXIdG/rZhHtfUjvJ8IUJI+PWAnzFzR312x5k4ZXazg30fYIiO 7ddLkXdJT5gNz/hSkqQ3BDFAxo8C8GLmhDR+aUQcnOyr8Ov6TJXpf4G/AWQc9/Bhwi+H vpWalABfIfx70hx5qlrRSNo6GBT8fq0sVYMQk/X2He2EUyeET8oSnpdy1HtoUgRXBpzP ce5QSg3+YShQTTNdzH0mmG8cJPYiePv93mfBfi+zgFCPUzSGUXmJgAqPSHosXuVga1xM apoheAIid2YjvICnzurUpW7nA6Mu+2kr9m3OPXLKPh7ZL35v+bFWZM3WiO1epNvH3UBC rzrw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=GAj+fQta; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-90273-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-90273-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id w5-20020a05622a134500b0042ef6c73c88si581968qtk.718.2024.03.04.01.06.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Mar 2024 01:06:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-90273-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=GAj+fQta; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-90273-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-90273-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6A5FD1C2217B for ; Mon, 4 Mar 2024 09:06:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B0CE61C2AE; Mon, 4 Mar 2024 09:06:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="GAj+fQta" Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 625501A58B; Mon, 4 Mar 2024 09:06:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709543191; cv=none; b=HqbEkQuM9VLg2nFbyDeCkMWI8Meo3iqu3hi/x7JeUUnltzNH3TJ6vwu/ZBQJOVOnjw2a/syJ0jEdzmBHu2fP4ZOltJoIyuSf9F7RaaNaPf7aGahrbiMq/y9sZw7p5Zx0MYYrgGEGcNA1PpjBIOvjnNaY6kwWlJqZvLndokw4a+s= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709543191; c=relaxed/simple; bh=GCuw5Sm9pjw8RPsF+AZn1B/kTPwUEgdiAsqcOZ4ANW4=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=V+F0nfqV8n4FGanRatN6e+RD5tQd1kgVzUdAmD9AixJ750rsGuWF/warwoy21g5Ndo3xgPt5HhFGZHu9TLZrqv8/T6O4k6/QAm1bWDB+zpnPfi5NCagiPsSCvv74wdL5H3bvJASyCU22hZofLv0KRlPE+bgvTqbnvNiOnrd2984= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=GAj+fQta; arc=none smtp.client-ip=46.235.227.194 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1709543188; bh=GCuw5Sm9pjw8RPsF+AZn1B/kTPwUEgdiAsqcOZ4ANW4=; h=From:To:Cc:Subject:Date:From; b=GAj+fQtaM6u3iin5ZbT5b0HjMjDpd/odSbjNw77qL0jim7x03ptPzJ3bAn2cN7C4R RUhQyBKG4m5ZeDvxb18qKB6sFfIH9e90sYI+neWLEe6F0yURn8zBzKGUulqISlmwBQ XxV3K0kgY+E6imnSaPWHGnyw36w4DWbvtI3BR88NCiRrDf8hY02+T+Zaj2sAag6Kot Gz96q1i1YBfXSQGnD7tdvpdbhT+gdyoLdJWooHAMAzWI8tAPFk+Noj//Q/Cutvcgih 6RpS3PiGj43mprxgFFChFZ4PPKIBfO6NH4UM4Rq7JnY4NYOWP6rS0m6sAnm00Kmk68 EBHE8sb39w5dQ== Received: from localhost.localdomain (broslavsky.collaboradmins.com [68.183.210.73]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: usama.anjum) by madrid.collaboradmins.com (Postfix) with ESMTPSA id BD3A53781FE9; Mon, 4 Mar 2024 09:06:25 +0000 (UTC) From: Muhammad Usama Anjum To: James Smart , Dick Kennedy , "James E.J. Bottomley" , "Martin K. Petersen" , Hannes Reinecke Cc: Muhammad Usama Anjum , kernel@collabora.com, kernel-janitors@vger.kernel.org, James Smart , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] scsi: lpfc: correct size for wqe for memset Date: Mon, 4 Mar 2024 14:06:48 +0500 Message-Id: <20240304090649.833953-1-usama.anjum@collabora.com> X-Mailer: git-send-email 2.39.2 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The wqe is of type lpfc_wqe128. It should be memset with the same type. Fixes: 6c621a2229b0 ("scsi: lpfc: Separate NVMET RQ buffer posting from IO resources SGL/iocbq/context") Signed-off-by: Muhammad Usama Anjum --- Changes since v1: - Use *wqe instead of type to find sizeof --- drivers/scsi/lpfc/lpfc_nvmet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/lpfc/lpfc_nvmet.c b/drivers/scsi/lpfc/lpfc_nvmet.c index 8258b771bd009..561ced5503c63 100644 --- a/drivers/scsi/lpfc/lpfc_nvmet.c +++ b/drivers/scsi/lpfc/lpfc_nvmet.c @@ -1586,7 +1586,7 @@ lpfc_nvmet_setup_io_context(struct lpfc_hba *phba) wqe = &nvmewqe->wqe; /* Initialize WQE */ - memset(wqe, 0, sizeof(union lpfc_wqe)); + memset(wqe, 0, sizeof(*wqe)); ctx_buf->iocbq->cmd_dmabuf = NULL; spin_lock(&phba->sli4_hba.sgl_list_lock); -- 2.39.2