From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-189.mta0.migadu.com (out-189.mta0.migadu.com [91.218.175.189]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 630C4278E7E for ; Thu, 14 Aug 2025 21:54:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.189 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755208463; cv=none; b=hc+D17XIi5QVhiQIGOvhp5tI7PA6mxDgdsvjLi7n5mAbsbnH1lbqt7HQXSda8jvvjY7MPUn9zCRiU2WShgyi11YzmFCcVZW8V5d/4MdxqMBABCZRYVunEpK5ePDEa58EY4MIYCB2nNAefH/5/fABaf+dmeaQstskH3MXEsVBxnI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755208463; c=relaxed/simple; bh=jtBi1e2mFHClEMU/nu+7X9bWJD/2lPJLlCa8SB3evZs=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=mSPBmfCVur9ColpGihzTHPEEU9AMQfaLHL+DRY/XeUTw0aQlsaiPObMuDn+RqeN/+qpZFFmWRSoMfu98r2rSIfRjvHB/JftP9hFVgkODLc/lXDkVNTKLm+roIFLQZeB3kWWYnc1SH6onoAK4ghUNJaSz9Yyhu2V8uOblOSKf8+I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=tjboaIui; arc=none smtp.client-ip=91.218.175.189 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="tjboaIui" Date: Thu, 14 Aug 2025 14:54:12 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1755208459; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=QHB/j+0DmL1EK+U0zklBCFzZzy1Aw8M5r+L+sDIIjzY=; b=tjboaIuiEmzkhcEjR5G3H5Z/cwClH0mr9Dgfa7CWAmuxbKfIiKTN1J4Hc8Yff2omMUoeMG bNMb2Cx8niSImfrgsMZEB+M8gjmhPsZjcnw9ARMo4kCXKOV5XUbFscNJCFqpTV7h5oBMdF JFM36ZRMOlgbmYLSssVesCI9Ob3Zf/c= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Shakeel Butt To: Kuniyuki Iwashima Cc: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Neal Cardwell , Paolo Abeni , Willem de Bruijn , Matthieu Baerts , Mat Martineau , Johannes Weiner , Michal Hocko , Roman Gushchin , Andrew Morton , Michal =?utf-8?Q?Koutn=C3=BD?= , Tejun Heo , Simon Horman , Geliang Tang , Muchun Song , Mina Almasry , Kuniyuki Iwashima , netdev@vger.kernel.org, mptcp@lists.linux.dev, cgroups@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH v4 net-next 08/10] net-memcg: Pass struct sock to mem_cgroup_sk_(un)?charge(). Message-ID: References: <20250814200912.1040628-1-kuniyu@google.com> <20250814200912.1040628-9-kuniyu@google.com> Precedence: bulk X-Mailing-List: cgroups@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20250814200912.1040628-9-kuniyu@google.com> X-Migadu-Flow: FLOW_OUT On Thu, Aug 14, 2025 at 08:08:40PM +0000, Kuniyuki Iwashima wrote: > We will store a flag in the lowest bit of sk->sk_memcg. > > Then, we cannot pass the raw pointer to mem_cgroup_charge_skmem() > and mem_cgroup_uncharge_skmem(). > > Let's pass struct sock to the functions. > > While at it, they are renamed to match other functions starting > with mem_cgroup_sk_. > > Signed-off-by: Kuniyuki Iwashima > Reviewed-by: Eric Dumazet > Acked-by: Roman Gushchin Acked-by: Shakeel Butt