Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp3918730rdb; Mon, 11 Dec 2023 04:07:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IHU0dEiC0ZN2jY10Zlelf9/Z1NYhz+npef/KqQ6j2kSVKXrbAv8No9svA+EGKIqrUaFgnEE X-Received: by 2002:a17:90a:ac0e:b0:286:7701:75de with SMTP id o14-20020a17090aac0e00b00286770175demr2988378pjq.22.1702296463032; Mon, 11 Dec 2023 04:07:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702296463; cv=none; d=google.com; s=arc-20160816; b=RyA1VQQOPBgV6DlbhLEYx/S0PFslRCqgsIyvojQ8MKG3O9LWRvB41y5clcT92ZmLrS faxV+oPoa9xK3BcqjtP2jsYFaTr+hzFC3ynDFqKoTjB12v95TmUDy08qp4bIM7W0qosr VMbdKO5RgZqt2rlWs54Ga9P6tSFl/eyTJmeGcAvwz9n5jcDrZ+A0O83aIvgo8q0rE2f5 pAT2fMK7Ohrvl1ZuvxrDMeHvm4x/6mtrCgjgQFiBJEvnWb5zClv/7rll4Z54Md3siL38 9osun7hBCu/bwTWZ9NNJElXbzAd9gjtPROiObcHI9pBh2ZE2rTFKAeadmVuxhaDPjVWt FlCA== 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-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=zt0nW2WMRXVLo8fGj0/D/eYVl54fURhSOQ9Wu4LqCCY=; fh=D0zHzE0rSeaV5xnFPtatb+q+bG5HGveof5GzyGf4cew=; b=YaG5gIFapXMYEY5gYWpzhk5+j1BJfDnFmmwgmGSTaF+hYvfimJSC5OXfLxct3OaJzT cjXSXCLa1VcRoDZRHsiULJvOt/Rl37qoU3I4Ok7XQAnOQuMYXf0+ayXHVEQCVzixgUDt DO6jnEFMlaKipy1CGwKmhx8mta3B1soYGNeqEdi/ov6qKSn+BHIHIKIMBX/eQ/Zb7xiT pd1icMS+r0W+OfAOHrfR6wxGSljz7wvAB5pfzkQ46apK+Yu2nGs5BjBb954/urQI2WRb vQ6jZ+xl5QAAJHsMF6C4e1YWIozCrw3qIJqdhbfy2mNyZuZYl+LWCKNtK1AOg2p7kt8o gZjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=I7z0jLw0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id e22-20020a17090ab39600b0028a2af4cdc4si5734309pjr.139.2023.12.11.04.07.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 04:07:43 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=I7z0jLw0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id C7FA9807DEF5; Mon, 11 Dec 2023 04:07:40 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234477AbjLKMHZ (ORCPT + 99 others); Mon, 11 Dec 2023 07:07:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49004 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234514AbjLKMHX (ORCPT ); Mon, 11 Dec 2023 07:07:23 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E29C5F7 for ; Mon, 11 Dec 2023 04:07:29 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E4579C43395; Mon, 11 Dec 2023 12:07:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1702296449; bh=X0lineiGbEOw+if71lLAZ8HUqLj0hNmSIZ78hSwpTDQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=I7z0jLw0YmiptUk44fTXoCKiT3QeNZ/aTegnhhyJayO6W6a+z+pGxbs8BNYCuNfFv GTSvfE5k97FrQjffo17yf07uV6oECh8mMxPRQzNfDblqx9CtsTMQ82zrx6OCkLMKXX hB8kyfG+baevsO7LVK11BB++H3hLXcQAksXkOJcsPYp+08qaOA0KZgbcbU/Qs3I4+P YPLMRiXbxT0hjcjRZd8EODUpyH5uS3HNL7uFVayjlLiAE6+ZhNpMGOmLl/ZYusUf44 cn9Q7s/8z4K/L9Ooyj0tGMDC1J4Z/n98PNT9bnXtSZp/PoNu1UzHwpP1YIObje5FI2 yrWHHK9i9xXcQ== Date: Mon, 11 Dec 2023 17:37:14 +0530 From: Manivannan Sadhasivam To: Bean Huo Cc: avri.altman@wdc.com, bvanassche@acm.org, alim.akhtar@samsung.com, jejb@linux.ibm.com, martin.petersen@oracle.com, quic_cang@quicinc.com, quic_asutoshd@quicinc.com, beanhuo@micron.com, thomas@t-8ch.de, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, mikebi@micron.com, lporzio@micron.com Subject: Re: [PATCH v4 2/3] scsi: ufs: core: Add UFS RTC support Message-ID: <20231211120714.GB2894@thinkpad> References: <20231208103940.153734-1-beanhuo@iokpp.de> <20231208103940.153734-3-beanhuo@iokpp.de> <20231208145021.GC15552@thinkpad> <89c02f8b999a90329f2125380ad2d984767d25ae.camel@iokpp.de> <20231208170609.GD15552@thinkpad> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Mon, 11 Dec 2023 04:07:40 -0800 (PST) On Sun, Dec 10, 2023 at 08:28:21PM +0100, Bean Huo wrote: > On Fri, 2023-12-08 at 22:36 +0530, Manivannan Sadhasivam wrote: > > Except that the warning will be issued to users after each 10s for 40 > > years. > > Atleast get rid of that. > > how about using dev_warn_once(), instead of dev_warn, using > dev_warn_once() ensures the warning is issued only once. > Sounds good to me. - Mani > > diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c > index 953d50cc4256..b2287d2f9bf3 100644 > --- a/drivers/ufs/core/ufshcd.c > +++ b/drivers/ufs/core/ufshcd.c > @@ -8205,7 +8205,7 @@ static void ufshcd_update_rtc(struct ufs_hba > *hba) > ktime_get_real_ts64(&ts64); > > if (ts64.tv_sec < hba->dev_info.rtc_time_baseline) { > - dev_warn(hba->dev, "%s: Current time precedes previous > setting!\n", __func__); > + dev_warn_once(hba->dev, "%s: Current time precedes > previous setting!\n", __func__); > > > > Kind regards, > Bean -- மணிவண்ணன் சதாசிவம்