From patchwork Thu Jun 22 16:51:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 13289447 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 79995EB64DA for ; Thu, 22 Jun 2023 16:51:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231318AbjFVQvP (ORCPT ); Thu, 22 Jun 2023 12:51:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40804 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230256AbjFVQvO (ORCPT ); Thu, 22 Jun 2023 12:51:14 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C7458197; Thu, 22 Jun 2023 09:51:13 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 7CC8F21D42; Thu, 22 Jun 2023 16:51:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1687452672; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=q5bTcwRpOQqDZeBG6wcf8dPs5qbb9VV08OwcH6T8toQ=; b=eHCkflT5BXAUCE9W/2YKkR3mi6WgjkQG8VvT8jOnJ3Ny/UHmNnrCvu5UBhtAPEHwc9omsk aCV7+/oRHsxjBFI7h8Co9uSpdyGuF4QydfnoHbl2C6Ll4sQKM+12j6yx0Nhx4IaegfNnHi m0ZmDCS0AgJlWKozGBXUJdtbAjKZg5Y= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1687452672; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=q5bTcwRpOQqDZeBG6wcf8dPs5qbb9VV08OwcH6T8toQ=; b=6E1se03t/3uAWtYUc88jX7W6o4F1a5x0ATDFOovANabjRIlF1nNgaP2PwggsiQLCVaOmoV Qp1gKpOgSwCTMNAw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 6E76713905; Thu, 22 Jun 2023 16:51:12 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id q3r1GgB8lGRqTQAAMHmgww (envelope-from ); Thu, 22 Jun 2023 16:51:12 +0000 Received: by quack3.suse.cz (Postfix, from userid 1000) id DE42EA0754; Thu, 22 Jun 2023 18:51:11 +0200 (CEST) From: Jan Kara To: Jens Axboe Cc: Christoph Hellwig , , , Jan Kara Subject: [PATCH] ext4: Fix warning in blkdev_put() Date: Thu, 22 Jun 2023 18:51:07 +0200 Message-Id: <20230622165107.13687-1-jack@suse.cz> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=813; i=jack@suse.cz; h=from:subject; bh=i5SQsfEQ6FLHG5qn+W2tiOHApX2mmYuZkyz4E8WBuPc=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBklHv0zj1YyI1UOaRwK54xrTwJ69oc3f05YwPhpmbr wtPU1JuJATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCZJR79AAKCRCcnaoHP2RA2W+yCA DeXI3YFNgz3v8pkNMAGteyHMiH7a9n+EQwggIWk6UPyOzOl2vPiG1HC63YJpbV1sAPLhXN22jOm+sg 8wtSsZkD6qhwaYsNu1XtA6+Q4L7b+QpCVGJX+xVsDHrYIfu25YfQc08MwiQHKmvXobgH5Bnqev147n XtDmzgxfQd6HBvX0jxsj3S5lcCVVQE0FLzWGH9Q7UmCpJu+A4HEPKaKnG0K9TYn5AnhqUjwHFOQ7xm ih9uFnbLOK5kIh5laurnxt6J2jd39I6cRzI5T6NuCVjhr4wLeTwSZmetdmygjDAd/2jQVEdzNXTwGf A3Xp3UbVrQIiPlMZcVHORFagZRfRW5 X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org ext4_blkdev_remove() passes a wrong holder pointer to blkdev_put() which triggers a warning there. Fix it. Fixes: 2736e8eeb0cc ("block: use the holder as indication for exclusive opens") Signed-off-by: Jan Kara Reviewed-by: Christoph Hellwig --- fs/ext4/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Jens, this is another fixup of the block device handling series sitting in your tree. diff --git a/fs/ext4/super.c b/fs/ext4/super.c index 53d74144ee34..d34b4eb90fe8 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -1133,7 +1133,7 @@ static void ext4_blkdev_remove(struct ext4_sb_info *sbi) struct block_device *bdev; bdev = sbi->s_journal_bdev; if (bdev) { - blkdev_put(bdev, sbi->s_es); + blkdev_put(bdev, sbi->s_sb); sbi->s_journal_bdev = NULL; } }