Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1189322imu; Tue, 11 Dec 2018 14:26:39 -0800 (PST) X-Google-Smtp-Source: AFSGD/VF/1QroxXlUxIs9fSzheI7WpoiPIJwYmpy+87u5rsZc0a83qdk2NSQANLFZQkphye801xb X-Received: by 2002:a62:5950:: with SMTP id n77mr17820343pfb.128.1544567199322; Tue, 11 Dec 2018 14:26:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544567199; cv=none; d=google.com; s=arc-20160816; b=VE0eE+/T6HI37qk0NADMmiPEWjT96REV1buQBQk+/WBfNuu17L/YPfX5vdJRYr+cH/ GOB4N6r2EfR8j+TL5I3neGgkyQrahwv7RuzdM8WKquJ8DgubZ2DcP+L7iTNJIOMb6XgI uVQEOsgGivR/jAtDP90tond6F0fx1M1/TmhnyTUJRUXzNxNdjaJhHblkTXDEsf7jkOZo ++wO0yQWmHUH6RYd6fP3GWtssz1i9GgVrnjAYGFpA4x4IrdkxEGh6jSW7HRdgtxDjfG8 qxxzmLRN/zq84OCMuflTAINZFipRuNpLp/l6UGb8Va96RdOcvoa9pIwshsTueNOeubNP U2JQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=0QRHmOX9pOxuQEveIxHJT8YsVZ8O9ehPXeitj8Ev49Q=; b=pjwvsEqkXvskYhGtJvx+GGTlfl17eKl9dvByGcxtb55fPqrDtHL6nrK6F1ZOYbowPn ruVELau/wxI1e20raFPUGzDZCrZchonNlLWRMnyvxmpPN+7TMCiZwHTg9cTxdoCBQfEP bUf6wtCq3Y7plbwjDqISzEaw5cehQV2F3Jzwk22/QsZa+bzXJWgaYz8nylsJE3+Bofig 4XzXdXIAESZUhM1ypeu0VxERlNbxTYxtiu+lJ4y60mvr8MFN7Cm+Bvzi0sUX8LnHLE6u WQZIi4CwwaCDDepSV+/i6gixBIyw1eT3NWM7caRkHDp8TPorvkxAjm0DgqXuQnSsg9hL 5eyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=mPRQjjPK; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 26si12762537pgu.190.2018.12.11.14.26.24; Tue, 11 Dec 2018 14:26:39 -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=@google.com header.s=20161025 header.b=mPRQjjPK; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726363AbeLKWZF (ORCPT + 99 others); Tue, 11 Dec 2018 17:25:05 -0500 Received: from mail-pl1-f193.google.com ([209.85.214.193]:45214 "EHLO mail-pl1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726215AbeLKWZF (ORCPT ); Tue, 11 Dec 2018 17:25:05 -0500 Received: by mail-pl1-f193.google.com with SMTP id a14so7575066plm.12 for ; Tue, 11 Dec 2018 14:25:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=0QRHmOX9pOxuQEveIxHJT8YsVZ8O9ehPXeitj8Ev49Q=; b=mPRQjjPKzEJ0PD4XUPmHNHtc/FmuH01KydfsgMF9KYjcJWV3GmwhgoewBPNaw6aSph fQnAJ3GsDPqugwRCMkZWmnqxmhbgTYAxfH1wYIbU73uzkudkpI+O8JRKs9vr+5ZZZmSE f7yd0F7WLyDRsRp8sEmEeRlTfPAMzTyYQKty5EErKpb4lWzA2zqdCAeJI5J56V60Fpff eZhJq4myLL88ZCpvkSkChZ4jvFL62sVBsjJjOFwgbg/tubge8qVjxloU1kpNHdy1Ty6L Qv80YGnXx9mkXj5xTaBldSsgEk7M0+rdPR5TVsSJTyZmgzD4+6vaX6RlJ5jcCzCvQ5KH 0IQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=0QRHmOX9pOxuQEveIxHJT8YsVZ8O9ehPXeitj8Ev49Q=; b=d/cgyAPACQrCxai1rEyiX0xCek7TiNbneGDc6Kv4aGgCMLgkgjltrI7eWHj6hN2efA FJlPiI4xjythIqnak+rPMOZqLwMQbicKPm2fvoOy0M9PWWwnArt1L48ZIqOCJelm0R8m Dy7aVTHos1k5Coy3aNSyJNn8GDCI8sk/9TTP/BRCts+61AmszXM61uiC+qvEpu5dEo9y iGeYuCvc2jlDiv2RX5fWmM3WVK7NNKorveng0N2mBZYqVw4mcr3M6zn5MHPdzbosrfLM WKS9dH/X+x013+t/QbsjyE13A+ThhST7v2T1LWKaTI5DGqJyyCDDL1Q7khig9e10Jpri GcXA== X-Gm-Message-State: AA+aEWYu8MIDfDGE1URUeUfbkXL7xnFQu55Eb49SbT6bYeH5OatJr1EO 4MejbqG/z9+SwsDiwFhhQOBs+w== X-Received: by 2002:a17:902:d68c:: with SMTP id v12mr17411398ply.4.1544567104320; Tue, 11 Dec 2018 14:25:04 -0800 (PST) Received: from [2620:15c:17:3:3a5:23a7:5e32:4598] ([2620:15c:17:3:3a5:23a7:5e32:4598]) by smtp.gmail.com with ESMTPSA id p67sm31082581pfi.85.2018.12.11.14.25.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 11 Dec 2018 14:25:03 -0800 (PST) Date: Tue, 11 Dec 2018 14:25:02 -0800 (PST) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Arnd Bergmann cc: =?UTF-8?Q?J=C3=A9r=C3=B4me_Glisse?= , Andrew Morton , Stephen Rothwell , Michal Hocko , Mike Rapoport , Linux Kernel Mailing List Subject: Re: [PATCH] mm/mmu_notifier: fix mmu_notifier_range_init warning In-Reply-To: Message-ID: References: <20181211200526.3868586-1-arnd@arndb.de> <20181211201909.GA6478@redhat.com> <20181211213636.GB6478@redhat.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 11 Dec 2018, Arnd Bergmann wrote: > > Hmm, strange that Arnd's build failure is only reporting about an unused > > variable instead of MMU_NOTIFY_CLEAR being undefined :/ > > > > I think this should be done so that anybody using > > mmu_notifier_range_init() doesn't need to worry about the implications of > > *any* unused formal parameter as a result of how the #define is formed: > > Your patch below is more or less what I tried at first, and that resulted > in another build failure for > > mm/hugetlb.c: mmu_notifier_range_init(&range, mm, start, end, > MMU_NOTIFY_CLEAR); > mm/hugetlb.c- adjust_range_if_pmd_sharing_possible(vma, > &range.start, &range.end); > > where range.end refers to a nonexisting member of range. > Isn't that separate? It seems like there is a strict dependency that CONFIG_HUGETLBFS has on CONFIG_MMU_NOTIFIER.