Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1740582

Re: [PATCH] percpu: make this_cpu_generic_read() atomic w.r.t. interrupts

From Mark Rutland <mark.rutland@arm.com>
Newsgroups linux.kernel
Subject Re: [PATCH] percpu: make this_cpu_generic_read() atomic w.r.t. interrupts
Date 2017-09-27 12:20 +0200
Message-ID <uuhBD-16K-3@gated-at.bofh.it> (permalink)
References (3 earlier) <utDNU-8jd-19@gated-at.bofh.it> <utRQS-150-29@gated-at.bofh.it> <utSMW-1IU-9@gated-at.bofh.it> <uu1dw-7dY-15@gated-at.bofh.it> <uugvU-kx-33@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Sep 27, 2017 at 11:01:13AM +0200, Thomas Gleixner wrote:
> The default for 32bit architectures is that they CANNOT do atomic
> fetch/write of 8 bytes.

Indeed.

In addition, even the native word size accesses weren't guaranteed to be
atomic, as we hadn't used the appropriate accessors to prevent the
compiler from messing with things behind our backs.

> So instead of forcing that to be implemented in every affected
> architecture this wants to be addressed in generic code and those few
> 32bit architectures which can do atomic double word fetch/write
> implement the magic functions to do so.

I've done this in v2 [1], which Tejun has queued [2] as a fix for v4.14.

Thanks,
Mark.

[1] https://lkml.kernel.org/r/1506426112-19826-1-git-send-email-mark.rutland@arm.com
[2] https://lkml.kernel.org/r/20170926144118.GA70381@devbig577.frc2.facebook.com

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: [PATCH] percpu: make this_cpu_generic_read() atomic w.r.t.  interrupts Christopher Lameter <cl@linux.com> - 2017-09-26 18:50 +0200
  Re: [PATCH] percpu: make this_cpu_generic_read() atomic w.r.t.  interrupts Thomas Gleixner <tglx@linutronix.de> - 2017-09-27 11:10 +0200
    Re: [PATCH] percpu: make this_cpu_generic_read() atomic w.r.t.  interrupts Mark Rutland <mark.rutland@arm.com> - 2017-09-27 12:20 +0200

csiph-web