Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp9097986imu; Tue, 4 Dec 2018 21:40:02 -0800 (PST) X-Google-Smtp-Source: AFSGD/UaVZq3h21aJ9uxeX89KhVGnB19nTo/8hxzbHnq3xnLypAdv1SJhIVUArKmiaCo9KtLO/Tm X-Received: by 2002:a62:4e49:: with SMTP id c70mr22782175pfb.167.1543988402780; Tue, 04 Dec 2018 21:40:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543988402; cv=none; d=google.com; s=arc-20160816; b=qGNnz1R/FeF6DcAkNNS9OJr7mGZZjQJvFWlJRpLL4cnGeomsSJ0O0tGQJVz7j6o0jz mgnLvf70YuOd5qML8lPLMwg49C6wS0GP6S8xqcxV/elfJGt5ZEBF8QsR73RJiUxlPwKJ weyQMYjuCmaKVuE2eySfVPN0owoWURijH0kUELYoDXuHu8rqft0NEpJ4qTaTyuwkhmQX 3asRsNFICUk1N4vdwRJleIABa3l0Ww5JJOjRBaDpwcpnvUpsX/12FfBoJ1/5twgNaT2V 2qsepSdWRkuS0MTwNDcnMQJnp4pkUEZt+C2BpH0FAzK0NnTiqfszKzD47zHPHZVit9sV gPOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:content-language:accept-language:in-reply-to:references :message-id:date:thread-index:thread-topic:subject:cc:to:from :dkim-signature; bh=49nlbjB/HVN4CbcTzKVYo25woRCnMJ1RH/9OpnFtFkc=; b=umhbXqnCwSKDZrMyMRBUzPMqcrvPBBfWf6TFLts47DrUSHNHDcFBnXpX38wkCr0WX2 bod48RevBdVipbrDRyFxqbWfiDk4L2FCfc9S2JLp3iTv/mDnT4o5XrUl79wh+L9XIojE Sitn8nZv1ppUajsXblugzNDqYpUkXihfE4HVRBpzD37F/lJ3NImqdNeOWtV7mHxerz2H bDiFvdZ2WD6TFtNxPaNimFnOX3oSYWkm/B6nLsdQxVDaPqaXs3MLK2d34m53V/7VLTov gjzCbAi+04hdjfM5h4eFi3WQ5B4+41Uz/uZND7L+md7CSLbpiUv5VnpR8lK/kEQlbJ4U n9kA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@live.com header.s=selector1 header.b=moUa7ufk; 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=NONE sp=QUARANTINE dis=NONE) header.from=live.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a195si21668245pfd.143.2018.12.04.21.39.47; Tue, 04 Dec 2018 21:40:02 -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=@live.com header.s=selector1 header.b=moUa7ufk; 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=NONE sp=QUARANTINE dis=NONE) header.from=live.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727104AbeLEFhj (ORCPT + 99 others); Wed, 5 Dec 2018 00:37:39 -0500 Received: from mail-oln040092001075.outbound.protection.outlook.com ([40.92.1.75]:59227 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726037AbeLEFhj (ORCPT ); Wed, 5 Dec 2018 00:37:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=live.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=49nlbjB/HVN4CbcTzKVYo25woRCnMJ1RH/9OpnFtFkc=; b=moUa7ufkXRzI6GoQWum+KjY+nwVPKHWbussPclT05MTa1ZQEs9tM3lHt/7GBwIcQh8/mkVpybTUyTSj8Y+rgKKEXshLrWvXdqtoi/B82x2Hd/6LxXdW2lTnL9D9KjojkdFWz4qSez8aAhJNNCn93LAnGw4q88G7gp+JVjsMfs4VkJRw0gzS1i/uzslRArmBpslsTV1+EmTgPTDywCF0+wk1dYMQSDzQbMMQ+dYtUN11mXic3YqO/r4lvg6jayPOVuHQeF3KuD/4zRrjHcEWviF2Bo2xGnUV6D8CnUxnC+Emo5LnL4sfoqEfJR7EhmEJB77lM2pGo+T3LNnjRMu0x5w== Received: from BY2NAM01FT023.eop-nam01.prod.protection.outlook.com (10.152.68.57) by BY2NAM01HT032.eop-nam01.prod.protection.outlook.com (10.152.68.250) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1404.13; Wed, 5 Dec 2018 05:37:37 +0000 Received: from BLUPR13MB0289.namprd13.prod.outlook.com (10.152.68.55) by BY2NAM01FT023.mail.protection.outlook.com (10.152.69.191) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1404.13 via Frontend Transport; Wed, 5 Dec 2018 05:37:37 +0000 Received: from BLUPR13MB0289.namprd13.prod.outlook.com ([fe80::19ff:b7ea:dfaa:2ee3]) by BLUPR13MB0289.namprd13.prod.outlook.com ([fe80::19ff:b7ea:dfaa:2ee3%2]) with mapi id 15.20.1404.019; Wed, 5 Dec 2018 05:37:37 +0000 From: Yueyi Li To: Wei Yang CC: "akpm@linux-foundation.org" , "mhocko@suse.com" , "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v2] memblock: Anonotate memblock_is_reserved() with __init_memblock. Thread-Topic: [PATCH v2] memblock: Anonotate memblock_is_reserved() with __init_memblock. Thread-Index: AQHUiryuEY3GC2m5nk+tSrupm8LKDqVt5pqAgAG9JYA= Date: Wed, 5 Dec 2018 05:37:37 +0000 Message-ID: References: <20181204030415.zpcvbzh5gxz5hxc6@master> In-Reply-To: <20181204030415.zpcvbzh5gxz5hxc6@master> Accept-Language: en-US, zh-CN Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: HK0PR01CA0040.apcprd01.prod.exchangelabs.com (2603:1096:203:3e::28) To BLUPR13MB0289.namprd13.prod.outlook.com (2a01:111:e400:5951::22) x-incomingtopheadermarker: OriginalChecksum:B6EF4B677E25A9F0A1F6D6FE54D739BC0C73BC7D3A6864055C4F474FF0A3D000;UpperCasedChecksum:6642BB504BB443A7FB082DC89C5A307DAEE6F09306C58FCEAD0ADF4485CCD582;SizeAsReceived:7738;Count:50 x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [CeEi051hXt7cDS7P9xY52aTnRgD6aoho] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BY2NAM01HT032;6:a/L9r4bc5zfDE7hSL+rhBfkb3uLK7p9xa7kiTBOb44B7esFxhg2ZTMnNC9gtYVeVOGKtW6EK8Wt33xJ/uH7K5BmTod3eIfklBDZhUK5NIJIYRVVmrUf83MpEZAqXFbA4AfkrVLL3iHEuz3HQacOpeUfhi8RYEv8knUFzoCP+AelEqJ08W9BazlmvWIjMGCevTALqbeSbkiwVc/WTnjXcCGWkUeCk3/THKZAeLX+YwiGJUITE0kmItAwJ8Bt4hAWjwvmQqdGqCLads1rDGgNQWD1oZL4ZIEBVyRNts2+upEMJGce7XR1hf0YdEje6RCLCwGXFRtfDZiXG9ETEPLAyAevRrDKtI+FdQ2qftpCKBVllAIU3okyZcXX6+wIopQezaK+hoQkOHgv9NLk5lqSDNA7f1O521npITPksiWPhZyF4H8lrk7AOIgrpikAJ9O0XGDM9UIT0R2H/FxxIMYjVpA==;5:n9qpyfWtUAiZO/AgjkWPx5r3QHSzQtVMGiKCdCBHm7ILkIdFvtiCbk21P/j++P/egGUlBFeaNn7SW2auZWafbg4ttrmyqGGJKhKfysoXIIx41asrGR7NFXkCO5R6UzGCgvBen9twZFWIwdLTXi+yxxJhGpFj3OBAsS8VVcYTOgM=;7:u/4QJjB8CUcQ7LpUAKjqyufiBPYt1y6OgeKx3Ubnkd/uRsCVxVXt71YnSORrySMe7S9mnQkGDSEU8+gjsQJP+Fy0FdfJQA+dPKAoijmh2tCgcBMmYyARyKmaAwLIe5AQq/llldzMbZvICA4G3/U70g== x-incomingheadercount: 50 x-eopattributedmessage: 0 x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390098)(7020095)(201702061078)(5061506573)(5061507331)(1603103135)(2017031320274)(2017031324274)(2017031323274)(2017031322404)(1603101475)(1601125500)(1701031045);SRVR:BY2NAM01HT032; x-ms-traffictypediagnostic: BY2NAM01HT032: x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(4566010)(82015058);SRVR:BY2NAM01HT032;BCL:0;PCL:0;RULEID:;SRVR:BY2NAM01HT032; x-microsoft-antispam-message-info: b9JYAZlNy651bcZj8I9cRWpYG4VT9JcaXIsNZv9XFGAILJ9VRCwyiICd+uKpsEYI Content-Type: text/plain; charset="Windows-1252" Content-ID: <3F6DD7343CFD8C43BA08FE6D04863379@namprd13.prod.outlook.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: live.com X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: f12efbb0-867f-4c93-8261-502eceebfafa X-MS-Exchange-CrossTenant-Network-Message-Id: 3ce09e1e-5e28-468e-3c58-08d65a73c32f X-MS-Exchange-CrossTenant-rms-persistedconsumerorg: f12efbb0-867f-4c93-8261-502eceebfafa X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Dec 2018 05:37:37.2520 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY2NAM01HT032 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018/12/4 11:04, Wei Yang wrote: > On Mon, Dec 03, 2018 at 04:00:08AM +0000, Yueyi Li wrote: >> Found warning: >> >> WARNING: EXPORT symbol "gsi_write_channel_scratch" [vmlinux] version gen= eration failed, symbol will not be versioned. >> WARNING: vmlinux.o(.text+0x1e0a0): Section mismatch in reference from th= e function valid_phys_addr_range() to the function .init.text:memblock_is_r= eserved() >> The function valid_phys_addr_range() references >> the function __init memblock_is_reserved(). >> This is often because valid_phys_addr_range lacks a __init >> annotation or the annotation of memblock_is_reserved is wrong. >> >> Use __init_memblock instead of __init. > Not familiar with this error, the change looks good to me while have > some questions. > > 1. I don't see valid_phys_addr_range() reference memblock_is_reserved(). > This is in which file or arch? Yes, I modified valid_phys_addr_range() for some other debugging. > 2. In case a function reference memblock_is_reserved(), should it has > the annotation of __init_memblock too? Or just __init is ok? If my > understanding is correct, annotation __init is ok. Well, I don't see > valid_phys_addr_range() has an annotation. > 3. The only valid_phys_addr_range() reference some memblock function is > the one in arch/arm64/mm/mmap.c. Do we suppose to add an annotation t= o > this? Actually, __init_memblock is null in arch arm64, this warning is due to CONFIG_DEBUG_SECTION_MISMATCH enabled, the help text in lib/Kconfig.debug. Thanks, Yueyi