Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1503599

Re: [PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after BIOS callback updates

From Alex Thorlton <athorlton@sgi.com>
Newsgroups linux.kernel
Subject Re: [PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after BIOS callback updates
Date 2016-10-19 16:20 +0200
Message-ID <stZSN-2nd-11@gated-at.bofh.it> (permalink)
References <stC0f-1Ip-15@gated-at.bofh.it> <stZSN-2nd-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Oct 19, 2016 at 12:32:00PM +0100, Matt Fleming wrote:
> Could you please invert the conditional? I had to read it 3 times to
> make sure it was correct given the comment that precedes it. E.g. this
> is preferable,
> 
> 	if (efi_enabled(EFI_OLD_MEMMAP))
> 		ret = efi_call((void *)__va(tab->function), (u64)which, a1, a2, a3, a4, a5);
> 	else
> 		ret = efi_call_virt_pointer(tab, function, (u64)which, a1, a2, a3, a4, a5);

Sure, no problem!  I generally default to checking for the more common
condition first, but I definitely see how that makes the code kind of
hard to read, in this case.

I'll send another version shortly.

Thanks, Matt!

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after BIOS callback updates Alex Thorlton <athorlton@sgi.com> - 2016-10-18 14:50 +0200
  Re: [PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after  BIOS callback updates Alex Thorlton <athorlton@sgi.com> - 2016-10-19 16:20 +0200
  Re: [PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after  BIOS callback updates Matt Fleming <matt@codeblueprint.co.uk> - 2016-10-19 16:30 +0200
    Re: [PATCH] x86/platform/UV: Fix support for EFI_OLD_MEMMAP after  BIOS callback updates Ingo Molnar <mingo@kernel.org> - 2016-10-19 17:00 +0200

csiph-web