Message ID | 20230622235547.56485-3-yuxuan.luo@canonical.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=<UNKNOWN>) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=rT+cDGva; dkim-atps=neutral Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QnHMC0wvmz20Xp for <incoming@patchwork.ozlabs.org>; Fri, 23 Jun 2023 09:56:07 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1qCU9g-0000zt-F5; Thu, 22 Jun 2023 23:56:00 +0000 Received: from smtp-relay-internal-1.internal ([10.131.114.114] helo=smtp-relay-internal-1.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from <yuxuan.luo@canonical.com>) id 1qCU9c-0000wG-Sc for kernel-team@lists.ubuntu.com; Thu, 22 Jun 2023 23:55:56 +0000 Received: from mail-qk1-f198.google.com (mail-qk1-f198.google.com [209.85.222.198]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id 6AF013F214 for <kernel-team@lists.ubuntu.com>; Thu, 22 Jun 2023 23:55:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1687478155; bh=ZTMlVKsr95FR/8G1pzZ/vgjoBw/tWxJM1zpKnMobIeE=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=rT+cDGvaYfrq0Uig0enHkwrT4svpqfiuFe/8P9bhwl/YQDbYlwCmDAq0xBXVAheWL GhqYZi/zJhbjr7n5MmG6erb0Vh+Y0tz82GQau/ogFjUMkeN58sOx6sJpDCNO5U2sDv K/aKnYTwOxHUiE2Nmbrd/lExw5Lz5RnVgwMZ/b38fLbT8303FzxI3aMwTp945C7/C3 qPZ4GhV6Vn46By3CldwGtCN2L2b4ShGltxu1MkyrFWrzVfkUPa3Uv8WiM+RgX/xHQv XdOkEHMBQDRJFeWdO7wKbdDByARYErS7OPjYbHfiBrGCb0OiiRMOTwbM5N/1JSqjFK RkU0HIE6V8q8g== Received: by mail-qk1-f198.google.com with SMTP id af79cd13be357-763ddc425b7so271498785a.1 for <kernel-team@lists.ubuntu.com>; Thu, 22 Jun 2023 16:55:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687478152; x=1690070152; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZTMlVKsr95FR/8G1pzZ/vgjoBw/tWxJM1zpKnMobIeE=; b=hX8lNYvRnQ824Zq2l/Z3yg3yT8kI/DgDbpMqOW5RhakE6OjabTm5/AUX9DVaQIgmRA o0VFvXdh+OWygjlwAZb4OOJW2Bw81O2SyJJz+Hopm8BtydElsK6w9otJCe42uSm2Qn/w hqzHlm+svMFlKN5xtDWOIslQm1yS1VaLP0Cva9XEMREit8QHHkyAtiuhG5wKBqd0Hx+Z GRDElhqGw3sjmwD8rV3nhM8Zhb2+Wh12UJ7PA9kZteklAwxDU9fB3qn251ewRC1uAq3p wd6de0eqNWeuAFx4LCCjMZfY/0Wo8vBcNPkTZ7QzgrLDdBuOJ2oseqxMwY5yXg7Zx6pw 1UDQ== X-Gm-Message-State: AC+VfDzo6NP4ZnEzUiW6GYrQw1ptONqw+ob2M5Hji/GyjANyO2TUxXRv ejpA8Fkw72bjXc1D3fG+SR34I+Jfdr1DpQWXmm3ZczKpEY79CEytdbDc1eEC2xgthnTbehJZjfq NAOj9rJCk428mp51CWp7oPZLKTNuvhoUDbZpxUcl7KojFm8XRRQ== X-Received: by 2002:a05:620a:4248:b0:761:fbb5:7421 with SMTP id w8-20020a05620a424800b00761fbb57421mr21306260qko.77.1687478152457; Thu, 22 Jun 2023 16:55:52 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4WPj5P5ZhHB6pPqPvB5Xk+h4EYn1xxcjmNPTXhfr9z+VyQQN7CC8TUU8lp8t6sAqDGX1opOg== X-Received: by 2002:a05:620a:4248:b0:761:fbb5:7421 with SMTP id w8-20020a05620a424800b00761fbb57421mr21306252qko.77.1687478152114; Thu, 22 Jun 2023 16:55:52 -0700 (PDT) Received: from cache-ubuntu.hsd1.nj.comcast.net ([2601:86:200:98b0:9ce5:9367:9ec1:3892]) by smtp.gmail.com with ESMTPSA id x14-20020ae9f80e000000b007578b6d060bsm3903858qkh.126.2023.06.22.16.55.51 for <kernel-team@lists.ubuntu.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Jun 2023 16:55:51 -0700 (PDT) From: Yuxuan Luo <yuxuan.luo@canonical.com> To: kernel-team@lists.ubuntu.com Subject: [SRU][Focal][PATCH 2/2] btrfs: unset reloc control if transaction commit fails in prepare_to_relocate() Date: Thu, 22 Jun 2023 19:55:47 -0400 Message-Id: <20230622235547.56485-3-yuxuan.luo@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230622235547.56485-1-yuxuan.luo@canonical.com> References: <20230622235547.56485-1-yuxuan.luo@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" <kernel-team-bounces@lists.ubuntu.com> |
Series |
CVE-2023-3111
|
expand
|
diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c index c196863420571..e603cc8c141e9 100644 --- a/fs/btrfs/relocation.c +++ b/fs/btrfs/relocation.c @@ -4102,7 +4102,12 @@ int prepare_to_relocate(struct reloc_control *rc) */ return PTR_ERR(trans); } - return btrfs_commit_transaction(trans); + + ret = btrfs_commit_transaction(trans); + if (ret) + unset_reloc_control(rc); + + return ret; } static noinline_for_stack int relocate_block_group(struct reloc_control *rc)