From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eddie.linux-mips.org ([148.251.95.138]:59926 "EHLO cvs.linux-mips.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754745AbcIMMnT (ORCPT ); Tue, 13 Sep 2016 08:43:19 -0400 Received: from localhost.localdomain ([127.0.0.1]:36468 "EHLO linux-mips.org" rhost-flags-OK-OK-OK-FAIL) by eddie.linux-mips.org with ESMTP id S23992279AbcIMMnRPFqKf (ORCPT ); Tue, 13 Sep 2016 14:43:17 +0200 Date: Tue, 13 Sep 2016 14:43:14 +0200 From: Ralf Baechle To: Paul Burton Cc: linux-mips@linux-mips.org, "stable # v4 . 4+" Subject: Re: [PATCH] MIPS: Remove compact branch policy Kconfig entries Message-ID: <20160913124314.GA20655@linux-mips.org> References: <20160912095806.4411-1-paul.burton@imgtec.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160912095806.4411-1-paul.burton@imgtec.com> Sender: stable-owner@vger.kernel.org List-ID: On Mon, Sep 12, 2016 at 10:58:06AM +0100, Paul Burton wrote: > Fixing this by hiding the Kconfig entry behind another seems to be more > hassle than it's worth, as MIPSr6 & compact branches have been around > for a while now and if policy does need to be set for debug it can be > done easily enough with KCFLAGS. Therefore remove the compact branch > policy Kconfig entries & their handling in the Makefile. I've applied your patch - and given where we are wrt. to R6 I think this simply and bulletproof solution is certainly the right thing. But, have you considered probing for the option and only using it where it actually is available with something like: cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_NEVER) += $(call cc-option,-mcompact-branches=never) cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_OPTIMAL) += $(call cc-option,-mcompact-branches=optimal) cflags-$(CONFIG_MIPS_COMPACT_BRANCHES_ALWAYS) += $(call cc-option,-mcompact-branches=always) ? I'm also wondering how much we gain from -mcompact-branches? Ralf