From patchwork Wed Jun 7 18:53:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rishabh Bhatnagar X-Patchwork-Id: 10446 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp431206vqr; Wed, 7 Jun 2023 12:28:03 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4DD1yrNMpnItQEkQA+y/G8S+NQLOLGMwVS9Ec/gGqCI9A75BO7hMI5wDLbCmfkv0GKOtsd X-Received: by 2002:a17:902:ec90:b0:1b1:94a8:ab2d with SMTP id x16-20020a170902ec9000b001b194a8ab2dmr7270622plg.29.1686166082866; Wed, 07 Jun 2023 12:28:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686166082; cv=none; d=google.com; s=arc-20160816; b=mOaUy1J+JtxgZaEZDNnY02kHxlCdtII1xyZLCbim2xCPFLipqy2HH+6PXKOFgQcrs6 Q8lcc2Aw216chq9IbU+QldQk3cpLXnLfsmtJiFl9PzoCWxvacyu2t/Lt97P5M6rWymaz Z1TOs9zdgLud6Iesg9csMmt69Dm1GXHhwJJtLBu5ekSbTm7vmM4r0ibdareEJfJRgY/I gCCCdRkACyqzMGK8waurSnddzcx/92XHvxdKynlyDTWuLnxyCG+2U38jyZxsSFjDEE22 woJ6CcWFTvzQ7fK2QLQo5EGVBg/WFBY0Zum0KX5bt2bpVLrjlI3koUGb4MwBRLNaSRDw 4GNg== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=QQccf1KeyTZf6ZPMjV/HwnVR62uBW11Zlzl2mRiQIRQ=; b=Zrik11aJZXevJLfxctXnQbHy1KfWBc5ml/uaU/1AWAZk3ZfJGkJ9xb7TWhZlWbmh/t uecvDzy9fcTZf1Qu95ZNgsPbhbC0O0tHyUBNG4RfiVBCGCCVmhb6xyxvvhBjTtr0V+dp mzRZhjhBMA3O0iLiEHVHEdAlBT0w/b1HuzHRkEquNM6n7vuXoxNT3BbbTthUi96WUny8 2gppODk/SZIK0eYsGJzMdKG1i1D45n4hHpfq1YoqTvEerz1+3324x7SszVNV1fZyGXBr 21EpTFpCKIqq1LDwr5X/LBcMZUICp+lKc/dOS0XaV0iX26lazCPFz+Q0ojZahs+iQMSf QRtA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b="jpy35Re/"; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n1-20020a170902dc8100b001add3e4ee84si9230804pld.132.2023.06.07.12.27.50; Wed, 07 Jun 2023 12:28:02 -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=@amazon.com header.s=amazon201209 header.b="jpy35Re/"; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233061AbjFGSyG (ORCPT + 99 others); Wed, 7 Jun 2023 14:54:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60504 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233041AbjFGSyB (ORCPT ); Wed, 7 Jun 2023 14:54:01 -0400 Received: from smtp-fw-9103.amazon.com (smtp-fw-9103.amazon.com [207.171.188.200]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D04F31BD6; Wed, 7 Jun 2023 11:54:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1686164040; x=1717700040; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=QQccf1KeyTZf6ZPMjV/HwnVR62uBW11Zlzl2mRiQIRQ=; b=jpy35Re/yLIbl7HDAU7wscKlGkE1bdjlUv8Y3WpC8q0RI5mBI+wXcKtb 3dbDLBuSCWNu4r7uAsxdP7ygCZOu4BfL3LNyq5N6koDpiiF4W1kJk5qxc M7wTJnQgazMmIlIMkJTB/pgR6AWTsAJOmE37Ou3jJf9hbZKcbKaDUxrwA Y=; X-IronPort-AV: E=Sophos;i="6.00,224,1681171200"; d="scan'208";a="1136280854" Received: from pdx4-co-svc-p1-lb2-vlan3.amazon.com (HELO email-inbound-relay-pdx-2c-m6i4x-e7094f15.us-west-2.amazon.com) ([10.25.36.214]) by smtp-border-fw-9103.sea19.amazon.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Jun 2023 18:54:00 +0000 Received: from EX19MTAUWC002.ant.amazon.com (pdx1-ws-svc-p6-lb9-vlan2.pdx.amazon.com [10.236.137.194]) by email-inbound-relay-pdx-2c-m6i4x-e7094f15.us-west-2.amazon.com (Postfix) with ESMTPS id 31AA0413FA; Wed, 7 Jun 2023 18:54:00 +0000 (UTC) Received: from EX19D002UWC001.ant.amazon.com (10.13.138.148) by EX19MTAUWC002.ant.amazon.com (10.250.64.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 7 Jun 2023 18:53:50 +0000 Received: from EX19MTAUEB001.ant.amazon.com (10.252.135.35) by EX19D002UWC001.ant.amazon.com (10.13.138.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 7 Jun 2023 18:53:50 +0000 Received: from dev-dsk-risbhat-2b-8bdc64cd.us-west-2.amazon.com (10.189.73.169) by mail-relay.amazon.com (10.252.135.35) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Wed, 7 Jun 2023 18:53:50 +0000 Received: by dev-dsk-risbhat-2b-8bdc64cd.us-west-2.amazon.com (Postfix, from userid 22673075) id BF818222F; Wed, 7 Jun 2023 18:53:49 +0000 (UTC) From: Rishabh Bhatnagar To: CC: , , , , "Rishabh Bhatnagar" Subject: [PATCH 5.4 0/2] Backport few dfs related fixes to cifs Date: Wed, 7 Jun 2023 18:53:11 +0000 Message-ID: <20230607185313.11363-1-risbhat@amazon.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768073149365260930?= X-GMAIL-MSGID: =?utf-8?q?1768073286473901381?= Recently we have been seeing kernel panic in cifs_reconnect function while accessing tgt_list. Looks like tgt_list is not initialized correctly. There are fixes already present in 5.10 and later trees. Backporting them to 5.4 CIFS VFS: \\172.30.1.14 cifs_reconnect: no target servers for DFS failover BUG: unable to handle page fault for address: fffffffffffffff8 #PF: supervisor read access in kernel mode #PF: error_code(0x0000) - not-present page PGD 260e067 P4D 260e067 PUD 2610067 PMD 0 Oops: 0000 [#1] SMP PTI RIP: 0010:cifs_reconnect+0x51d/0xef0 [cifs] RSP: 0018:ffffc90000693da0 EFLAGS: 00010282 RAX: fffffffffffffff8 RBX: ffff8887fa63b800 RCX: fffffffffffffff8 Call Trace: cifs_handle_standard+0x18d/0x1b0 [cifs] cifs_demultiplex_thread+0xa5c/0xc90 [cifs] kthread+0x113/0x130 *** BLURB HERE *** Paulo Alcantara (2): cifs: get rid of unused parameter in reconn_setup_dfs_targets() cifs: handle empty list of targets in cifs_reconnect() fs/cifs/connect.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)