From patchwork Thu Apr 20 10:05:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13218311 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6FC03C77B72 for ; Thu, 20 Apr 2023 10:06:22 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 4937B90000E; Thu, 20 Apr 2023 06:06:20 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 442CF900002; Thu, 20 Apr 2023 06:06:20 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 26D5E90000E; Thu, 20 Apr 2023 06:06:20 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 17E13900002 for ; Thu, 20 Apr 2023 06:06:20 -0400 (EDT) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay03.hostedemail.com (Postfix) with ESMTP id E064AA013C for ; Thu, 20 Apr 2023 10:06:19 +0000 (UTC) X-FDA: 80701339278.05.1587668 Received: from mail-wm1-f46.google.com (mail-wm1-f46.google.com [209.85.128.46]) by imf12.hostedemail.com (Postfix) with ESMTP id 0FA614000E for ; Thu, 20 Apr 2023 10:06:17 +0000 (UTC) Authentication-Results: imf12.hostedemail.com; dkim=none; spf=pass (imf12.hostedemail.com: domain of morbidrsa@gmail.com designates 209.85.128.46 as permitted sender) smtp.mailfrom=morbidrsa@gmail.com; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=kernel.org (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1681985178; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bdnAdvAKJlDAz7pM0pp8Diurpm3+TR0sCY4FonfaEe4=; b=DSqVGkMzJS7kRp8ObjuD/kWZGEZ56Sn4pQpj57L/yPGlE68VHElnamyPhsS3b+M2feFIHf m71mfBJA7RAP+cyDubvnK+ZSYbqrs2LGCo/lGMJ4QryV+g4FOQ0qV7YMtTSYcMwTB5KVGP PVEcwDslYL/vG8cPxWudRUBFWvmPxpg= ARC-Authentication-Results: i=1; imf12.hostedemail.com; dkim=none; spf=pass (imf12.hostedemail.com: domain of morbidrsa@gmail.com designates 209.85.128.46 as permitted sender) smtp.mailfrom=morbidrsa@gmail.com; dmarc=fail reason="SPF not aligned (relaxed), No valid DKIM" header.from=kernel.org (policy=none) ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1681985178; a=rsa-sha256; cv=none; b=AdRaa7TlXSS1L/80a4dfNRudimuiH9m09Za9WFlckerR658OuTcrTCq08f2EDH9pYmAOs8 pPea77zEUTe1de+3O+1qqkI7EXAu8FCMZAePbZCaWq5XF3i539EajOBzp3SJbeLBhPHrCM X4MjFsDhr852LGDk6XUElCRZ3ILCBxA= Received: by mail-wm1-f46.google.com with SMTP id 5b1f17b1804b1-3f17e5fe8bbso5485275e9.1 for ; Thu, 20 Apr 2023 03:06:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681985176; x=1684577176; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=bdnAdvAKJlDAz7pM0pp8Diurpm3+TR0sCY4FonfaEe4=; b=g/t8K1j4M0r7dC1uZT4Cb64YIipT0b0i5MuLunpbtT0bAowmtrL70NfwVI2YLQpULl iyj+V83ZSK1lzvgFP8Rcni0SwjrmsgQG4W3j51frnVK05OuRF12LafQRTnprBTWMDcG3 sguPqlXA+UyBRh4tSmmpOSlp780uGK4VmUQLx+nAasvMw7KaZRCl2bFM429Gt/PE7Tue gjXTQ8qpk+C/+bk5hgCmjgV/QoiUl94KdwN/2GNv9Eggq07kyDEqtMXTg7jj4a+90pMH 9t11w0Rlzr0qPm5Gvrs7lPDb2BGgvXkf5Jd6gIM62KQRrh4FpDnHgqkkMPDchA4iMdiw E58Q== X-Gm-Message-State: AAQBX9dVuJmUyVe6BC0Xp7JpAeaw4eUTilczjKxKhWIilOdnrz9EeEPm 8+a7+sbJ0bMOHJE6AK6Ph+c= X-Google-Smtp-Source: AKy350bs2gtzNI5cB6yEjD27bAOubU763Pln69XpJllBqakY/TYBXJ5mOXnM5tQ2B75UHodvDIFK3A== X-Received: by 2002:a5d:6dcc:0:b0:2fa:43e7:4a32 with SMTP id d12-20020a5d6dcc000000b002fa43e74a32mr694948wrz.66.1681985176558; Thu, 20 Apr 2023 03:06:16 -0700 (PDT) Received: from localhost.localdomain (aftr-62-216-205-208.dynamic.mnet-online.de. [62.216.205.208]) by smtp.googlemail.com with ESMTPSA id l11-20020a5d674b000000b0030276f42f08sm201410wrw.88.2023.04.20.03.06.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Apr 2023 03:06:16 -0700 (PDT) From: Johannes Thumshirn To: axboe@kernel.dk Cc: johannes.thumshirn@wdc.com, agruenba@redhat.com, cluster-devel@redhat.com, damien.lemoal@wdc.com, dm-devel@redhat.com, dsterba@suse.com, hare@suse.de, hch@lst.de, jfs-discussion@lists.sourceforge.net, kch@nvidia.com, linux-block@vger.kernel.org, linux-btrfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-raid@vger.kernel.org, ming.lei@redhat.com, rpeterso@redhat.com, shaggy@kernel.org, snitzer@kernel.org, song@kernel.org, willy@infradead.org Subject: [PATCH v4 22/22] block: mark bio_add_folio as __must_check Date: Thu, 20 Apr 2023 12:05:01 +0200 Message-Id: <20230420100501.32981-23-jth@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230420100501.32981-1-jth@kernel.org> References: <20230420100501.32981-1-jth@kernel.org> MIME-Version: 1.0 X-Rspam-User: X-Rspamd-Server: rspam03 X-Stat-Signature: 6zqxbecpge7ifp75xa3ui69r8uyq8j1q X-Rspamd-Queue-Id: 0FA614000E X-HE-Tag: 1681985177-582014 X-HE-Meta: U2FsdGVkX1/9iY8pIKjD9+Pc3RZVblJ9Ip/KRhDkU6O/tZPwWOUnzEkE4gA8nDh1Xf4nfiTa1Gk67Myq27RehspH3xrgAXkZSCgry7gf0/n7ouYEY5Rl/1QwtL4s+pRDc2bPu5I8xDfOBYahoknyHCx9M/i+4AfELTweD8U6ekWvzP54nQFogIUaMuZX/SrU9GLxOfI/yRIEgg/czTOIf7khl3g/LLSFXd4s0g3QHoNNnRE2Rfx1lHDFg45ENku3Fa67oxsgjXRVq5z8qpcYEqYmu/Rw45P2JbelVCNE43WrXvjPbgU+D5vwTf/XOk44WwOkBJM2MA9xj4ROpZfr/csKOx5NY+it3oDKxH/lBzUMUXOBR4E/tfeno2sMwclBfjBdkNZ0JO7oKAcxyTF5qsFITUmqFF3hTOAUSKv9BbnR0+2KFo00478HRk5q/3EiilPeHL8gyYzraPYny+F6aoxt+pRgXdWMbChl6DbbJ/+tA0B7vhE3Dp22LII1/3Dx1IffPmYLxM8KNvYqwkD96NRWX46JEeFzwFQBhWrko61j1mTpbWWkuJWhWRkuQQZ//KjcymxfpHh7TxnE84NxYF7mxMiLcC4ppYSwTFdz7GyDJvkIZaAVXYJVQMFQrEkMwRKhL0D/CsPdaZY/RkRZuPb8O9t4C4rxJ80lBfhVdK3MxwKWxhNJaYinmjW7SBcamXu7WFfM9SvHbfP/nG785jhnajt9EjI4DqQV6fdTaxW+iDE2uChlRx3saL4lMCHM8NT2vaibl4+8fvge9itOiBBds6Dew9jOCcqbkhmbftgwuy2vfrDUZn/XiIePX4NWmnmshc8xJGzLt0MHvjr4dqbtPNDWQ+EPRszZQ5k2y6EhG7GfMD2ifKmEcqDbUiPCh+NIVZDxmMJS2VVodYZzN638EeRSR/FJCBGTb7AltlwkTIg4++E6iHQghaURfTpo0ItGxXZZf9zcab0D5vC b9Oy5zQL x9mVdrrHCJj3QePXVGiPyPF+Sds5k7M9UQzAkHDjzWWTi3y4GrFu8BziAslcX009/X5B7fIYrgjqo9SDmr1u2fhDO16lFa8YGvDyPp0PjPZFvbwz5Cvzat5fpyECnA03hM9lAg2DplglEbQqio2+E72IEcmoXWESMxH4jWqJafPyekaPhOB5Hkwu3tnS5Prkj5xTgqlrv0CxR8FvUzFt9c7STCBZmv7CNf+ketS2YJnT/xGfuL1MeiBomxcKozo/zjvsitK5chjiNrPzfYYjXMd9ja2qDYcjSJIu2lst9T/0cmpYzKVvbrS+zN3AKMK1jB920+7gr+RQvW+Ky71EF07EdQVEB3cX9qVwUEwN5gFxBKPJcQ8+2zLjaH89DjNxk32CG67IM4/ndLSDdsXmh/NgRv7ZJMdM7EN+Cugy3wzqTnGuxTh8sbqtWGtCe9jdxBuOg3817hr+ib6sbngBwbef8cYPLasHsv8WnvBsUBL1fBRUSeaebRZMC9JYom6RyB0cjqxAIN/vRxG9146NBX6SPUDAlIz9BLq+a1kgXJozRja97NRDEL3BWxu7yGCEVyRGY X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Johannes Thumshirn Now that all callers of bio_add_folio() check the return value, mark it as __must_check. Signed-off-by: Johannes Thumshirn --- include/linux/bio.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/bio.h b/include/linux/bio.h index 99fa832db836..36cfc091caed 100644 --- a/include/linux/bio.h +++ b/include/linux/bio.h @@ -466,7 +466,7 @@ void bio_reset(struct bio *bio, struct block_device *bdev, blk_opf_t opf); void bio_chain(struct bio *, struct bio *); int __must_check bio_add_page(struct bio *, struct page *, unsigned len, unsigned off); -bool bio_add_folio(struct bio *, struct folio *, size_t len, size_t off); +bool __must_check bio_add_folio(struct bio *, struct folio *, size_t len, size_t off); extern int bio_add_pc_page(struct request_queue *, struct bio *, struct page *, unsigned int, unsigned int); int bio_add_zone_append_page(struct bio *bio, struct page *page,