Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp408251pxu; Tue, 1 Dec 2020 14:31:14 -0800 (PST) X-Google-Smtp-Source: ABdhPJxtTywynvyZ455+HXDA0D28Pw/gga0RflcBXcQNg2FThfuoUD+4mTKEJ6+MbSUaJ9S0NX5q X-Received: by 2002:a17:906:4e83:: with SMTP id v3mr5253366eju.154.1606861874131; Tue, 01 Dec 2020 14:31:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606861874; cv=none; d=google.com; s=arc-20160816; b=HMnGlmp/vkOBNexWDdud7yjW1oCr8zO0AZdWzgWvl/a7ZFlb8HZb9ccpAIyv8EMLOc +dDUlNBEBaBKz39WCdYw4t/hh0m2rwtgujmEQgWJZIiI9IyQ1cqqM3L3Cv8JiZfdqouW DbPNgEZXpjnCBda6GzBlbOu2fUN1gLi0N1OVNxIs87+j65GKlwGj1i2hbGfAPQHcIgMp gd6woJYAIhOIOMpYK8R18CtddzfeUJIpWFOibohP8gzSinDwzGaVdMQgLgOnIFPbQant RMeVbchEXImqpyRDpfyQ08nw03hHiM13yjmXzHeM0LfBOUUA5jExKX/Jm27EmsxyAfam lK2Q== 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=1lRbJbpAbIlNi8Do77NhPfJNQSJriHsqNrGwlLyqMd4=; b=Kz6GTK2WJKGLDowhJXQ24/5G55w8GrXaxt/QDvyirJ7w1EALk+27KdWd+nH7Zeqy/D kAV9NJEHaI/HsZbGp8omH5ObT2uNdwbirUUovSpAk/0ZV/il/hn0DvZNQy4uWarT/oqA f71fGeqvs1mFWPSyU/nuVplVqo3jM3v1iXGV3UugFEGL1kU4y8kwMoe+9tzFZVQqFDJb UyueSyfK+vBSswt7rdVGwBXWfjCDqbQbrqH5qKLhVi2+AWeQOuUpBizg94U9ixebHoG5 jb+ozsqQdvT3XuIgaaHBumMrRGIt/zt26GozJjn/bswu+em5hSN30HTQ5PlpAvPX8awD hCCg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="0stIo/QQ"; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cn1si769115edb.408.2020.12.01.14.30.51; Tue, 01 Dec 2020 14:31:14 -0800 (PST) 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=@linuxfoundation.org header.s=korg header.b="0stIo/QQ"; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729562AbgLAJYC (ORCPT + 99 others); Tue, 1 Dec 2020 04:24:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:43214 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388758AbgLAJGV (ORCPT ); Tue, 1 Dec 2020 04:06:21 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 82F0722245; Tue, 1 Dec 2020 09:05:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606813541; bh=cLlfYmBM43nEai9iLzYZtVzly2bVU8zKa6peQumlORw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0stIo/QQKTwfkR78WYH7s7MKjR6uTUSNbUR2QoTVmu0wvHpavOMVOFY/BFlorEt/Z ORXgHkUs9n59BUaeDBsGxWch/cDlxZeGjmsjmaddnTJn18+fSyKmqqLrABH3PR3YmT BUyUPbI5XdP7Liurpxu3OMCnswLiuWGyegdrDupg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yixian Liu , Weihang Li , Jason Gunthorpe , Sasha Levin Subject: [PATCH 5.4 75/98] RDMA/hns: Bugfix for memory window mtpt configuration Date: Tue, 1 Dec 2020 09:53:52 +0100 Message-Id: <20201201084658.742503695@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201201084652.827177826@linuxfoundation.org> References: <20201201084652.827177826@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yixian Liu [ Upstream commit 17475e104dcb74217c282781817f8f52b46130d3 ] When a memory window is bound to a memory region, the local write access should be set for its mtpt table. Fixes: c7c28191408b ("RDMA/hns: Add MW support for hip08") Link: https://lore.kernel.org/r/1606386372-21094-1-git-send-email-liweihang@huawei.com Signed-off-by: Yixian Liu Signed-off-by: Weihang Li Signed-off-by: Jason Gunthorpe Signed-off-by: Sasha Levin --- drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index b285920bcd8ab..e8933daab4995 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -2423,6 +2423,7 @@ static int hns_roce_v2_mw_write_mtpt(void *mb_buf, struct hns_roce_mw *mw) roce_set_bit(mpt_entry->byte_8_mw_cnt_en, V2_MPT_BYTE_8_R_INV_EN_S, 1); roce_set_bit(mpt_entry->byte_8_mw_cnt_en, V2_MPT_BYTE_8_L_INV_EN_S, 1); + roce_set_bit(mpt_entry->byte_8_mw_cnt_en, V2_MPT_BYTE_8_LW_EN_S, 1); roce_set_bit(mpt_entry->byte_12_mw_pa, V2_MPT_BYTE_12_PA_S, 0); roce_set_bit(mpt_entry->byte_12_mw_pa, V2_MPT_BYTE_12_MR_MW_S, 1); -- 2.27.0