Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp5861609imd; Wed, 31 Oct 2018 03:17:39 -0700 (PDT) X-Google-Smtp-Source: AJdET5dqKRnMzKcDOuqDOVff5poQQ+v+a5Fw8vQeZUB/WG+LjlN8RmktEHJXixWOi52QQfsCE2ly X-Received: by 2002:a63:8742:: with SMTP id i63mr610623pge.298.1540981059231; Wed, 31 Oct 2018 03:17:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540981059; cv=none; d=google.com; s=arc-20160816; b=rB6zryKnXJ8Hn6MDzJihqTEibrt1yeOCBRjHlVOiz/LMYTDXXDarLOcnYiTpbiZksb aMA9c+RsXTjX7ovD/tCfISKKQhoNEjrDtpOzI9B2qYL6tS6lzGeCh4yHMfaLViASkNNG QHzmDhAKLdSU5mNbo7y2Ac50rpmQHeKfOb7Z4t3rcevFs1DhvW5/YhraBNV9Lm6C+nOB G2N6r/JTvFvhHPlxquOarQb1RLbLyaH8v+SwY3gg9bM+b/XPGSWh5/EK9sVRJJe/k/ZK wmsLj3Nd7FHWXN1FHGNcZqsX4WhZwvWySkW8A4G5l9mUJJ20pkL33YNUYlGBURn/DSLB MQJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=o3VdnwRmG+w5DGF0pK/3abPJlSaEMhwjDqGpoNPIrIc=; b=ibRL9OQJm11F6aAarI+irxhFiOX9h6xP30Mr54t6VQOOU+xfReM0E9vkxjD+0doKY1 iDGVssR8qIBMbxk9k5syvrfkrtMPADQY4IVmTOOtYNPjgnwgC2ikUykMF9oLBhqM1fQx 4e1MgL2Cipd55KeIqFXBCunynBsiS+UD8LHHwtz/NjHjMXsPoIQvsMmahjVWI5U1P12B GKPpYX49lkE4fSwqCxpOHlOh/G/Fw2O5KsccHpOQ72g7AKfMXT9NIXs3G/rsc5SuatW/ PFF16bRo1B9w2RSgrPZfRlTQepF3rzntshkaw1OlJDrCYKk+fJ21qIBnr+PCwUNusX5H QWFw== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w17-v6si18430774pgk.497.2018.10.31.03.17.23; Wed, 31 Oct 2018 03:17:39 -0700 (PDT) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728559AbeJaTMd (ORCPT + 99 others); Wed, 31 Oct 2018 15:12:33 -0400 Received: from mx2.suse.de ([195.135.220.15]:50700 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727865AbeJaTMd (ORCPT ); Wed, 31 Oct 2018 15:12:33 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 5F308AE3E; Wed, 31 Oct 2018 10:15:03 +0000 (UTC) Date: Wed, 31 Oct 2018 11:15:01 +0100 From: Michal Hocko To: Miles Chen Cc: Andrew Morton , Joe Perches , Matthew Wilcox , linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wsd_upstream@mediatek.com Subject: Re: [PATCH v3] mm/page_owner: use kvmalloc instead of kmalloc Message-ID: <20181031101501.GL32673@dhcp22.suse.cz> References: <1540790176-32339-1-git-send-email-miles.chen@mediatek.com> <20181029080708.GA32673@dhcp22.suse.cz> <20181029081706.GC32673@dhcp22.suse.cz> <1540862950.12374.40.camel@mtkswgap22> <20181030060601.GR32673@dhcp22.suse.cz> <1540882551.23278.12.camel@mtkswgap22> <20181030081537.GV32673@dhcp22.suse.cz> <1540975637.10275.10.camel@mtkswgap22> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1540975637.10275.10.camel@mtkswgap22> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 31-10-18 16:47:17, Miles Chen wrote: > On Tue, 2018-10-30 at 09:15 +0100, Michal Hocko wrote: > > On Tue 30-10-18 14:55:51, Miles Chen wrote: > > [...] > > > It's a real problem when using page_owner. > > > I found this issue recently: I'm not able to read page_owner information > > > during a overnight test. (error: read failed: Out of memory). I replace > > > kmalloc() with vmalloc() and it worked well. > > > > Is this with trimming the allocation to a single page and doing shorter > > than requested reads? > > > I printed out the allocate count on my device the request count is <= > 4096. So I tested this scenario by trimming the count to from 4096 to > 1024 bytes and it works fine. > > count = count > 1024? 1024: count; > > It tested it on both 32bit and 64bit kernel. Are you saying that you see OOMs for 4k size? -- Michal Hocko SUSE Labs