From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751942AbcF0LA6 (ORCPT ); Mon, 27 Jun 2016 07:00:58 -0400 Received: from mail-wm0-f41.google.com ([74.125.82.41]:37571 "EHLO mail-wm0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751886AbcF0LA4 (ORCPT ); Mon, 27 Jun 2016 07:00:56 -0400 Date: Mon, 27 Jun 2016 13:00:50 +0200 From: Ingo Molnar To: Matt Fleming Cc: Thomas Gleixner , "H . Peter Anvin" , Alex Thorlton , Ard Biesheuvel , linux-kernel@vger.kernel.org, linux-efi@vger.kernel.org, Catalin Marinas , Dimitri Sivanich , Ingo Molnar , Mark Rutland , Roy Franz , Russ Anderson , Russell King , Will Deacon Subject: Re: [PATCH 4/7] efi: Convert efi_call_virt to efi_call_virt_pointer Message-ID: <20160627110050.GB9099@gmail.com> References: <1466839230-12781-1-git-send-email-matt@codeblueprint.co.uk> <1466839230-12781-5-git-send-email-matt@codeblueprint.co.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1466839230-12781-5-git-send-email-matt@codeblueprint.co.uk> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Matt Fleming wrote: > +#define efi_call_virt_pointer(p, f, args...) \ > +({ \ > + efi_status_t __s; \ > + unsigned long flags; \ > + \ > + arch_efi_call_virt_setup(); \ > + \ > + local_save_flags(flags); \ > + __s = arch_efi_call_virt(p, f, args); \ > + efi_call_virt_check_flags(flags, __stringify(f)); \ > + \ > + arch_efi_call_virt_teardown(); \ > + \ > + __s; \ > +}) > + > +#define __efi_call_virt_pointer(p, f, args...) \ > +({ \ > + unsigned long flags; \ > + \ > + arch_efi_call_virt_setup(); \ > + \ > + local_save_flags(flags); \ > + arch_efi_call_virt(p, f, args); \ > + efi_call_virt_check_flags(flags, __stringify(f)); \ > + \ > + arch_efi_call_virt_teardown(); \ > +}) Note that while at it I renamed 'flags' to '__flags' because 'flags' is a commonly used variable name and the 'efi_status_t __s' variable was macro-prefixed already. Any objections? Thanks, Ingo