From mboxrd@z Thu Jan 1 00:00:00 1970 From: torvalds@linux-foundation.org (Linus Torvalds) Date: Thu, 30 Apr 2009 09:16:31 -0700 (PDT) Subject: [ltt-dev] [PATCH] Fix dirty page accounting in redirty_page_for_writepage() In-Reply-To: <20090430160606.GA5913@elte.hu> References: <20090430133859.GB8329@elte.hu> <20090430141446.GD14696@elte.hu> <20090430143819.GF14696@elte.hu> <20090430150142.GC20580@elte.hu> <20090430154255.GA3714@elte.hu> <20090430160606.GA5913@elte.hu> Message-ID: On Thu, 30 Apr 2009, Ingo Molnar wrote: > > c0436275: 64 83 05 20 5f 6a c0 addl $0x1,%fs:0xc06a5f20 > > There's no atomic instructions at all - the counters here are only > accessed locally. They are local-irq-atomic, but not > cacheline-atomic. On other architectures, you need the whole "disable preemption, load-locked, store-conditional, test-and-loop, enable preemption" thing. Or "disable interrupts, load, store, restore interrupts". There really aren't very many architectures that can do almost unrestricted ALU ops in a single instruction (and thus automatically safe from preemption and interrupts). Linus