[lkml]   [2019]   [Aug]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] btrfs: fix allocation of bitmap pages.
On Mon, Aug 19, 2019 at 07:46:00PM +0200, David Sterba wrote:
> Another thing that is lost is the slub debugging support for all
> architectures, because get_zeroed_pages lacking the red zones and sanity
> checks.
> I find working with raw pages in this code a bit inconsistent with the
> rest of btrfs code, but that's rather minor compared to the above.
> Summing it up, I think that the proper fix should go to copy_page
> implementation on architectures that require it or make it clear what
> are the copy_page constraints.

The whole point of copy_page is to copy exactly one page and it makes
sense to assume that is aligned. A sane memcpy would use the same
underlying primitives as well after checking they fit. So I think the
prime issue here is btrfs' use of copy_page instead of memcpy. The
secondary issue is slub fucking up alignments for no good reason. We
just got bitten by that crap again in XFS as well :(

 \ /
  Last update: 2019-08-20 04:30    [W:0.064 / U:4.996 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site