linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Matthew Wilcox <willy@infradead.org>
Cc: Linux MM <linux-mm@kvack.org>,
	Linux FS Devel <linux-fsdevel@vger.kernel.org>,
	 linux-s390 <linux-s390@vger.kernel.org>,
	 "linux-ia64@vger.kernel.org" <linux-ia64@vger.kernel.org>,
	 "open list:BROADCOM NVRAM DRIVER" <linux-mips@vger.kernel.org>,
	linux-m68k <linux-m68k@lists.linux-m68k.org>,
	 alpha <linux-alpha@vger.kernel.org>,
	linux-riscv@lists.infradead.org
Subject: Re: [PATCH v3 00/11] Make PageWriteback use the PageLocked optimisation
Date: Fri, 17 Apr 2020 09:28:14 +0200	[thread overview]
Message-ID: <CAMuHMdWxhVoPCZ5+=Pf1LFpdE9vPv9GGTqTYMQP9oFz7eCxDaQ@mail.gmail.com> (raw)
In-Reply-To: <20200416220130.13343-1-willy@infradead.org>

Hi Matthew,

On Fri, Apr 17, 2020 at 12:01 AM Matthew Wilcox <willy@infradead.org> wrote:
> From: "Matthew Wilcox (Oracle)" <willy@infradead.org>
> PageWaiters is used by PageWriteback and PageLocked (and no other page
> flags), so it makes sense to use the same codepaths that have already been
> optimised for PageLocked, even if there's probably no real performance
> benefit to be had.
>
> Unfortunately, clear_bit_unlock_is_negative_byte() isn't present on every
> architecture, and the default implementation is only available in filemap.c
> while I want to use it in page-writeback.c.  Rather than move the default
> implementation to a header file, I've done optimised implementations for
> alpha and ia64.  I can't figure out optimised implementations for m68k,
> mips, riscv and s390, so I've just replicated the effect of the generic
> implementation in them.  I leave it to the experts to fix that (... or
> convert over to using asm-generic/bitops/lock.h ...)
>
> v3:
>  - Added implementations of clear_bit_unlock_is_negative_byte()
>    to architectures which need it

I have two questions here?
  1. Why not implement arch_clear_bit_unlock_is_negative_byte()
     instead, so the kasan check in asm-generic is used everywhere?
  2. Why not add the default implementation to
     include/asm-generic/bitops/instrumented-lock.h, in case an arch_*()
     variant is not provided yet?

Note that you did 1 for s390.
Thanks!

Gr{oetje,eeting}s,

                        Geert


--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds


  parent reply	other threads:[~2020-04-17  7:28 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-16 22:01 Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 01/11] alpha: Add clear_bit_unlock_is_negative_byte implementation Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 02/11] ia64: " Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 03/11] m68k: " Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 04/11] mips: " Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 05/11] riscv: " Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 06/11] s390: " Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 07/11] mm: Remove definition of clear_bit_unlock_is_negative_byte Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 08/11] mm: Move PG_writeback into the bottom byte Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 09/11] mm: Convert writeback BUG to WARN_ON Matthew Wilcox
2020-04-23 15:58   ` Jan Kara
2020-04-16 22:01 ` [PATCH v3 10/11] mm: Use clear_bit_unlock_is_negative_byte for PageWriteback Matthew Wilcox
2020-04-16 22:01 ` [PATCH v3 11/11] mm: Remove TestClearPageWriteback Matthew Wilcox
2020-04-17  7:28 ` Geert Uytterhoeven [this message]
2020-04-17 11:12   ` [PATCH v3 00/11] Make PageWriteback use the PageLocked optimisation Matthew Wilcox

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='CAMuHMdWxhVoPCZ5+=Pf1LFpdE9vPv9GGTqTYMQP9oFz7eCxDaQ@mail.gmail.com' \
    --to=geert@linux-m68k.org \
    --cc=linux-alpha@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-m68k@lists.linux-m68k.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=willy@infradead.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