Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp170864rwb; Wed, 5 Oct 2022 16:46:56 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4+XfgWoZOR2q18CVPJmQt1EQC3bzV7LHgrti2pRmQPNOFNa1ctt8NMkQzys6UhSBDgbH4K X-Received: by 2002:a17:902:e54b:b0:177:e29e:a0c0 with SMTP id n11-20020a170902e54b00b00177e29ea0c0mr1769818plf.66.1665013615891; Wed, 05 Oct 2022 16:46:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665013615; cv=none; d=google.com; s=arc-20160816; b=ryfPiKot8GObOMDJgsclPSfLBB+ajpq8cFLIWFPKZFpDCkVXbQdjIrEq4AEqWEYpse 4D2EG/tWA04OLEhbMt0rIRQ4D8aBZ5lqgRJVQ/pcNKeSm0OfjS9Kg7FiJ4S0ccTJfxX2 OxpY2p94KHFRomvghm6oTQNTJj0FPVHnZTTcPAcBWoZp46QfEecXtpbVR2HEAWA/Y4l1 126Ynn4na8LLHlehMxIhM0m67yJhiJMNpoaBzEF8dFQrhZ29FTnEILTasse9e0pTDwfv EwUDwPdEHTJ/0SyrSlGoCiCZH/c8VxmK6r8oyH+GHwZ3DzZ0Ycf8lQHQorfdf3HnN899 ug/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=QK9Ffo7noBOOh68pwr2VdWG30paSM0HTeytlJI3ponQ=; b=csD3OI1tnJv/Ek0gl99JkJC3MSjBW6AqEaWA7BwayYWphpS6dJZo1WQEEDqoLCRy84 3jqo9nAoi30lSInN7QEr+1BgZK6dTggXBs2FZWWD54KrvToJJuh1x5AzJ1cRvyV3wojQ GW9dH0CE1Zm/VTEZVX7cpp7ZNm3+cX27rw4f8zlrFZpEk1zYAvObaDSRElRZyLu4M7FL K/yKKxvi8pwe/Bgyst1mLUGMbBO4AgEAMx7GvsINRPPAfTq83zXpX+2O6b7Trd8VeZtW sWCuOf5bcNmGDMG3VKM9X4qP8IYapS3fFxcqi8d0XtmDC6yhMVBB6dvjbXKqkkGoiU4t OXpQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=X9cU4nMr; 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=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k13-20020a056a00134d00b0052b75c32fd2si17814772pfu.48.2022.10.05.16.46.43; Wed, 05 Oct 2022 16:46:55 -0700 (PDT) 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=@chromium.org header.s=google header.b=X9cU4nMr; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229556AbiJEX1M (ORCPT + 99 others); Wed, 5 Oct 2022 19:27:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58112 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229482AbiJEX1L (ORCPT ); Wed, 5 Oct 2022 19:27:11 -0400 Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 34DBA844F6 for ; Wed, 5 Oct 2022 16:27:09 -0700 (PDT) Received: by mail-wr1-x429.google.com with SMTP id u10so151016wrq.2 for ; Wed, 05 Oct 2022 16:27:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=QK9Ffo7noBOOh68pwr2VdWG30paSM0HTeytlJI3ponQ=; b=X9cU4nMrm7TIMWhG4EGG2kJdfwvMNeHdgPmMiXncsa7X2+uTXPuygqXzWmK0IeSqM/ BaybWEoyEEeZB4QjL7geXkScLmUx564HUYiv6dbK9cIiGW1Wgrfj2U8tzeBK9vKFIQGl y+/OkP8BJ9icwnMBiO7Yn9lAB2k/GT1eEgtJI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=QK9Ffo7noBOOh68pwr2VdWG30paSM0HTeytlJI3ponQ=; b=vT8UtbHOhKgZ3vrsBqK5x9cMXlBUgGQx9k7ntTJNvtptgxO1fIARcyfZ+xKPD96Ikm gnm984941IiRUTpkmaywGAaEWr3vKtor6FNLA+D2xfCsrvsnRIeTPlK0P9eaVhh+36X0 ywPo5PYYDPCdV5LYrNFE2wiguVrQbPFhqrZ83P+jXK6ZVjWxwCEECHJ+IzXs8oqzgcjJ zD1JYrLpDMoz92jSKrufh9fqAmBxg6xxXrx6Y8/i7oX046HNPuYorYNGeft9FQUI2b9H Xmz3sGXXgcf5O/Zibm2yEhnb1ZUcj4IUBuWHTwtTcRgSrBE7DPP1q7Bvt8lwOtNTh6aY O+OA== X-Gm-Message-State: ACrzQf3KhuCrdF7aPACY0FS4+Ww1Ah56/8dPxiIV7xwXquds8hffUYwm zdXM8xMD6XMcgGFQSrGAQQB5QxMR7hsJnQXcrqwIiQ== X-Received: by 2002:a5d:4a06:0:b0:22e:3e36:d7e7 with SMTP id m6-20020a5d4a06000000b0022e3e36d7e7mr1206969wrq.410.1665012427627; Wed, 05 Oct 2022 16:27:07 -0700 (PDT) MIME-Version: 1.0 References: <20221004003811.4075765-1-jrosenth@chromium.org> In-Reply-To: From: Julius Werner Date: Wed, 5 Oct 2022 16:26:55 -0700 Message-ID: Subject: Re: [PATCH v12] firmware: google: Implement cbmem in sysfs driver To: Greg KH Cc: Julius Werner , Jack Rosenthal , LKML , chrome-platform@lists.linux.dev, Stephen Boyd , Tzung-Bi Shih , Guenter Roeck Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_SPF_WL autolearn=no 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 > If the kernel is reporting a value, that value needs to be documented > somewhere. If the kernel is acting on that value, it needs to know what > those values are. > > In this specific instance it seems that the kernel knows a subset of the > values, and some random userspace tool knows all of them? Think about > what you would want to see here if you knew nothing about this at all. The kernel doesn't know any of the values. The kernel is just telling userspace that spaces with these IDs exist and providing an interface to access them, it's not supposed to know what any of them mean. In terms of what you'd want to see in the documentation, I think what Jack's patch provides is already the best solution? We're referring to the definitions in the coreboot source tree as the source of truth for exact details about what each of these IDs mean. Do you want that documentation to say more explicitly that these are coreboot-internal data structures exposed for use by coreboot-aware userspace tools and that their exact meaning and format is only described within coreboot sources? Or do you want us to put a full link to coreboot's gitiles page for the file instead of just the file name? Other than that I'm not sure how we could make this more explicit -- we don't have a big official documentation page separate from the source code for all these IDs in coreboot, unfortunately (like I said, some of them a large and standardized but most of them are small, platform-specific things for communicating between different firmware stages that don't need much explanation beyond the source code itself and don't always have a fixed format).