public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Wang Yugui <wangyugui@e16-tech.com>
To: linux-btrfs@vger.kernel.org
Cc: Filipe Manana <fdmanana@suse.com>
Subject: 6.1.140 build failure(fs/btrfs/discard.c:247:5: error: implicit declaration of function 'ASSERT')
Date: Mon, 26 May 2025 13:40:28 +0800	[thread overview]
Message-ID: <20250526134027.187C.409509F4@e16-tech.com> (raw)

Hi,
Cc: Filipe Manana

I noticed 6.1.140 build failure(fs/btrfs/discard.c:247:5: error: implicit declaration of function 'ASSERT')

fs/btrfs/discard.c: In function 'peek_discard_list':
fs/btrfs/discard.c:247:5: error: implicit declaration of function 'ASSERT'; did you mean 'IS_ERR'? [-Werror=implicit-function-declaration]
     ASSERT(block_group->discard_index !=
     ^~~~~~
     IS_ERR

It seems realted to the patch(btrfs-fix-discard-worker-infinite-loop-after-disabling-discard.patch).

I walked around it with the following patch.

diff --git a/fs/btrfs/discard.c b/fs/btrfs/discard.c
index 98bce18..9ffe5c4 100644
--- a/fs/btrfs/discard.c
+++ b/fs/btrfs/discard.c
@@ -7,6 +7,7 @@
 #include <linux/math64.h>
 #include <linux/sizes.h>
 #include <linux/workqueue.h>
+#include "messages.h"
 #include "ctree.h"
 #include "block-group.h"
 #include "discard.h"


Best Regards
Wang Yugui (wangyugui@e16-tech.com)
2025/05/26



             reply	other threads:[~2025-05-26  5:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-26  5:40 Wang Yugui [this message]
2025-05-26  9:59 ` 6.1.140 build failure(fs/btrfs/discard.c:247:5: error: implicit declaration of function 'ASSERT') Qu Wenruo
2025-05-26 11:16 ` Filipe Manana
2025-05-31 13:16   ` Wang Yugui

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250526134027.187C.409509F4@e16-tech.com \
    --to=wangyugui@e16-tech.com \
    --cc=fdmanana@suse.com \
    --cc=linux-btrfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox