Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp2760549rwb; Fri, 2 Dec 2022 14:48:36 -0800 (PST) X-Google-Smtp-Source: AA0mqf4rNUqND5zUMuJ56YRaC1OjxTG0c9V5EgqP+P56/dnegQRtF9B1Rnp/J84kfkmW1WIcG+HU X-Received: by 2002:aa7:9293:0:b0:56b:9bf4:c1c4 with SMTP id j19-20020aa79293000000b0056b9bf4c1c4mr65886126pfa.67.1670021315927; Fri, 02 Dec 2022 14:48:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670021315; cv=none; d=google.com; s=arc-20160816; b=h93lJxtay4B+iRC2UqmFxx66GhHLTxbF9Ck0lJ5fjIsoVii0kkyo6DHTGmUzOOqxo3 iJIvKbkgIBRMaIDt2XRHWahMqv7j/NlMyXJ3Z4Qtchh4d5GErzXzubYcMvvMZeI0N9d4 Ml7L83E8pPKiQKYiuvrmHT+VVqKwBAQB54K+EWX+5VQkKeLc3x4kHMzREsfy17BHtktm tDzZJBYBBfPIeXvkjLuq8r6zBCR1sVcUExiyFAhqdaoapua3f8uH6PBjSq3I0AMWH/Al CNR8SinBxyJJq03LI2jTV8cCsobJNPU0eZCNGz0wmmyGMH1RXXVSL2SWDR60N2fIE+q+ 58jQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=jUdXewApqtUtJDz8NJrGktCh8TFWvuPGP2SWRNjg8IE=; b=ndp4Ys12z7w7jkKV8QAOVpmjPMI+n4XDiUHPGXuW4oQF/2zCuHxOKwLmiYVdB9YYpb mKgzYKuR9CdoC+m1JWH8GBYPV2suXCCxjlNtqzlQDxtCjWe+vUIlHq8rNe0tL4zznZG4 O5iEVLu4TXRYYZ3ZLcwGtOXNIGtdFdVOge9UaqFAqKSWIikxxFNgfxrtJC8MEq3pCU8b PhhqsV2QSViQRdwn0B4v60clXKxywb8tZ0pzYrI/iU/Q8FVHpWqv0yrXl+VbVMeqxTJC QPinsw51PN1x4tH/z5Lu2gFiK+xc2I7z0+pc9VbDz88IH0Jn2kBdAaheCDU30mnergLH Q68A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=gMvbzBqD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e27-20020a630f1b000000b00477b10def88si8341517pgl.696.2022.12.02.14.48.25; Fri, 02 Dec 2022 14:48:35 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=gMvbzBqD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234266AbiLBWK2 (ORCPT + 82 others); Fri, 2 Dec 2022 17:10:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58338 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229527AbiLBWK0 (ORCPT ); Fri, 2 Dec 2022 17:10:26 -0500 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 65177EC83B; Fri, 2 Dec 2022 14:10:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1670019025; x=1701555025; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=kff4S1vyf+hWj1GXzPubNZckk1uQ/dFn8K1E9qFptjk=; b=gMvbzBqDLpKA5i7dJC5HoH5F16MU8pJNXCZDNhEAVrL+cb9y/ookBjcp lnmlJYY10vLIX332z1gctOlnVNGCIKruFWyQk5PmK+jSWDUWRcud2GVmf X1sgm23k4qb17CGnU0pWsSi7Kxe8rui5235qqnxCoSpLU7nzug+jAWSe0 2oaFVJ0niQSlQ8ZXV8uxSFhUjyAULFCFrV3WXYGB3AYBxZTBpCZpETrEY yYlNtDDxToA1bWMVYgFu7C/HhOzXf/WAe5eFRZa/E1kA+MMr2VVtxPn3E 8/jbDCwebvsUSy9SbbMr/JTlr4K8vqweoVgv9K8yqARU1gNZccWYqRqMg w==; X-IronPort-AV: E=McAfee;i="6500,9779,10549"; a="317913157" X-IronPort-AV: E=Sophos;i="5.96,213,1665471600"; d="scan'208";a="317913157" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Dec 2022 14:10:23 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10549"; a="622850146" X-IronPort-AV: E=Sophos;i="5.96,213,1665471600"; d="scan'208";a="622850146" Received: from rsnyder-mobl.amr.corp.intel.com (HELO [10.209.68.71]) ([10.209.68.71]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Dec 2022 14:10:17 -0800 Message-ID: Date: Fri, 2 Dec 2022 14:10:16 -0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2 Subject: Re: [PATCH v2 04/18] x86/sgx: Use sgx_epc_lru_lists for existing active page list Content-Language: en-US To: Kristen Carlson Accardi , jarkko@kernel.org, dave.hansen@linux.intel.com, tj@kernel.org, linux-kernel@vger.kernel.org, linux-sgx@vger.kernel.org, cgroups@vger.kernel.org, Thomas Gleixner , Ingo Molnar , Borislav Petkov , x86@kernel.org, "H. Peter Anvin" Cc: zhiquan1.li@intel.com, Sean Christopherson References: <20221202183655.3767674-1-kristen@linux.intel.com> <20221202183655.3767674-5-kristen@linux.intel.com> From: Dave Hansen In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 12/2/22 13:51, Kristen Carlson Accardi wrote: > I know - and originally the addition of unreclaimable was added later, > but when I posted the RFC I felt there was some misunderstanding about > what this data structure was and how it would be used because the > addition of the unreclaimable bits came later. So I stuck both lists in > one so it'd be a better view of what the data structure would look > like. You're not insane for thinking that. But, it's really OK to introduce an abstraction that *looks* silly on its face at first. You can easily just make up for it by saying: struct silly_abstraction { struct list_head list; } Oh, boy does my structure look silly. It's a structure with a single list_head. Why oh why would I do something silly like that? Well, for now, the code has but one list. Soon, I'll add a whole smorgasbord of lists. Bear with me for now.