Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp3796038rwl; Mon, 10 Apr 2023 00:52:06 -0700 (PDT) X-Google-Smtp-Source: AKy350ZUNMsv5r+A02sX5cuItsKlZUngoJPDSTEifd7R2NaI5x7r8B3gNuxlAE1OcvU99DnzICIK X-Received: by 2002:a17:906:2a48:b0:933:4d37:82b2 with SMTP id k8-20020a1709062a4800b009334d3782b2mr6036144eje.57.1681113126558; Mon, 10 Apr 2023 00:52:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681113126; cv=none; d=google.com; s=arc-20160816; b=oMaVmTqKj2BYD6jQw/tzCCSYTpKpHSapZrB7IjkshCMm9xhdcWT64LE6ruVfoZdF9H r6SGl8AXmvMrH4snuXXIGj5p8B5knipquUX8ErcDQk5CKayK146iPVIUMNqasF8kMEmv 0We+mcVnibRqNCWtCvdyD3ynEnTEOsMgG0bKSw1ipLJ5KnXHxIeYf2tWMaN/kkXkccjS 0/8HPJzNvHMr0M7xuFLcSDJzW46OzDF/TzUlO1u5D7uQWSb3RPXmmzPUb2k7BzXcxCVr tvfHTBQzUOOPlgB9AxYW3isOqRVx8YH6DVn3o5gi9C5IKc+bTExuVS7cpaPViKm7rtnt itlg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=fwrXRGfSmKlo4WbFfzYXcuFfLGPyVKMHaIhBRcO3tu8=; b=VMwCAm/jwif2YO3LslNgWpavPmo3aR8NZR+OjFKAeMIXRwjwZtjEAFA9UKhEfvRsMJ qruiImwt82npJdzEixTBOqoNRY72mw0a43dsIYZgewhPQFuJjtJYZrr/NyxXCNYCdxFP fluuNiEDm8zuqiyfCSf4vjP9pdXYng23LltZnivH4YaygJkcv4y4Qg+eGXxWh05edFCz my9t3s3s3HFMZgqfu1PClgPg0rIpCgcBO16szEKTBHNXtqNhnnmiaMajcHHkympI8p2L XDrxq20PjouBn1zpR9dBOAa5j+0MQEpsH2unT/tJqwATNYinuM2zKLJgFQn87+cVfE6j /0Mg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=v6OPvVGF; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id he33-20020a1709073da100b009287477c339si10834257ejc.538.2023.04.10.00.51.39; Mon, 10 Apr 2023 00:52:06 -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=@linuxfoundation.org header.s=korg header.b=v6OPvVGF; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229800AbjDJHpt (ORCPT + 99 others); Mon, 10 Apr 2023 03:45:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54156 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229611AbjDJHps (ORCPT ); Mon, 10 Apr 2023 03:45:48 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E8D183C20; Mon, 10 Apr 2023 00:45:47 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 8025C61187; Mon, 10 Apr 2023 07:45:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6ECC2C433EF; Mon, 10 Apr 2023 07:45:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1681112746; bh=t/KY9hnRvPrQKkPlCnL180pm6J2CY1USbVAOaF/2POQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=v6OPvVGFJnoAqWMK0YdevoA5VrZN6V7CGXYMj+TXOwhgLqd8Ei0KasbIxwOIIjyCF SyQ4HbELHJyz06RQbJWEO3Z2P2vOmAC6Gegg/OWlOgq55icI0umbUXfERaU9BTe2Bt VKnCPp6g/V7xLjqquZFufYICDeE9iU0S656QP7vQ= Date: Mon, 10 Apr 2023 09:45:43 +0200 From: Greg KH To: Badhri Jagan Sridharan Cc: linux@roeck-us.net, heikki.krogerus@linux.intel.com, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1] usb: typec: tcpm: Add kernel config to wrap around tcpm logs Message-ID: <2023041028-irritate-starless-a42f@gregkh> References: <20230410073134.488762-1-badhri@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230410073134.488762-1-badhri@google.com> X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable 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 Mon, Apr 10, 2023 at 07:31:34AM +0000, Badhri Jagan Sridharan wrote: > This change adds CONFIG_TCPM_LOG_WRAPAROUND which when set allows the > logs to be wrapped around. Additionally, when set, does not clear > the TCPM logs when dumped. > > Signed-off-by: Badhri Jagan Sridharan > --- > drivers/usb/typec/tcpm/Kconfig | 6 ++++++ > drivers/usb/typec/tcpm/tcpm.c | 9 +++++++-- > 2 files changed, 13 insertions(+), 2 deletions(-) > > diff --git a/drivers/usb/typec/tcpm/Kconfig b/drivers/usb/typec/tcpm/Kconfig > index e6b88ca4a4b9..4dd2b594dfc9 100644 > --- a/drivers/usb/typec/tcpm/Kconfig > +++ b/drivers/usb/typec/tcpm/Kconfig > @@ -18,6 +18,12 @@ config TYPEC_TCPCI > help > Type-C Port Controller driver for TCPCI-compliant controller. > > +config TCPM_LOG_WRAPAROUND > + bool "Enable TCPM log wraparound" > + help > + When set, wraps around TCPM logs and does not clear the logs when dumped. TCPM logs by > + default gets cleared when dumped and does not wraparound when full. Kconfig help text needs to be wrapped at the properly width. And you do not provide any hint here as to why this is not the default option, or why someone would want this. So, why is this not just the default operation anyway? Why would you ever want the logs cleared? thanks, greg k-h