From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Google-Smtp-Source: AH8x2274cjAW1DiLPDjYayxAM+voxx1BeG88VzVwZfKfQuL7KG+Jl+w4y7YHvGUdvgRkEbDUbNRY ARC-Seal: i=1; a=rsa-sha256; t=1516721589; cv=none; d=google.com; s=arc-20160816; b=R9AhIWPuBodS57ppzJpOMuKYGUtSn4DuJUiU7uwKf9xTwC8tbrDJhIDPy3q5JcOX1f lcrBp477uui93qJ8phsqOGst2y7UCoiUFHX50IJRcly4jfI7/MBizculywPvqm3BNL3V waR1zZfrcYAKLJ6CcJgq6KTl0asnOhqGGTqjV9Lmlvig4EY/WKeDin1MTy8r941h+PCo 7WrRmHYa938Z1xZJAhNyOOtfeJqgZGAefaNcCMRVu+kssaoQVeA93JTTXDINiW+4uSTG 36f1xAlEnqXAUqf68Z2lySm+cUR9Ai2joHNGYPK7j0DweWeofX0Vq1xbaKmtPTysCxAW Rnwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-disposition:mime-version:references:subject:cc:to:from:date :user-agent:message-id:dkim-signature:arc-authentication-results; bh=ofAqT76ezopjGN4V/swmgxclHnohTN3X97yPs54JYQ8=; b=WieWEz0+nnfzgcDaZU+z1W43PMw4D6op9y1VImqw+IRetaq0uvBiBomm88V0GYOCcV DUDxC33b4nG1OdznsYtWtJakVE9V0rqmsK1SrU6vTBtmCNvwRgS2zFLjlSD4kOGTut4B SNxVeSd8qjJTp3kGNKt2RSIfSdm8dWjIVAuURD6q7ncO1hDFUI6d5xuto4ShmrhEH4AB 7eshMHVtZOa9/Tigr8kRA6LBrPBVF0bjsT8qtaAObPRFMwpuwtxXMESXXsQiX6lEOEU2 CNwvowvEJocXBx12edHdAOXBmiR4c1zzaKJ3Z7RMklHcHcQYmW/nmh8/BeD0zLKTCt0n k65Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b=LnAam/Gs; spf=pass (google.com: best guess record for domain of peterz@infradead.org designates 205.233.59.134 as permitted sender) smtp.mailfrom=peterz@infradead.org Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b=LnAam/Gs; spf=pass (google.com: best guess record for domain of peterz@infradead.org designates 205.233.59.134 as permitted sender) smtp.mailfrom=peterz@infradead.org Message-Id: <20180123152638.512294068@infradead.org> User-Agent: quilt/0.63-1 Date: Tue, 23 Jan 2018 16:25:48 +0100 From: Peter Zijlstra To: David Woodhouse , Thomas Gleixner , Josh Poimboeuf Cc: linux-kernel@vger.kernel.org, Dave Hansen , Ashok Raj , Tim Chen , Andy Lutomirski , Linus Torvalds , Greg KH , Andrea Arcangeli , Andi Kleen , Arjan Van De Ven , Dan Williams , Paolo Bonzini , Jun Nakajima , Asit Mallick , Jason Baron , Peter Zijlstra Subject: [PATCH 09/24] jump_label: Add branch hints to static_branch_{un,}likely() References: <20180123152539.374360046@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline; filename=peterz-jump_label-fix.patch X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: =?utf-8?q?1590397857505687509?= X-GMAIL-MSGID: =?utf-8?q?1590397857505687509?= X-Mailing-List: linux-kernel@vger.kernel.org List-ID: For some reason these were missing, I've not observed this patch making a difference in the few code locations I checked, but this makes sense. Cc: Jason Baron Signed-off-by: Peter Zijlstra (Intel) --- include/linux/jump_label.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/include/linux/jump_label.h +++ b/include/linux/jump_label.h @@ -388,7 +388,7 @@ extern bool ____wrong_branch_error(void) branch = !arch_static_branch_jump(&(x)->key, true); \ else \ branch = ____wrong_branch_error(); \ - branch; \ + likely(branch); \ }) #define static_branch_unlikely(x) \ @@ -400,7 +400,7 @@ extern bool ____wrong_branch_error(void) branch = arch_static_branch(&(x)->key, false); \ else \ branch = ____wrong_branch_error(); \ - branch; \ + unlikely(branch); \ }) #else /* !HAVE_JUMP_LABEL */