From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751861AbdIOTcK (ORCPT ); Fri, 15 Sep 2017 15:32:10 -0400 Received: from mout.kundenserver.de ([212.227.126.131]:50035 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751620AbdIOTcI (ORCPT ); Fri, 15 Sep 2017 15:32:08 -0400 From: Arnd Bergmann To: Andrew Morton Cc: Arnd Bergmann , Michal Hocko , Vlastimil Babka , Mel Gorman , Hillf Danton , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH] mm: meminit: mark init_reserved_page as __meminit Date: Fri, 15 Sep 2017 21:31:30 +0200 Message-Id: <20170915193149.901180-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:rugLZlvsziAul8pryBXcT/MIaD4rSWkMXUquYskxBBsH7KqhbWq 0BpZAY1RiyDrSB921fc6SjQ1M0gy0xHv60eyR9cXhJX2KElev9UYwMhUBTtllagWw121EZm 4LhmzkFS72/H34eHTd47idJtEGY4zwhRbgr+dFDTKbu1U5XLYpnTSWQNC0hKV9pMeJLw6Nb RaZFpJcQAAhbNIhZqRgXQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:F576bJSuem0=:eSJif6GLyWWVB4YV6es8NE 3D0hefFBGbJR6j6k2LCwqywWEb2od+zX06ptnL/DA9EJntY2xKPbxXbd2h2el6imD6sJFXrAY A7Wlk+LPm1iwd9CVkwY19q1aygKa3JWfkj3LStSQcqNO3LdKVex2HiLnKQxwQAqEua08txYnT ZzWp0htidH27Gwv6gKjcO8cFGLMLxxkf8up7CF+jTGENHI1VAUW4hi9Oqb0yl2QAMhcP1CuLl kZTtMjnVjqWKfzpUtx+/wvY0PyHoEgZA9XS52wX4iWoHwHaYWxmd8iW43OVp/fiAh91vPFSD0 h0T0kB2B07e0ukl4j0G0ajk7zsPepY65keCX2OSsX3HNN2bRw3y+e2789qMiiev2ssADkapOU yOeutZPRxk6ezuzeggkysc5nPxd6+oC1DxroODWRvF/VoThL0rzIH8h7UQhXb2IO0e3Pyii0D FWYgp3POl9tNYlHHytaHVc7KGYkQn13T2JiLXBYSoV9Gs5nOX0K+uoczgi7ZtmvMRIPZC6jKD Swc+G4r+7L2GvpMKm3OAQ8Yig2XycpTXMdWJFalaD9sQLm3yvI4hAkxr3ToMged0tWp0d5PNQ 39LVkFrTFE+1Ch0g99FrnvltIR19fQTocnJfjGNlU4HXzVCuTA5p11JDXQpT37/SBNIfEZo4D oFUSV61xBSx0R4slYAGX/PHcYk767l+xMrkd5sLyI2qJBgq2S451YEVKknj7UDIpx7GP33EuP FnN1fNuewEmc0uXY6P3uXyR2y3/aE+G4O30bAQ== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The function is called from __meminit context and calls other __meminit functions but isn't it self mark as such today: WARNING: vmlinux.o(.text.unlikely+0x4516): Section mismatch in reference from the function init_reserved_page() to the function .meminit.text:early_pfn_to_nid() The function init_reserved_page() references the function __meminit early_pfn_to_nid(). This is often because init_reserved_page lacks a __meminit annotation or the annotation of early_pfn_to_nid is wrong. On most compilers, we don't notice this because the function gets inlined all the time. Adding __meminit here fixes the harmless warning for the old versions and is generally the correct annotation. Fixes: 7e18adb4f80b ("mm: meminit: initialise remaining struct pages in parallel with kswapd") Signed-off-by: Arnd Bergmann --- mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index a123dee01872..ff45b8ebace3 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -1190,7 +1190,7 @@ static void __meminit __init_single_pfn(unsigned long pfn, unsigned long zone, } #ifdef CONFIG_DEFERRED_STRUCT_PAGE_INIT -static void init_reserved_page(unsigned long pfn) +static void __meminit init_reserved_page(unsigned long pfn) { pg_data_t *pgdat; int nid, zid; -- 2.9.0