From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF7C1C4CECE for ; Mon, 14 Oct 2019 07:44:14 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7C17620663 for ; Mon, 14 Oct 2019 07:44:14 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="bqj5jpv8" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7C17620663 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arndb.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=x+9JCxnPbO4g5dogwXZzXI8XcGZGtyJXELYZjFSnWg0=; b=bqj5jpv8lhrn2e P4DDJ/q8OOb7GCaA+8JE0LnGMLrxvPnTW5GAsmgqykchjEenKLj0/GmlXw/CbSAFPV9GFRKStHxTc kIYOru7704qzwJUWcb9RTzAIG7s8cOJpErBc+vUXiPMcnlF4jvWOuDQ0VnQL3BdmlUEKLXzGWrm5e tVEQ2weMZ+1FOx3LBk0/uURBee9kjYDKXYn+jdv/eePOLsE3S07isLUP8RJJ2JHpOw2mSJSQ2Xzng xMh3vbtF2GixfhI+gw6d3+VwcCkdmY9xUfGP+QMsTR7dmK1NA3mNikdjG7b+b0dU0SHvfIAhvN0fE 2zLMOuQRugn/LyJNrqxg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iJv1a-0002cl-0G; Mon, 14 Oct 2019 07:44:14 +0000 Received: from mail-qk1-f196.google.com ([209.85.222.196]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iJv1W-0002cR-GA for linux-arm-kernel@lists.infradead.org; Mon, 14 Oct 2019 07:44:11 +0000 Received: by mail-qk1-f196.google.com with SMTP id x134so15090336qkb.0 for ; Mon, 14 Oct 2019 00:44:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Th8+PaRjqfrVclFmGSa4ziCjIND3/k2iwSpjIet79bA=; b=mmrkWxcr4KirI1wHC6yclWCFKJBuJomBBBUi8T6GiuqpA5OyfvbeHNheZTEBkGj2ra yJgZG/cj7pDH+0q/p1C7z1FxLa+yQxiowd80lZBwZfXwnLu/5sUXmKgBppjRyQ9YaBjY 1uO+hTo5jHy2I0XYtQ5ELsPMOs/UNOeuk3hZdWCgjLiTyN61aD2N5c9Yhsc5qGAtVRXF 0crMzVMDmJ7hUgAAivrWhZFC5lvOcufGbxLpOL5Dr2IyrPY1ytThUfvvWZq2VIxYUB9U xMEV1JdKdYHKkjzgrTkJl6edGFBte8zNOs+7q78unhYjIxq/EzsSGz/pT6/ZUHD07r1h wD2g== X-Gm-Message-State: APjAAAUFeoNPkhE8xDkKqrZyoM1SbWC4vRw+upDGsVUo5opWweTE3O7M xs1lG4cXOxuwrPETK4ury+JeNzaDRl4ANcipo/w= X-Google-Smtp-Source: APXvYqyc3WuiQQNChn49ipIYrsi7R8Cr3Z39fmTe75l40EWivcSBqQ8SM08Qr+aAqEkiACVAE48OuzJZkDMb4DgD8ZI= X-Received: by 2002:a37:9442:: with SMTP id w63mr28085661qkd.138.1571039049189; Mon, 14 Oct 2019 00:44:09 -0700 (PDT) MIME-Version: 1.0 References: <20191013221310.30748-1-sebastian@breakpoint.cc> <20191013221310.30748-7-sebastian@breakpoint.cc> In-Reply-To: <20191013221310.30748-7-sebastian@breakpoint.cc> From: Arnd Bergmann Date: Mon, 14 Oct 2019 09:43:53 +0200 Message-ID: Subject: Re: [PATCH 6/6] ARM: Inline locking functions for !PREEMPTION To: Sebastian Andrzej Siewior X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191014_004410_540160_FB4736E5 X-CRM114-Status: GOOD ( 14.75 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Zijlstra , Russell King , Ingo Molnar , Waiman Long , Will Deacon , Linux ARM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Oct 14, 2019 at 12:14 AM Sebastian Andrzej Siewior wrote: > > On non-preemptive kernels, the locking instruction is less than 64 bytes > and it makes sense to inline it. With PREEMPTION the kernel becomes very > big if the locks are inlined. > > Signed-off-by: Sebastian Andrzej Siewior > --- At the moment, we have two architectures selecting all 28 symbols and you are adding a third, all other architecture select none of them. This tells me that the configurability has gone a little overboard. How about adding a shortcut ARCH_INLINE_ALL_SPINLOCKS that selects the 28 symbols and using that for arm/arm64/s390? Also, the output of 'size vmlinux' before and after the patch for multi_v7_defconfig would be useful to have in the changelog, as there are a couple of platforms that are particularly sensitive to object code size changes. Arnd > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig > index 4c780e7387208..21edc8e649261 100644 > --- a/arch/arm/Kconfig > +++ b/arch/arm/Kconfig > @@ -26,6 +26,32 @@ config ARM > select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST > select ARCH_HAVE_CUSTOM_GPIO_H > select ARCH_HAS_GCOV_PROFILE_ALL > + select ARCH_INLINE_READ_LOCK if !PREEMPTION > + select ARCH_INLINE_READ_LOCK_BH if !PREEMPTION > + select ARCH_INLINE_READ_LOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_READ_LOCK_IRQSAVE if !PREEMPTION > + select ARCH_INLINE_READ_UNLOCK if !PREEMPTION > + select ARCH_INLINE_READ_UNLOCK_BH if !PREEMPTION > + select ARCH_INLINE_READ_UNLOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_READ_UNLOCK_IRQRESTORE if !PREEMPTION > + select ARCH_INLINE_WRITE_LOCK if !PREEMPTION > + select ARCH_INLINE_WRITE_LOCK_BH if !PREEMPTION > + select ARCH_INLINE_WRITE_LOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_WRITE_LOCK_IRQSAVE if !PREEMPTION > + select ARCH_INLINE_WRITE_UNLOCK if !PREEMPTION > + select ARCH_INLINE_WRITE_UNLOCK_BH if !PREEMPTION > + select ARCH_INLINE_WRITE_UNLOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE if !PREEMPTION > + select ARCH_INLINE_SPIN_TRYLOCK if !PREEMPTION > + select ARCH_INLINE_SPIN_TRYLOCK_BH if !PREEMPTION > + select ARCH_INLINE_SPIN_LOCK if !PREEMPTION > + select ARCH_INLINE_SPIN_LOCK_BH if !PREEMPTION > + select ARCH_INLINE_SPIN_LOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_SPIN_LOCK_IRQSAVE if !PREEMPTION > + select ARCH_INLINE_SPIN_UNLOCK if !PREEMPTION > + select ARCH_INLINE_SPIN_UNLOCK_BH if !PREEMPTION > + select ARCH_INLINE_SPIN_UNLOCK_IRQ if !PREEMPTION > + select ARCH_INLINE_SPIN_UNLOCK_IRQRESTORE if !PREEMPTION > select ARCH_KEEP_MEMBLOCK if HAVE_ARCH_PFN_VALID || KEXEC > select ARCH_MIGHT_HAVE_PC_PARPORT > select ARCH_NO_SG_CHAIN if !ARM_HAS_SG_CHAIN > -- > 2.23.0 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel