[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <51AF9D40.60906@linux.intel.com>
Date: Wed, 05 Jun 2013 13:19:12 -0700
From: "H. Peter Anvin" <hpa@...ux.intel.com>
To: Matt Fleming <matt@...sole-pimps.org>
CC: Matthew Garrett <matthew.garrett@...ula.com>,
"Fleming, Matt" <matt.fleming@...el.com>, joeyli <jlee@...e.com>,
"rja@....com" <rja@....com>, "mingo@...nel.org" <mingo@...nel.org>,
"torvalds@...ux-foundation.org" <torvalds@...ux-foundation.org>,
"bp@...en8.de" <bp@...en8.de>, "jkosina@...e.cz" <jkosina@...e.cz>,
"linux-efi@...r.kernel.org" <linux-efi@...r.kernel.org>,
"x86@...nel.org" <x86@...nel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
"oneukum@...e.de" <oneukum@...e.de>
Subject: Re: [PATCH] Modify UEFI anti-bricking code
On 06/05/2013 08:59 AM, Matt Fleming wrote:
> + * There still isn't enough room, so return an error
> + */
> + if (remaining_size - size < 5120)
> + return EFI_OUT_OF_RESOURCES;
> + }
Please don't open-code the constant 5120 in this case. We may easily
run into a system which needs, say, 7K, and it is error-prone to just
replace numbers.
-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists