All of lore.kernel.org
 help / color / mirror / Atom feed
* [5.16.14] csum mismatch on free space cache on subpage
@ 2022-03-28 21:18 Matt Corallo
  2022-03-29  5:57 ` Qu Wenruo
  0 siblings, 1 reply; 4+ messages in thread
From: Matt Corallo @ 2022-03-28 21:18 UTC (permalink / raw)
  To: Btrfs BTRFS

Basically what the subject says. Any time I mount an fs on my 64K-page PPC host mount a 4K-page 
device (so far two-of-two - once a flash drive with mirror and nothing else, once a many-TB volume 
across multiple disks) I see a stream of csum mismatches in the space cache in dmesg. The FS' 
otherwise seem to work.

Matt

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [5.16.14] csum mismatch on free space cache on subpage
  2022-03-28 21:18 [5.16.14] csum mismatch on free space cache on subpage Matt Corallo
@ 2022-03-29  5:57 ` Qu Wenruo
  2022-03-29 12:58   ` David Sterba
  2022-03-29 16:02   ` Matt Corallo
  0 siblings, 2 replies; 4+ messages in thread
From: Qu Wenruo @ 2022-03-29  5:57 UTC (permalink / raw)
  To: Matt Corallo, Btrfs BTRFS



On 2022/3/29 05:18, Matt Corallo wrote:
> Basically what the subject says. Any time I mount an fs on my 64K-page
> PPC host mount a 4K-page device (so far two-of-two - once a flash drive
> with mirror and nothing else, once a many-TB volume across multiple
> disks) I see a stream of csum mismatches in the space cache in dmesg.
> The FS' otherwise seem to work.
>
> Matt

Oh, so you're using the subpage feature recently introduced, awesome!

But it looks like there are still some v1 cache code using hardcoded
PAGE_SIZE instead of sectorsize, thus it's reporting the problem.

You're completely fine to continue using the fs, as such PAGE_SIZE usage
will invalidate all old cache, thus there is no chance of corruption.

Or you can convert to v2 cache as a workaround.

I'll need to investigate some time for this fix.

Thanks,
Qu

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [5.16.14] csum mismatch on free space cache on subpage
  2022-03-29  5:57 ` Qu Wenruo
@ 2022-03-29 12:58   ` David Sterba
  2022-03-29 16:02   ` Matt Corallo
  1 sibling, 0 replies; 4+ messages in thread
From: David Sterba @ 2022-03-29 12:58 UTC (permalink / raw)
  To: Qu Wenruo; +Cc: Matt Corallo, Btrfs BTRFS

On Tue, Mar 29, 2022 at 01:57:18PM +0800, Qu Wenruo wrote:
> 
> 
> On 2022/3/29 05:18, Matt Corallo wrote:
> > Basically what the subject says. Any time I mount an fs on my 64K-page
> > PPC host mount a 4K-page device (so far two-of-two - once a flash drive
> > with mirror and nothing else, once a many-TB volume across multiple
> > disks) I see a stream of csum mismatches in the space cache in dmesg.
> > The FS' otherwise seem to work.
> >
> > Matt
> 
> Oh, so you're using the subpage feature recently introduced, awesome!
> 
> But it looks like there are still some v1 cache code using hardcoded
> PAGE_SIZE instead of sectorsize, thus it's reporting the problem.
> 
> You're completely fine to continue using the fs, as such PAGE_SIZE usage
> will invalidate all old cache, thus there is no chance of corruption.
> 
> Or you can convert to v2 cache as a workaround.
> 
> I'll need to investigate some time for this fix.

We can mandate free space tree for subpage, don't try to fix the v1 code
as it's going to be deleted in a year timeframe anyway.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [5.16.14] csum mismatch on free space cache on subpage
  2022-03-29  5:57 ` Qu Wenruo
  2022-03-29 12:58   ` David Sterba
@ 2022-03-29 16:02   ` Matt Corallo
  1 sibling, 0 replies; 4+ messages in thread
From: Matt Corallo @ 2022-03-29 16:02 UTC (permalink / raw)
  To: Qu Wenruo, Btrfs BTRFS



On 3/28/22 10:57 PM, Qu Wenruo wrote:
> 
> 
> On 2022/3/29 05:18, Matt Corallo wrote:
>> Basically what the subject says. Any time I mount an fs on my 64K-page
>> PPC host mount a 4K-page device (so far two-of-two - once a flash drive
>> with mirror and nothing else, once a many-TB volume across multiple
>> disks) I see a stream of csum mismatches in the space cache in dmesg.
>> The FS' otherwise seem to work.
>>
>> Matt
> 
> Oh, so you're using the subpage feature recently introduced, awesome!

Yep, been waiting on it since I got this box years ago so I can finally stop building kernels 
locally. Thanks so much for all your work on it!

> But it looks like there are still some v1 cache code using hardcoded
> PAGE_SIZE instead of sectorsize, thus it's reporting the problem.

Ah! Okay, thanks. Definitely strange to see the errors in syslog and not have them show up in `btrfs 
device stats`.

> You're completely fine to continue using the fs, as such PAGE_SIZE usage
> will invalidate all old cache, thus there is no chance of corruption.

Awesome, thanks.

> Or you can convert to v2 cache as a workaround.
> 
> I'll need to investigate some time for this fix.
> 
> Thanks,
> Qu

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-03-29 16:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-28 21:18 [5.16.14] csum mismatch on free space cache on subpage Matt Corallo
2022-03-29  5:57 ` Qu Wenruo
2022-03-29 12:58   ` David Sterba
2022-03-29 16:02   ` Matt Corallo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.