Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp688136rdb; Tue, 5 Dec 2023 17:52:41 -0800 (PST) X-Google-Smtp-Source: AGHT+IFahf4kTazwyxMUtavNShBS+auxMyUz4uf3Qb0thNL3x8SPPric4m1NhS6/JkGFvADn9h38 X-Received: by 2002:a25:ae1c:0:b0:db7:dacf:2f1f with SMTP id a28-20020a25ae1c000000b00db7dacf2f1fmr69395ybj.102.1701827561564; Tue, 05 Dec 2023 17:52:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701827561; cv=none; d=google.com; s=arc-20160816; b=EW9GBhX3mBwMZM6lzQtqbj+ILaR2fyCsAHkR6YcYrnEyqGNQhIhJT/y2jtA8yE2WTM aHpUXlraNJZ3VV9vT/jTlk3VNai1IWrE7lOjoEGs7difMTPJVbHMDklltoMruGxYwZVw 9/ChEvz/ra5pu8N3OK/kv8fsDQEPjU1YLyq+9WFu6rYa+XHw8yrvk8IX9t6HdXflAymQ eLRBuj9OSlwAfI8fgRMqI2lnNFUaaX3rDjiRwBToWocMnVC5Nwf690n3jpOvv7l6dRxn p5SzH7m2zI0ORJjLhQvZB1O1A5ZHI2QpncuU8FRNIs1/TvMuQuITFrtu4rVsgwt301wi CqUA== 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=v5RePDUwYgBtV9FXypbgr6pbYR4NEqK4Pxca2uRjtfw=; fh=X4PR+57XmJXd+qvzJoHk2pUlN0Iv6GWiHUf76R2QYlM=; b=SjNMR3fv3NZwbNO8NBYznV9Ufg8c+cOHs84A9os7SbIkzZAnLGLDA81rVEQa1FMh7s K751pcTgNQyuUFUoYZmpMvkO8IezSkzN/GsQi3XAWdA4Dodu93tlrUeUR43B7cbpkYxm Fg2cHsAUejYglhOAoahvPpPU604bGPIBZwqlvU1EpWyG8Oz6xiYRLLFhveMi5KgpCL3V fUlELigsSYs5qWcpcRiwnxLTWrkEC2mOZqW+HKT95eVaSylBuhDg3IGd+7ckhK04vzSO sIdUhw1QDbl/+LR2Bbe9wbxwS2GCNArz2CYMQ4AQ4yNfaZd+IgkalkrtcBRx7zcQDemj +xtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=myDWz9yz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id be7-20020a656e47000000b005c215b317e9si10601813pgb.478.2023.12.05.17.52.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 17:52:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=myDWz9yz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 3B6758030A59; Tue, 5 Dec 2023 17:52:39 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376545AbjLFBwY (ORCPT + 99 others); Tue, 5 Dec 2023 20:52:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52236 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229592AbjLFBwY (ORCPT ); Tue, 5 Dec 2023 20:52:24 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0044C18B; Tue, 5 Dec 2023 17:52:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Sender:Reply-To:Content-ID:Content-Description; bh=v5RePDUwYgBtV9FXypbgr6pbYR4NEqK4Pxca2uRjtfw=; b=myDWz9yz/MAdL2scpZ+48gE3ON HhVmT1I8syLn82evaehJ4fZTsNovpOh6rbzS5Q49ls9o4Ze0ZBWpX9hCWuCYb6ATl/jLBlif+9i49 PSO25Df2P7B168MENUHu6IIJNXLBtSLaufLNPaD+/VfoMWbXuUiLgY1GQidn/RfJ63U33VkcY1wlu f9+EjX2re1+Y/S8+phIM7M2uIaN7L+1qrf6GBYRNEULufkYYEaNjLcQL5csOTq0TjC3DY+N6jgCjm HKNqaxH9A64HQXLFT/0RQJLPXHPX5mcAQBIRYLDCl5KXywyYswl2M7jDHpm+8HvV3RyRxAv8slVoG tFfb3oKA==; Received: from [50.53.46.231] (helo=[192.168.254.15]) by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1rAh5Q-008qWP-0S; Wed, 06 Dec 2023 01:52:28 +0000 Message-ID: <22785d9a-0d4f-4ebd-bc98-3e77dcb4db13@infradead.org> Date: Tue, 5 Dec 2023 17:52:24 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] soc: qcom: stats: Fix division issue on 32-bit platforms Content-Language: en-US To: Bjorn Andersson , Andy Gross , Bjorn Andersson , Konrad Dybcio Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20231205-qcom_stats-aeabi_uldivmod-fix-v1-1-f94ecec5e894@quicinc.com> From: Randy Dunlap In-Reply-To: <20231205-qcom_stats-aeabi_uldivmod-fix-v1-1-f94ecec5e894@quicinc.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,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 lipwig.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 (lipwig.vger.email [0.0.0.0]); Tue, 05 Dec 2023 17:52:39 -0800 (PST) On 12/5/23 16:44, Bjorn Andersson wrote: > commit 'e84e61bdb97c ("soc: qcom: stats: Add DDR sleep stats")' made it > in with a mult_frac() which causes link errors on Arm and PowerPC > builds: > > ERROR: modpost: "__aeabi_uldivmod" [drivers/soc/qcom/qcom_stats.ko] undefined! > > Expand the mult_frac() to avoid this problem. > > Fixes: e84e61bdb97c ("soc: qcom: stats: Add DDR sleep stats") > Reported-by: Randy Dunlap > Signed-off-by: Bjorn Andersson That works. Thanks. Acked-by: Randy Dunlap Tested-by: Randy Dunlap # build-tested > --- > drivers/soc/qcom/qcom_stats.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/drivers/soc/qcom/qcom_stats.c b/drivers/soc/qcom/qcom_stats.c > index 4763d62a8cb0..5ba61232313e 100644 > --- a/drivers/soc/qcom/qcom_stats.c > +++ b/drivers/soc/qcom/qcom_stats.c > @@ -221,7 +221,8 @@ static int qcom_ddr_stats_show(struct seq_file *s, void *unused) > > for (i = 0; i < ddr.entry_count; i++) { > /* Convert the period to ms */ > - entry[i].dur = mult_frac(MSEC_PER_SEC, entry[i].dur, ARCH_TIMER_FREQ); > + entry[i].dur *= MSEC_PER_SEC; > + entry[i].dur = div_u64(entry[i].dur, ARCH_TIMER_FREQ); > } > > for (i = 0; i < ddr.entry_count; i++) > > --- > base-commit: adcad44bd1c73a5264bff525e334e2f6fc01bb9b > change-id: 20231205-qcom_stats-aeabi_uldivmod-fix-4a63c7ec013f > > Best regards, -- ~Randy