Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp844512ybj; Tue, 5 May 2020 08:25:17 -0700 (PDT) X-Google-Smtp-Source: APiQypKzMCgidkYCQs2eT9Q5ktFXwr2Eg4GyrBHXqTyv2mVnMzNIXSEdEWIJ/H4+xBVnrMjJ2kLG X-Received: by 2002:aa7:c714:: with SMTP id i20mr3096518edq.230.1588692317091; Tue, 05 May 2020 08:25:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588692317; cv=none; d=google.com; s=arc-20160816; b=qMe0TpLBxI0OP967oSQRhksqXMvWTwL1+wCBDqjdyW3m9T+ZKyQ9Z5/EVMQonUpPQ2 0XKxob8Y3ZeKZIfXNOy8pPbRscRESZBflFvLGI4vjd02YrkRUSKmoYLgGS8azwnwK9Pp EFVXY0Nd5bAnrcQ4Z2YDK2UZ+PwcO7Vh0VCKpW2KR+Kfk0y+KJcLQQFpfwVAtT3pMuAQ f5990zzehz0SNnzSteyV+92diW55/ZgVYPvGi4VdWWmdV90fIUGsCmZSfQ6PngYmHV9M j0iW0xjgHyFH17Jira94Uw4v7cLfz73JJQpzoJTEznsXh2ct5FZVRdZU8WkPqf3Wemxc FdzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=ijPZh8B4iDN+Zy3Lbn8azz7wIkX6gQvepkatyf1Zg2U=; b=NGaN3QrbgcE0Y1gu8xklq9dOerl4mPJ5amOxZfZqrZPtIZQv/+leDdsvn6hl5p07PJ /I9NEma/Wc0Af8azeBPXgATIajJgcrj1sUBduG2Z8QvSnSGPMnfMvUU7cNi8QVcmIOvF 6CC7rAQpGUVQgwc8raK5PP386YubT3TQc6LnAokJ40is1CQMf6p0Uw+gv1E+QvRjVchx 3dkgZFq9A68Dpl/Qi5/JbHUFEoX535Zvg5tfP5iSc9HIVNWtRgZjFldIC9uvRrStggHI BqH8w9ffU3WZyEETHmhtRUPbdzEoxiJfTxoJviL86IgbwWV+99+U54sEcocryRntkt9u mIFA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=b+4dZwe2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e23si1402129edr.298.2020.05.05.08.24.47; Tue, 05 May 2020 08:25:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=b+4dZwe2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730047AbgEEPUz (ORCPT + 99 others); Tue, 5 May 2020 11:20:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59332 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1729709AbgEEPUz (ORCPT ); Tue, 5 May 2020 11:20:55 -0400 Received: from mail-pj1-x1044.google.com (mail-pj1-x1044.google.com [IPv6:2607:f8b0:4864:20::1044]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D841FC061A0F; Tue, 5 May 2020 08:20:53 -0700 (PDT) Received: by mail-pj1-x1044.google.com with SMTP id mq3so1296245pjb.1; Tue, 05 May 2020 08:20:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ijPZh8B4iDN+Zy3Lbn8azz7wIkX6gQvepkatyf1Zg2U=; b=b+4dZwe21myBqVCmmpmf7s/5B4GYvFeMaXPncR16D1Lwjgt/CG4navWP1THhFFdxVC FrgwbB7pTbqozj2ncAaWSkhSgi0Ug8t/9UuE24ydi5dzzEDqROPx2pkGFpbnTiAi5pvX ylLJOy/L4/wUd0Mk1LIjMvaqPbHjr6SC9XAgcoDmfxp1pbcqFkoOZ6LHtXAhkQNzDvEA 5UNQYdWphLOVit2+RO+P4RMMPzPtJ5gZuMwz1r4VlF47oB2L9mV44+gloqHUqpFKikla hNOHDE0O2jTGV/X6tFT7i/e8nwvC1HS9HrBK2zoBw7Uw4NKSKpuwIXgjilVj1V58SHVP Upcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ijPZh8B4iDN+Zy3Lbn8azz7wIkX6gQvepkatyf1Zg2U=; b=sClHn0bjOd9q4gsuIOcRd+9RMFp/r9TNeilOBcFrqNlyKccJ5Q7AWuNhkW4fSyWLac zBKCVAU7zp4xu7j7PfohWljFBOYHh4Kps1zVajxYHjt2jIBkYveG14SCvwHldKJSY/Qt 2DmPPBbWpoaRJ4cDQBGCxLiy3gQDtydJRlbfLf0IHEvECyRoXsh+BHKx53TOCAsKp/1I 2/54c+fX0nDANl5FGh2UJ+cxuxewQA+t57J4uWuOJKNpOoETrKCguCQHwYHZ4MhxBEgu B6/zm99RACqVp+g+/NrG2ibByz6YZiVXGU32TRHF6TnlGkAtWf13hNhw5EI9kwZ1kn4Z ocmQ== X-Gm-Message-State: AGi0Pubjz16f39ZrutkH+Dr5H87GQI5SYtfboIupRzHVeYIU5j4XZvRh 1UnBCxPSDxFIucJqSsPB26HZisEm X-Received: by 2002:a17:90b:f11:: with SMTP id br17mr1361595pjb.222.1588692053003; Tue, 05 May 2020 08:20:53 -0700 (PDT) Received: from [192.168.86.235] (c-73-241-150-58.hsd1.ca.comcast.net. [73.241.150.58]) by smtp.gmail.com with ESMTPSA id 62sm2292222pfu.181.2020.05.05.08.20.50 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 05 May 2020 08:20:51 -0700 (PDT) Subject: Re: [PATCH net v2 0/2] Revert the 'socket_alloc' life cycle change To: SeongJae Park , Eric Dumazet Cc: David Miller , Al Viro , Jakub Kicinski , Greg Kroah-Hartman , sj38.park@gmail.com, netdev , LKML , SeongJae Park , snu@amazon.com, amit@kernel.org, stable@vger.kernel.org References: <20200505150717.5688-1-sjpark@amazon.com> From: Eric Dumazet Message-ID: Date: Tue, 5 May 2020 08:20:50 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: <20200505150717.5688-1-sjpark@amazon.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/5/20 8:07 AM, SeongJae Park wrote: > On Tue, 5 May 2020 07:53:39 -0700 Eric Dumazet wrote: > >> Why do we have 10,000,000 objects around ? Could this be because of >> some RCU problem ? > > Mainly because of a long RCU grace period, as you guess. I have no idea how > the grace period became so long in this case. > > As my test machine was a virtual machine instance, I guess RCU readers > preemption[1] like problem might affected this. > > [1] https://www.usenix.org/system/files/conference/atc17/atc17-prasad.pdf > >> >> Once Al patches reverted, do you have 10,000,000 sock_alloc around ? > > Yes, both the old kernel that prior to Al's patches and the recent kernel > reverting the Al's patches didn't reproduce the problem. > I repeat my question : Do you have 10,000,000 (smaller) objects kept in slab caches ? TCP sockets use the (very complex, error prone) SLAB_TYPESAFE_BY_RCU, but not the struct socket_wq object that was allocated in sock_alloc_inode() before Al patches. These objects should be visible in kmalloc-64 kmem cache.