From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756110AbcHBFfb (ORCPT ); Tue, 2 Aug 2016 01:35:31 -0400 Received: from sender153-mail.zoho.com ([74.201.84.153]:21463 "EHLO sender153-mail.zoho.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751350AbcHBFf3 (ORCPT ); Tue, 2 Aug 2016 01:35:29 -0400 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=subject:to:references:cc:from:message-id:date:user-agent:mime-version:in-reply-to:content-type; b=TuVd5k7bGl0K+ApI4Wh+lj5IiCuQyzgDJSRPHGA8Y8CsZBG455kMAT1gu0e26FZEPRhtMlLaLVcd yhHqIQevPvwzaYXMA+mfE9GRlsC9gir/dQ5AwVJBXOL+vZwPnRre Subject: Re: [PATCH] mm/memblock.c: fix NULL dereference error To: kbuild test robot References: <201608021315.YmAh1zzr%fengguang.wu@intel.com> Cc: kbuild-all@01.org, akpm@linux-foundation.org, ard.biesheuvel@linaro.org, david@gibson.dropbear.id.au, dev@g0hl1n.net, kuleshovmail@gmail.com, tangchen@cn.fujitsu.com, tj@kernel.org, weiyang@linux.vnet.ibm.com, mm-commits@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, torvalds@linux-foundation.org From: zijun_hu Message-ID: <57A03083.7010003@zoho.com> Date: Tue, 2 Aug 2016 13:32:51 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <201608021315.YmAh1zzr%fengguang.wu@intel.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org i am sorry, the second patch is only a test patch, please don't apply it i will send another mail for correct this On 08/02/2016 01:23 PM, kbuild test robot wrote: > Hi zijun_hu, > > [auto build test WARNING on mmotm/master] > [also build test WARNING on v4.7 next-20160801] > [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] > > url: https://github.com/0day-ci/linux/commits/zijun_hu/mm-memblock-c-fix-NULL-dereference-error/20160802-130708 > base: git://git.cmpxchg.org/linux-mmotm.git master > config: i386-randconfig-x009-201631 (attached as .config) > compiler: gcc-6 (Debian 6.1.1-9) 6.1.1 20160705 > reproduce: > # save the attached .config to linux build tree > make ARCH=i386 > > All warnings (new ones prefixed by >>): > > In file included from include/linux/kernel.h:13:0, > from mm/memblock.c:13: > mm/memblock.c: In function 'memblock_patch_verify': >>> mm/memblock.c:1713:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ >>> mm/memblock.c:1713:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > mm/memblock.c:1713:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 4 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ >>> mm/memblock.c:1713:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > mm/memblock.c:1719:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ > mm/memblock.c:1719:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > mm/memblock.c:1719:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 4 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ > mm/memblock.c:1719:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > mm/memblock.c:1726:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ > mm/memblock.c:1726:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > mm/memblock.c:1726:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 4 has type 'phys_addr_t {aka unsigned int}' [-Wformat=] > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^ > include/linux/printk.h:260:21: note: in definition of macro 'pr_fmt' > #define pr_fmt(fmt) fmt > ^~~ > mm/memblock.c:1726:3: note: in expansion of macro 'pr_info' > pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > ^~~~~~~ > > vim +1713 mm/memblock.c > > 1697 pr_info(" memory size = %#llx reserved size = %#llx\n", > 1698 (unsigned long long)memblock.memory.total_size, > 1699 (unsigned long long)memblock.reserved.total_size); > 1700 > 1701 memblock_dump(&memblock.memory, "memory"); > 1702 memblock_dump(&memblock.reserved, "reserved"); > 1703 } > 1704 > 1705 void __init_memblock memblock_patch_verify(void) > 1706 { > 1707 u64 i; > 1708 phys_addr_t this_start, this_end; > 1709 > 1710 pr_info("in %s: memory\n", __func__); > 1711 for_each_mem_range_rev(i, &memblock.memory, NULL, NUMA_NO_NODE, > 1712 MEMBLOCK_NONE, &this_start, &this_end, NULL) >> 1713 pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > 1714 i, this_start, this_end); > 1715 > 1716 pr_info("in %s: reserved\n", __func__); > 1717 for_each_mem_range_rev(i, &memblock.reserved, NULL, NUMA_NO_NODE, > 1718 MEMBLOCK_NONE, &this_start, &this_end, NULL) > 1719 pr_info("[%#016llx]\t[%#016llx-%#016llx]\n", > 1720 i, this_start, this_end); > 1721 > > --- > 0-DAY kernel test infrastructure Open Source Technology Center > https://lists.01.org/pipermail/kbuild-all Intel Corporation >