From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752324AbeBBXG4 (ORCPT ); Fri, 2 Feb 2018 18:06:56 -0500 Received: from smtp-fw-9102.amazon.com ([207.171.184.29]:11856 "EHLO smtp-fw-9102.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752125AbeBBXGf (ORCPT ); Fri, 2 Feb 2018 18:06:35 -0500 X-IronPort-AV: E=Sophos;i="5.46,451,1511827200"; d="scan'208";a="592663351" Subject: Re: [PATCH] x86: e820: Implement a range manipulation operator To: Andy Shevchenko Cc: Ingo Molnar , Thomas Gleixner , x86@kernel.org, "H. Peter Anvin" , Linux Kernel Mailing List References: <20180201231313.28458-1-jschoenh@amazon.de> From: "=?UTF-8?Q?Jan_H._Sch=c3=b6nherr?=" Message-ID: Date: Sat, 3 Feb 2018 00:06:26 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 02/02/2018 09:50 PM, Andy Shevchenko wrote: > On Fri, Feb 2, 2018 at 1:13 AM, Jan H. Schönherr wrote: > >> + [KNL,ACPI] Convert memory within the specified region >> + from to . If "-" is left >> + out, the whole region will be marked as , >> + even if previously unavailable. If "+" is left >> + out, matching memory will be removed. Types are >> + specified as e820 types, eg, 1==RAM, 2==reserved, >> + 3==ACPI, 12==PRAM. > > s/==/ = /g Sure. I've also properly abbreviated that "e.g.". >> + } else if (*p == '%') { >> + enum e820_type from = 0, to = 0; >> + >> + start_at = memparse(p + 1, &p); >> + if (*p == '-') >> + from = simple_strtoull(p + 1, &p, 0); >> + if (*p == '+') >> + to = simple_strtoull(p + 1, &p, 0); >> + if (*p != 0) > > if (*p) > > or > > if (*p != '\0') > > ? Something similar to the latter is used in the function already. The latter it is. Regards Jan