Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp2260214pxm; Fri, 4 Mar 2022 12:32:36 -0800 (PST) X-Google-Smtp-Source: ABdhPJz20fDWXMtJ6xeKTVe+W7CfG37dZWP2y3P2Tv1eKzGNMatMfOPexytlrANCxH6bt3HCitdo X-Received: by 2002:a17:902:be10:b0:14d:66b5:7065 with SMTP id r16-20020a170902be1000b0014d66b57065mr104550pls.81.1646425956419; Fri, 04 Mar 2022 12:32:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646425956; cv=none; d=google.com; s=arc-20160816; b=bjSYLlhiD+y3p9yja8TBqsNWw99enyBqO7gbVbnAY8gCzEF0DjCyblb2a06pnhkdK7 8V6J99DZfIGwQuI2SxoXpz4RSwN1mecmQ6HH7Di00rRcAad/XA3C1r4u0bF0r/4PHmLH ISsDALXrMTqPkZYri4KrApbvtQvak7V5Ygo0ioXLx8c51LD+e5gqgEfowHP/a14NECO8 HJ+YI0ZOBcCnN1a7X2rXAfHFGamRULpeaSwrYaixfgv+zXP1bjeM+RjXL3WCXxD8PQKz NU7V6zrwzQBllm5ArPz/JEmeJc7WMGmx0cZq0IK1KWz2IblkdpDJfn6OeieSZpaQgxO8 Mdww== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=/DgQnFlNZ9XU3MUiWD3W/xSOCpM12Wnovh2/HHtJAns=; b=byghjWLNZ7WhsH12ijnnnFrVV1DfMnvCcjnFcXKfaoCjxv+TXexSz9d78dhNaa0XaK LIDD5YoTzsC3E8N18ECIlL53LwULyNhDprVpW9Y6+jhoMnyk/ZOW8MYt/WZVxZyNdUH5 jhQ2sudsuBnQoVlP8xWODnB5Zv6OP154pAneRJsbwESBmdFfc44kdWCvdSrA6OumIPpW ymsxJUEU7iY5bhBaE1hZIs7ZOEksmvfxza4owz7RbYDLw6HGsaUW1QOG372OnD8BrwHy adyQJ61nE065I/B0lCsF6Z3fRtDJViw+sp5QhW6XnpmB/VYR3IyX+ytGIlhMyRfpyVYN V0yA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b="gFJUv/iq"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id v4-20020a1709029a0400b0014af00acf68si5206317plp.177.2022.03.04.12.32.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Mar 2022 12:32:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-ext4-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=@infradead.org header.s=bombadil.20210309 header.b="gFJUv/iq"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B5AD22590C4; Fri, 4 Mar 2022 11:36:52 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241488AbiCDSCZ (ORCPT + 99 others); Fri, 4 Mar 2022 13:02:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59504 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241458AbiCDSCO (ORCPT ); Fri, 4 Mar 2022 13:02:14 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 498801C4B2A; Fri, 4 Mar 2022 10:01:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=/DgQnFlNZ9XU3MUiWD3W/xSOCpM12Wnovh2/HHtJAns=; b=gFJUv/iqGPUrFqOo4zKYr7SM6n 0HB+IUMBpdrhBvNbI24UPggkNktOF69JinOcS8v+LK33M36D7afdoQCU7H2YyfU7GDwl3fq3nKa7b 4Yu+dZUy8FBkP6Ac4RE50C4a2dsHnn9Y3bGhugN40FAe4qojkeu8A5t6AbF4Hb24QsTOkTeCNE1k9 C8SD2sMpW2RQya1hRm+22AC/MHC0yhcrUCajz0XcF/l4IKT08uHCZN6agm1+x+U3t72kpaFE0gsS0 DnwVH4lsUfw5kgiBgXPYc4ZT7Y2Lb1BJEsYKLa1TCbzQoMV9dIeCutamH6V9SvAruUbpL0cElRPJS 5Pmiz80A==; Received: from [2001:4bb8:180:5296:cded:8d4b:ace6:f3c] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nQCEz-00BUpr-2n; Fri, 04 Mar 2022 18:01:21 +0000 From: Christoph Hellwig To: Jens Axboe Cc: Song Liu , "Theodore Ts'o" , linux-block@vger.kernel.org, dm-devel@redhat.com, linux-raid@vger.kernel.org, linux-ext4@vger.kernel.org Subject: [PATCH 05/10] dm-integrity: stop using bio_devname Date: Fri, 4 Mar 2022 19:01:00 +0100 Message-Id: <20220304180105.409765-6-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220304180105.409765-1-hch@lst.de> References: <20220304180105.409765-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,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-ext4@vger.kernel.org Use the %pg format specifier to save on stack consuption and code size. Signed-off-by: Christoph Hellwig --- drivers/md/dm-integrity.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/md/dm-integrity.c b/drivers/md/dm-integrity.c index eb4b5e52bd6ff..c58a5111cb575 100644 --- a/drivers/md/dm-integrity.c +++ b/drivers/md/dm-integrity.c @@ -1788,12 +1788,11 @@ static void integrity_metadata(struct work_struct *w) checksums_ptr - checksums, dio->op == REQ_OP_READ ? TAG_CMP : TAG_WRITE); if (unlikely(r)) { if (r > 0) { - char b[BDEVNAME_SIZE]; sector_t s; s = sector - ((r + ic->tag_size - 1) / ic->tag_size); - DMERR_LIMIT("%s: Checksum failed at sector 0x%llx", - bio_devname(bio, b), s); + DMERR_LIMIT("%pg: Checksum failed at sector 0x%llx", + bio->bi_bdev, s); r = -EILSEQ; atomic64_inc(&ic->number_of_mismatches); dm_audit_log_bio(DM_MSG_PREFIX, "integrity-checksum", -- 2.30.2