public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Wang Yugui <wangyugui@e16-tech.com>
To: Filipe Manana <fdmanana@kernel.org>
Cc: linux-btrfs@vger.kernel.org, Filipe Manana <fdmanana@suse.com>,
	stable@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: Re: 6.1.140 build failure(fs/btrfs/discard.c:247:5: error: implicit declaration of function 'ASSERT')
Date: Sat, 31 May 2025 21:16:54 +0800	[thread overview]
Message-ID: <20250531211653.ED6C.409509F4@e16-tech.com> (raw)
In-Reply-To: <CAL3q7H48BBHKd-3DHCgfxbx5zbJvqfeAr=UV1hQFGj0Lw4DEzA@mail.gmail.com>

Hi,

> On Mon, May 26, 2025 at 6:40?AM Wang Yugui <wangyugui@e16-tech.com> wrote:
> >
> > 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).
> 
> Yes, it is.
> 
> The patch, like most stable backports, was automatically picked by the
> stable scripts and added to stable releases.
> I assume that before the release was made, it was compile tested by
> the stable automatic processes.
> 
> I just tried it, and it compiles successfully for me:
> 
> fdmanana 11:56:26 ~/git/hub/linux ((v6.12))> git clean -xfd
> fdmanana 11:57:27 ~/git/hub/linux ((v6.12))> git co v6.1.140
> fdmanana 11:59:53 ~/git/hub/linux ((v6.1.140))> make defconfig
> 
> fdmanana 12:02:17 ~/git/hub/linux ((v6.1.140))> grep BTRFS .config
> CONFIG_BTRFS_FS=m
> CONFIG_BTRFS_FS_POSIX_ACL=y
> CONFIG_BTRFS_FS_CHECK_INTEGRITY=y
> CONFIG_BTRFS_FS_RUN_SANITY_TESTS=y
> CONFIG_BTRFS_DEBUG=y
> CONFIG_BTRFS_ASSERT=y
> CONFIG_BTRFS_FS_REF_VERIFY=y
> 
> fdmanana 12:06:08 ~/git/hub/linux ((v6.1.140))> make fs/btrfs/btrfs.ko
>   LD [M]  fs/btrfs/btrfs.ko
> 
> fdmanana 12:11:12 ~/git/hub/linux ((v6.1.140))> gcc --version
> gcc (Debian 9.3.0-18) 9.3.0

Yes.  this build error does NOT happen on 6.1.140 upstream.

It happened here because of some local btrfs backuport of linux 6.2.

Sorry.

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

> >
> > I walked around it with the following patch.
> 
> In the future please cc the stable list when you find problems with
> stable backports.
> 
> >
> > 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-31 13:47 UTC|newest]

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

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=20250531211653.ED6C.409509F4@e16-tech.com \
    --to=wangyugui@e16-tech.com \
    --cc=fdmanana@kernel.org \
    --cc=fdmanana@suse.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=stable@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