Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753319AbbBXQVc (ORCPT ); Tue, 24 Feb 2015 11:21:32 -0500 Received: from userp1040.oracle.com ([156.151.31.81]:29501 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752503AbbBXQVb (ORCPT ); Tue, 24 Feb 2015 11:21:31 -0500 Date: Tue, 24 Feb 2015 17:23:18 +0100 From: Quentin Casasnovas To: Borislav Petkov Cc: X86 ML , LKML , Quentin Casasnovas Subject: Re: [PATCH 07/13] x86/microcode/intel: Rename update_match_revision() Message-ID: <20150224162318.GG4565@chrystal.uk.oracle.com> References: <1424774232-5981-1-git-send-email-bp@alien8.de> <1424774232-5981-8-git-send-email-bp@alien8.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1424774232-5981-8-git-send-email-bp@alien8.de> User-Agent: Mutt/1.5.22 (2013-10-16) X-Source-IP: aserv0022.oracle.com [141.146.126.234] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 948 Lines: 25 On Tue, Feb 24, 2015 at 11:37:06AM +0100, Borislav Petkov wrote: > +++ b/arch/x86/include/asm/microcode_intel.h > @@ -60,8 +60,12 @@ extern int > get_matching_microcode(unsigned int csig, int cpf, void *mc, int rev); > extern int microcode_sanity_check(void *mc, int print_err); > extern int get_matching_sig(unsigned int csig, int cpf, void *mc, int rev); > -extern int > -update_match_revision(struct microcode_header_intel *mc_header, int rev); > + > +static inline int > +revision_is_newer(struct microcode_header_intel *mc_header, int rev) > +{ > + return (mc_header->rev <= rev) ? 0 : 1; > +} > Minor nit-pick, if you reverse your inequality, you don't need for the ternary operator. Quentin -- 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/