Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753828AbbDTQIk (ORCPT ); Mon, 20 Apr 2015 12:08:40 -0400 Received: from mail-ie0-f171.google.com ([209.85.223.171]:35531 "EHLO mail-ie0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750973AbbDTQIi (ORCPT ); Mon, 20 Apr 2015 12:08:38 -0400 MIME-Version: 1.0 In-Reply-To: <1429544753-4120-1-git-send-email-a.ryabinin@samsung.com> References: <1429544753-4120-1-git-send-email-a.ryabinin@samsung.com> Date: Mon, 20 Apr 2015 09:08:37 -0700 X-Google-Sender-Auth: DG0QOyNAbNnGgC5KlRBVicYH-5I Message-ID: Subject: Re: [PATCH] arm64: Implement 1-,2- byte smp_load_acquire and smp_store_release From: Linus Torvalds To: Andrey Ryabinin Cc: Catalin Marinas , Will Deacon , "Paul E. McKenney" , Peter Zijlstra , "linux-arm-kernel@lists.infradead.org" , Linux Kernel Mailing List Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1025 Lines: 24 On Mon, Apr 20, 2015 at 8:45 AM, Andrey Ryabinin wrote: > > Commit 8053871d0f7f ("smp: Fix smp_call_function_single_async() locking") > started to use smp_load_acquire() to load 2-bytes csd->flags. > That crashes arm64 kernel during the boot. Ahh. I don't disagree with your patch, but we should just make csd->flags be an "int" regardless of this issue. There is absolutely no reason to try to use 16-bit words. It doesn't save us any space (alignment), and it's just a *bad* idea to depend on any kind of atomicity of 16-bit entities. Bytes, yes. Words, yes. But 16-bit half-words? There's no point. So I'll make it "unsigned int" instead of "u16". But as said, the ARM64 patch definitely is a good idea regardless. Linus -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/