Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp630541pxb; Tue, 5 Apr 2022 16:34:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxzmopFDFto1zDIZZzTo7DOmitHcZZCawO9TwBX697BSZ3E1izGQJ6GHXEfbRfmM7yAi4SK X-Received: by 2002:a17:902:e84d:b0:155:d31c:5c93 with SMTP id t13-20020a170902e84d00b00155d31c5c93mr5852779plg.103.1649201684173; Tue, 05 Apr 2022 16:34:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649201684; cv=none; d=google.com; s=arc-20160816; b=MtP8pF09JnWW/3qQlXVZzGFpRyvefic6tvpOZrovZbtgULFWRLYJglcB5Z9ENvN9HT xaVz+AMrOJCT7GMiOhauICC8fCJQo3BIXvHKhkL/09CgkcwVTEX87GcKOGxdBrPyqAGD +KB3hxJWWLxregPTAX3YRPig9iNQPV3orPFq05ftATifyCyN60PhpICgATkoYyPaNnNi i/hlvcQC5yuf+dk93i4BEYUtfjyN72dEp3QUNTpoNUazhEUE70ea4pnF1DJFGVbTYV1+ ZJBsRAQmeMwj4v3HWVCkG8x/pKVY0QEYUYvurhd96RDzXoaynffVnbU+DVwvEBpmMB+u +lIw== 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=6OZEmBKDyTMjqTqc9zZBqX9aisjkDt+RM7gQr3MvXXM=; b=DrCh9xilMXv9SuhAPUXjW335htoEKMGIZfytcFzPyIEgwz8BBPU8ucfeaq5wp3+lLE LpzItCQH+7uhtlVwjTga9JxTNBTcCYYBkvZ/BhzAfU9sJtUMTWJhMzC87XZ30ljbOXa5 WVwwmJT2Jr2zME9MfF2fb0WNziXMrvop9PWKAKZWwxyHn6k60gkYz5RWDMquc+qAzfVa NmrZVeuKEHNFDYfOnLr8TXrsAeosOkHsxp1blWUnRW1VN2S0bHpbJUDrPSxhEhR33DrY fUQFhQve6n4fm/eWB3TUyexHxECUyp1/e302O3xzKThYvYwEvxzJ6aCJEr4QyfDT7wir mdPg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=V7q50ER0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1: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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id o16-20020a170902779000b00153b2d16542si13170742pll.330.2022.04.05.16.34.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Apr 2022 16:34:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=V7q50ER0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1: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: from out1.vger.email (out1.vger.email [IPv6:2620:137:e000::1:20]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E4DA6198EC2; Tue, 5 Apr 2022 16:19:59 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244786AbiDEN1E (ORCPT + 99 others); Tue, 5 Apr 2022 09:27:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59912 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345222AbiDEJWW (ORCPT ); Tue, 5 Apr 2022 05:22:22 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6982C33A33; Tue, 5 Apr 2022 02:09:42 -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 ED386B80DA1; Tue, 5 Apr 2022 09:09:40 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 64CB9C385A2; Tue, 5 Apr 2022 09:09:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1649149779; bh=8OMFyOaAk1BzOs8bd9OEu8SQHWkFyA3dMkqxRl+sTPI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=V7q50ER06Jj2HvX+J8kh1lzlOUfTdWQa6sNSMuvAfrgk0RwXoRq0AcM/kPPObm/rI 9Gco0wvwsKjafCaU95Bkvz3OtewVL7deBWYEugESQF7U8PuaFTLj0mryA5hn/dhGvT Wo9CrmOUEtuDzIU8D1dAw1dJ3whqG5m0JD3t/pdo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Chao Yu , Jaegeuk Kim , Sasha Levin Subject: [PATCH 5.16 0800/1017] f2fs: compress: fix to print raw data size in error path of lz4 decompression Date: Tue, 5 Apr 2022 09:28:33 +0200 Message-Id: <20220405070417.997536220@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220405070354.155796697@linuxfoundation.org> References: <20220405070354.155796697@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=-2.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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: Chao Yu [ Upstream commit d284af43f703760e261b1601378a0c13a19d5f1f ] In lz4_decompress_pages(), if size of decompressed data is not equal to expected one, we should print the size rather than size of target buffer for decompressed data, fix it. Signed-off-by: Chao Yu Signed-off-by: Jaegeuk Kim Signed-off-by: Sasha Levin --- fs/f2fs/compress.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c index 190a3c4d4c91..ced0fd54658c 100644 --- a/fs/f2fs/compress.c +++ b/fs/f2fs/compress.c @@ -313,10 +313,9 @@ static int lz4_decompress_pages(struct decompress_io_ctx *dic) } if (ret != PAGE_SIZE << dic->log_cluster_size) { - printk_ratelimited("%sF2FS-fs (%s): lz4 invalid rlen:%zu, " + printk_ratelimited("%sF2FS-fs (%s): lz4 invalid ret:%d, " "expected:%lu\n", KERN_ERR, - F2FS_I_SB(dic->inode)->sb->s_id, - dic->rlen, + F2FS_I_SB(dic->inode)->sb->s_id, ret, PAGE_SIZE << dic->log_cluster_size); return -EIO; } -- 2.34.1