Received: by 10.223.176.46 with SMTP id f43csp206574wra; Fri, 19 Jan 2018 16:17:22 -0800 (PST) X-Google-Smtp-Source: AH8x225nBoQgrdurAt3zdhfwVwmlBCvfRfvuDG/JbHFPWFc71grA1+0vJfkmu5LoCcqm9snC8jJS X-Received: by 10.101.75.141 with SMTP id t13mr244590pgq.232.1516407442379; Fri, 19 Jan 2018 16:17:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516407442; cv=none; d=google.com; s=arc-20160816; b=mN3mITelDa/q7bY4XjYwZEtITTacUW4D5Dvbs+a4gAoRLbRJCkKHCHxdmn0oMMB8cQ mTlSqcO6zoIqdeFDUpwClsZOTlx/UNq6CEbKw1z30p6daQiihu4l9QbbOyFKAGHhGzSF 0Guza74UNg6wL/6u0/y936xXQOwGmmAKjHbq9A7ti/r3vKB2XMZ1aGDQjBuBUczGLO7A NCfQX0iz8sJOVCKYw0FDam5x30KURvrWFlcQB86sX3+3hfMC2OvgVanuzRDLK9MNtCgR LZ+4o2zWOvs9iLSdMvSFCjWTWAvwxrQuSCctYoQUfPwaUBKXungOc0ChKMBxe67FXH6/ U9nQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:references:in-reply-to:mime-version :dkim-signature:arc-authentication-results; bh=p+4QQXVfyBau7Ww5eCRCF0uBPcSysLktlzSLuZ4N9hk=; b=PipM3df959H84V6utpP/gMWPFA//sKRxdctbzcgEYI5X9bVELsgHCdfHSfjaAGNA2R 2xh6fp4I0HBkako9zlx9Kl24/cTZbILFeGFwu2q7vg9aA16jaoxUCQDPyMUQNJb6FTKo 51eDghe+5kSKibXjnN1+Xd/XjyZ6nhKhbn3FTn0FysEQGICGqyrzLyhRedqx8d+nXcYN P0PoQT7srpbfZbW0xU5lZAIrXIcNrGw9PBudspW2lAxF58ctBiJRQAIWZsZzRuQ4xTFZ /JmWgIZmPmErDZGt6HpIsctHRNDgDfv7/W46agMm2woeXYEV27hYpV0RkqEtofif4v3n Wx+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Ts5ihdmB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t12si9121222pgq.425.2018.01.19.16.17.07; Fri, 19 Jan 2018 16:17:22 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Ts5ihdmB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756225AbeATAPi (ORCPT + 99 others); Fri, 19 Jan 2018 19:15:38 -0500 Received: from mail-oi0-f44.google.com ([209.85.218.44]:43020 "EHLO mail-oi0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752938AbeATAPb (ORCPT ); Fri, 19 Jan 2018 19:15:31 -0500 Received: by mail-oi0-f44.google.com with SMTP id t16so2296121oif.10 for ; Fri, 19 Jan 2018 16:15:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=p+4QQXVfyBau7Ww5eCRCF0uBPcSysLktlzSLuZ4N9hk=; b=Ts5ihdmBOLvqgKcjnHU4vu3+rPjxNvytOJ8cxlcQaRgZyCp2WgcNHSg+bKFa1wOAMT lxNWKG1WX0EeI8gSeaaKhg1MMTZqXC+L63hwVa3xpq2mhH1mL23U4Bk/w/bGGksNFWlD /RBu+egPpNwxOV9msJfxxJg2NKbxH6NN8cp/V2yJWXof+Uc4SEs9OIKbETrYd3GUygU7 K/tPN3skI9U5/PNk+oGPcwVmgqhzW2Uk12iEKe7WQb9GybtQrc4EpDOhPeNUDU+BR1TC Wl0kj6ZU6PDBvqjfXqyM//Q30++cQ9Rk0dJT8IDfXniu2sjUYPNcIayKsQM3mXuM7ecF JqHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=p+4QQXVfyBau7Ww5eCRCF0uBPcSysLktlzSLuZ4N9hk=; b=b5Df+w4InkDhjEQfqOL83FhvDMnMk1X3AyZv4Mdk+J+KDXFRM0ww7Cv/qa5jqgdGWG 8Kbmh05KDz5qH13jr+yGEruDkXg8DJJ9X5PdD9Ocl0ppwA+TKep/8Qbq1nhXS1anMquN wOt8b0LzUrD1rTWnd3o4CHlw3V+iaIMjOtzEgJSxS4FafuEaYJ3kqwbQW8bBEQBE6JIu n3amkeCKEg8wDF8/HmmrqHIbrE6jw5Tc086o2kHnKqRh8RXYnHeBEc18QcfV4q6+hWtE fiHunfENoTT0UEaRTURPlazjcT0qIt3seDJetB9+yyTLwDw0VZXzEbSKYrD7TMaYD7Mj rk2g== X-Gm-Message-State: AKwxytdVFotjNm4wtkPDvlSbrQ2CtlF2Phgl9GeiCHsgL1CCl6mF+2fO ekipMe/5k0AKDSSsxmEjLF/XJfacW7E/E0MP13L26Q== X-Received: by 10.202.80.68 with SMTP id e65mr150607oib.304.1516407329773; Fri, 19 Jan 2018 16:15:29 -0800 (PST) MIME-Version: 1.0 Received: by 10.157.62.72 with HTTP; Fri, 19 Jan 2018 16:15:29 -0800 (PST) In-Reply-To: <20180118000602.5527-1-jschoenh@amazon.de> References: <20180118000602.5527-1-jschoenh@amazon.de> From: Dan Williams Date: Fri, 19 Jan 2018 16:15:29 -0800 Message-ID: Subject: Re: [PATCH 1/2] mm: Fix memory size alignment in devm_memremap_pages_release() To: =?UTF-8?Q?Jan_H=2E_Sch=C3=B6nherr?= Cc: Andrew Morton , Linux MM , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 17, 2018 at 4:06 PM, Jan H. Sch=C3=B6nherr = wrote: > The functions devm_memremap_pages() and devm_memremap_pages_release() use > different ways to calculate the section-aligned amount of memory. The > latter function may use an incorrect size if the memory region is small > but straddles a section border. > > Use the same code for both. > > Fixes: 5f29a77cd957 ("mm: fix mixed zone detection in devm_memremap_pages= ") > Signed-off-by: Jan H. Sch=C3=B6nherr Looks good to me, applied for 4.16.