Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp953263rdb; Fri, 2 Feb 2024 08:52:52 -0800 (PST) X-Google-Smtp-Source: AGHT+IFQLYyBO3r3q0RXvlRlkWKWPViXyFIVx4/yd9vxiwZ3GlKi2GIM+yvELAroiU+iZkG3QoPk X-Received: by 2002:a05:6808:2e92:b0:3bd:5f35:58f6 with SMTP id gt18-20020a0568082e9200b003bd5f3558f6mr4007086oib.37.1706892772100; Fri, 02 Feb 2024 08:52:52 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706892772; cv=pass; d=google.com; s=arc-20160816; b=eapegF5sB4pG9CG4w8RF7XKQAuLWaSyfhbLzxYSDTZuI4bSbfdwtIBVpErS+uB2XQA 8DmTBOO5iUEv1rdxS5gctfDDEreGj2eS6hzLu9sAN+nfdYkzaNXCcvFZvY7Y9KJGDsTi SoKDzwq+mcL3/1sHYa3M19HXIkgIfyQc9EGAWjKIGGjySG+u88Es6EvEBU+0RSeRzDGU /qLu4TE1IPVzEusdVcYULWIAcUr7eIk7tFH1a0MC8Kgg7UylXyTseyO9DK9ripahBtCZ 9bEnJyNNKIB/rMHDenVRFE3qMBsQDYBOf/iBstVEs1gjBHWQKndmyV9WYPVdd1ZVfsRA nowA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:message-id:organization:from :content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:references:subject:cc:to :dkim-signature; bh=PN2mkpSyX7nEj7fh49nBse8d9uJ2MD5kPuk4t8PdKk8=; fh=YSYPqgimUuGevvlkf3ieEo7eU/dxsLXva3eUn8FdTOg=; b=C0FWF8z1xF3prQJns5tK39z0tHuFEmFKFF1G18lyUTgLuQBjjOyuzVpWy/DuAMSn3x 4vNGIMB0TcMfL6veQ2vJ9bo28UIEHn44FflnqyM5F6BFaw1ckzrRSIQNBHxgPiwICwg9 C7bczeJOhYqKSxN+o24bJ5ajPDoxkXTwoDedDW02rYIZbx0mTRNCrrY7ihBs2yK+gTwC 7Mg57dv+FgAJDIBINn7VuEMoxjYa/sv2RLSYXDTfVnndMTubN2GujZfUcOfbXWEeoaPR uJB8l0zH7yAopFuDdkctgPdwdYRgyEv4x9Yc/EcGBNIo6rVP6rkxYX93mw7DGWZNy99x rChQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=LQCciCfU; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-50180-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50180-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com X-Forwarded-Encrypted: i=1; AJvYcCWAphL2zO/8hTT7sLEiwp4tsTTWjC4nZucZVnW8qhbB5ckJVf2sDUHzNVffv1PzE9ADNUpvYyJ3s/hl6upcH6uvbXbwVRQeqQPDpNosBA== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id c26-20020a05620a165a00b007854f7e6c1csi2281466qko.405.2024.02.02.08.52.51 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Feb 2024 08:52:52 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-50180-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=LQCciCfU; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-50180-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50180-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6727A1C27549 for ; Fri, 2 Feb 2024 16:52:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 477451487C1; Fri, 2 Feb 2024 16:52:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="LQCciCfU" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.19]) (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 C969814A4EC; Fri, 2 Feb 2024 16:52:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.19 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706892746; cv=none; b=o/NaY5058QPilt+ofBL4I7E2wEu96fKwMhjtldgiQEpm7xWDMm++EjZ4rGkFL8a0UJJna9JHPxahaB8g7CsR+SVjKuVnyQ7bI1gtH1IX5MvqN8mMVItTEh6tZHeT7PVg5tOlqvQWlvbgIAj/it1zyAy0fOsoiGGalOFIatl17ME= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706892746; c=relaxed/simple; bh=HzgDzI/Ge9eFvWVgikaxYZfFSROrOdcCMT23siR2Q6o=; h=Content-Type:To:Cc:Subject:References:Date:MIME-Version:From: Message-ID:In-Reply-To; b=qiYSeYdsG7NMeAWcp7YGSFJtBdqDc+r4/NaLh4U3A+CAyzp9BQ4tdLIjEvdnmecbUss25/n6DYH+ZAJzD/HlA9dbXo5Uc3iePCfPH+c5dbKtld4K3vD7Rhpt388FY3j6Hw3jxGbP4dHkzf2Rbh1GLLthd6a3RfCCYDAN+dYabPY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=LQCciCfU; arc=none smtp.client-ip=192.198.163.19 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1706892741; x=1738428741; h=to:cc:subject:references:date:mime-version: content-transfer-encoding:from:message-id:in-reply-to; bh=HzgDzI/Ge9eFvWVgikaxYZfFSROrOdcCMT23siR2Q6o=; b=LQCciCfUe7id/mI1xZw4oEdn51ZVVKlNNI29SfutAVYE83VXu+DI8eEb +e9gHAiZpOcssBeugERBY9KqzSKhnwm9sM2o5JewkhR9Vz/2tpvepMN5L WH9GF9Lrv+bmkFVZmNz0n6KUgKSYpUSftW2rmdRLPwr2uEKi4xn9Gk7nY TUGukvG6CbRiQY3bb6UJBErXn+gZV4QdkP7HoZJ4MHmu9W2AOdflmhEcC YynHR0pyrX59sce/RQjnTNrhfFHYo7hrRInKVBeB8ehsoNy9AfNMmdQeH CegEs7jQLjQmaftmGtnjhyppqjwAjlnBVsrgezmynSGJwVZIel/zV6kFJ w==; X-IronPort-AV: E=McAfee;i="6600,9927,10971"; a="102604" X-IronPort-AV: E=Sophos;i="6.05,238,1701158400"; d="scan'208";a="102604" Received: from orviesa007.jf.intel.com ([10.64.159.147]) by fmvoesa113.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Feb 2024 08:52:17 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.05,238,1701158400"; d="scan'208";a="435399" Received: from hhuan26-mobl.amr.corp.intel.com ([10.92.17.168]) by orviesa007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 02 Feb 2024 08:52:15 -0800 Content-Type: text/plain; charset=iso-8859-15; format=flowed; delsp=yes To: dave.hansen@linux.intel.com, tj@kernel.org, mkoutny@suse.com, linux-kernel@vger.kernel.org, linux-sgx@vger.kernel.org, x86@kernel.org, cgroups@vger.kernel.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, sohil.mehta@intel.com, "Jarkko Sakkinen" Cc: zhiquan1.li@intel.com, kristen@linux.intel.com, seanjc@google.com, zhanb@microsoft.com, anakrish@microsoft.com, mikko.ylinen@linux.intel.com, yangjie@microsoft.com, chrisyan@microsoft.com Subject: Re: [PATCH v8 05/15] x86/sgx: Add sgx_epc_lru_list to encapsulate LRU list References: <20240130020938.10025-1-haitao.huang@linux.intel.com> <20240130020938.10025-6-haitao.huang@linux.intel.com> Date: Fri, 02 Feb 2024 10:52:12 -0600 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Haitao Huang" Organization: Intel Message-ID: In-Reply-To: User-Agent: Opera Mail/1.0 (Win32) On Thu, 01 Feb 2024 17:28:32 -0600, Jarkko Sakkinen wrote: > On Tue Jan 30, 2024 at 4:09 AM EET, Haitao Huang wrote: >> From: Sean Christopherson >> >> Introduce a data structure to wrap the existing reclaimable list and its >> spinlock. Each cgroup later will have one instance of this structure to >> track EPC pages allocated for processes associated with the same cgroup. >> Just like the global SGX reclaimer (ksgxd), an EPC cgroup reclaims pages >> from the reclaimable list in this structure when its usage reaches near >> its limit. >> >> Use this structure to encapsulate the LRU list and its lock used by the >> global reclaimer. >> >> Signed-off-by: Sean Christopherson >> Co-developed-by: Kristen Carlson Accardi >> Signed-off-by: Kristen Carlson Accardi >> Co-developed-by: Haitao Huang >> Signed-off-by: Haitao Huang > > I'd put author as last sob but that said I'm not sure if there is rigid > rule to do so. Thus not saying must here. > The documentation says "the ordering of Signed-off-by: tags should reflect the chronological history of the patch insofar as possible, regardless of whether the author is attributed via From: or Co-developed-by:. Notably, the last Signed-off-by: must always be that of the developer submitting the patch." So this should be OK. [...] >> struct sgx_epc_page *__sgx_alloc_epc_page(void); >> void sgx_free_epc_page(struct sgx_epc_page *page); >> > > Reviewed-by: Jarkko Sakkinen > > BR, Jarkko > Thank you! Haitao