Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp3043180pxb; Mon, 18 Apr 2022 14:17:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyG+QN1toFH2DJO2J0AEXOSNHeFaLtafEkosXdr9FqypDQBLA3gfJjR+ItsuV/4dFGGWTfZ X-Received: by 2002:a17:907:868c:b0:6e8:d608:bcc7 with SMTP id qa12-20020a170907868c00b006e8d608bcc7mr10717553ejc.148.1650316648708; Mon, 18 Apr 2022 14:17:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650316648; cv=none; d=google.com; s=arc-20160816; b=WEJhAoI26d9MPZ/Pt2FUxYMgCeLopkIpwSxu6fptGBiegK6xBQf3FnTG8sqxAHtAAn Y+M4hcPP3VjBnXrRLhuNPeyqgMXgZtzfa1OtDZTvLkZvyLHxp0JYvuABfwxQIonuT6Ur MRTD1GTPYGoFmaCwv/dGGDnNhi4fnlbeFzSW8UTCgtfsZqo56mlXYgNoneXrADwnqTkf qyvJqjF/RR1iDcK/ooEdf0hWJYYK80c3cV1b2G6gIJJk7POdoh8lxD99wlLi8/bIPC4p zsu9xCHS3VwB/Zeen7g9oi5d9kN46Om008E1lkdOmsj2q4eS8pq/zWsyNS0cAxtoIio3 iEsA== 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:message-id:date:subject:cc:to :from:dkim-signature; bh=wyGFe0XWmaD3qJ02rRPT4rnY5Wysgh47T02sOmUjMvo=; b=gFnLNyVMlwal6CuZKj07GmuHaFsXyH4LixTlfDc915f7HSAR97NyuYjLo7sFLB8XYQ kecygiXppSw7+U/KhFPLYDM08YnDB2r/8gvn8+PsOaZ9qaJeqwO/zvqFjhRpn9SKAkJH W5xmtWWo+0f+sfajpuCUP0Xo1AUuwqFMBDDBGllv2J/T776MyWS1zuV3JUewSIf+Wo2l QfVffoOXL455yP2tk2In6icFT6CcnPaQoAd7jrlcgOusQcw7G9SCU/2UlCTne9vGy6QC 9mf6zSH389f8bPx6pxv1MsHOkHSpHiKlPoCC5kgNAZQHXIk3AH7mHvCDiaGNVr8Zu2S0 hWdQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=o8stmyzm; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ej11-20020a056402368b00b0041d7ac1b8ccsi6628824edb.36.2022.04.18.14.17.03; Mon, 18 Apr 2022 14:17:28 -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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=o8stmyzm; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244632AbiDRNpL (ORCPT + 99 others); Mon, 18 Apr 2022 09:45:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43480 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241396AbiDRNVP (ORCPT ); Mon, 18 Apr 2022 09:21:15 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 896BD140D6; Mon, 18 Apr 2022 05:52:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 0F4EEB80E44; Mon, 18 Apr 2022 12:52:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5930AC385A1; Mon, 18 Apr 2022 12:52:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1650286350; bh=oDCLpOGgBcPsxVODLiGPdcn9SR76ABDkisKl8yt2qy8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=o8stmyzmxQm5bKbfwm3D/SOFAqsPG68zioFvX4cBa2or2SxBPkl4OSnWDdiygfmua dOV3r/WvZOGhOgrLZx5FeuLfjRYfH3X2K5q3AMvJBkhiG80QPntTH/wDtq/QivtyLr OTyibfjtrdErdjJOUQLaSaWGiIo0NT1JLJ6nGTdo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, John Garry , Jack Wang , Damien Le Moal , "Martin K. Petersen" , Sasha Levin Subject: [PATCH 4.14 107/284] scsi: pm8001: Fix payload initialization in pm80xx_set_thermal_config() Date: Mon, 18 Apr 2022 14:11:28 +0200 Message-Id: <20220418121213.945201259@linuxfoundation.org> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220418121210.689577360@linuxfoundation.org> References: <20220418121210.689577360@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 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 From: Damien Le Moal [ Upstream commit bb225b12dbcc82d53d637d10b8d70b64494f8c16 ] The fields of the set_ctrl_cfg_req structure have the __le32 type, so use cpu_to_le32() to assign them. This removes the sparse warnings: warning: incorrect type in assignment (different base types) expected restricted __le32 got unsigned int Link: https://lore.kernel.org/r/20220220031810.738362-8-damien.lemoal@opensource.wdc.com Fixes: 842784e0d15b ("pm80xx: Update For Thermal Page Code") Fixes: f5860992db55 ("[SCSI] pm80xx: Added SPCv/ve specific hardware functionalities and relevant changes in common files") Reviewed-by: John Garry Reviewed-by: Jack Wang Signed-off-by: Damien Le Moal Signed-off-by: Martin K. Petersen Signed-off-by: Sasha Levin --- drivers/scsi/pm8001/pm80xx_hwi.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/pm8001/pm80xx_hwi.c b/drivers/scsi/pm8001/pm80xx_hwi.c index 162b819f3a89..cf037e076235 100644 --- a/drivers/scsi/pm8001/pm80xx_hwi.c +++ b/drivers/scsi/pm8001/pm80xx_hwi.c @@ -870,9 +870,11 @@ pm80xx_set_thermal_config(struct pm8001_hba_info *pm8001_ha) else page_code = THERMAL_PAGE_CODE_8H; - payload.cfg_pg[0] = (THERMAL_LOG_ENABLE << 9) | - (THERMAL_ENABLE << 8) | page_code; - payload.cfg_pg[1] = (LTEMPHIL << 24) | (RTEMPHIL << 8); + payload.cfg_pg[0] = + cpu_to_le32((THERMAL_LOG_ENABLE << 9) | + (THERMAL_ENABLE << 8) | page_code); + payload.cfg_pg[1] = + cpu_to_le32((LTEMPHIL << 24) | (RTEMPHIL << 8)); rc = pm8001_mpi_build_cmd(pm8001_ha, circularQ, opc, &payload, 0); if (rc) -- 2.34.1