From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D5286C433F5 for ; Mon, 22 Nov 2021 12:06:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=kOTys4cZTVXWAICQmzx+wxMJItEPgqaqvXO4uqLZKdc=; b=ovRzhMsgGv4jqm gEp1OeLN0z2rMoIbm+fc6ehrwMOuYmMsGWmmjo/L5Pc8iVCKF8/NAmzYAF6sLYvM9lgaGCyl6AJIG bAhZShSHSPlPFEPZg58sQo2uFVd6SfPqdgp0uquubHHreg0KiJ05eZsL0fZkB5Z88crS7ae/fq8az zIYvVHOkNsSs9XwNG4DlSZrtvbhyxC6bXmaUHwa1Rjyn4YaaZocer/2+K3zn/GquC5NX4fOXRQyRa UUpfs4dL5Qea5W7Q96bbjOvrBuaAZfztcQ7ZFOSRiaonEvypv6I/r49ta+dHbO3nmLPjKh0fka687 h7IQJ4Sdh4ZIbKsvMzbQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mp83K-00GESw-Mm; Mon, 22 Nov 2021 12:04:06 +0000 Received: from linux.microsoft.com ([13.77.154.182]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mp7WS-00G3jc-EC for linux-arm-kernel@lists.infradead.org; Mon, 22 Nov 2021 11:30:09 +0000 Received: from mail-pf1-f175.google.com (mail-pf1-f175.google.com [209.85.210.175]) by linux.microsoft.com (Postfix) with ESMTPSA id 22A1F20CDF92 for ; Mon, 22 Nov 2021 03:30:06 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 22A1F20CDF92 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1637580606; bh=Gc95weIGGpO+jXyf82d/fH9Q/HcQ7XjvTMwfhsgPgI4=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=OI4ZWxsym+mw7hYk8A2um8Y/M/Iwse97wugDiCCxlFnyfQcsFtsRLS1z2D5hW+Vkx ZvfKh0GEahgx9z15FD8Kg/9y2H4v0Bskj8nYnCPjrsBuE9e+z7e9DR/nE4/0Liwy/Y 7PUedmA1zE8iO5LF/8jCK7UhzX+cPqFhS+dLlt0w= Received: by mail-pf1-f175.google.com with SMTP id 8so15799581pfo.4 for ; Mon, 22 Nov 2021 03:30:06 -0800 (PST) X-Gm-Message-State: AOAM532Nr48cJXpifl0Wexon92w6Wdutd74NhlNBNLbDOFM6h6HGBt8I /X1jKnaHo2nMiXHKtkI8hLPih+FmZyZ7NbUJQkE= X-Google-Smtp-Source: ABdhPJxSTevhDOzsZ28L/0ODxidwCGCcz7z3raqHwmrHB2ue0L4viG8Xnag+6PfN/t0C11BGDPcCuvS4O41ETSmLU0s= X-Received: by 2002:aa7:98dd:0:b0:49f:bab8:3b67 with SMTP id e29-20020aa798dd000000b0049fbab83b67mr42597291pfm.86.1637580605680; Mon, 22 Nov 2021 03:30:05 -0800 (PST) MIME-Version: 1.0 References: <20211122111931.135135-1-kurt@linutronix.de> In-Reply-To: <20211122111931.135135-1-kurt@linutronix.de> From: Matteo Croce Date: Mon, 22 Nov 2021 12:29:29 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH net-next v2] net: stmmac: Caclucate CDC error only once To: Kurt Kanzenbach Cc: "David S. Miller" , Jakub Kicinski , Giuseppe Cavallaro , Alexandre Torgue , Jose Abreu , Maxime Coquelin , Voon Weifeng , Ong Boon Leong , Wong Vee Khee , Tan Tee Min , "Wong, Vee Khee" , Xiaoliang Yang , netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, Benedikt Spranger , Thomas Gleixner X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211122_033008_620125_E46B7E9E X-CRM114-Status: GOOD ( 12.54 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Nov 22, 2021 at 12:19 PM Kurt Kanzenbach wrote: > > The clock domain crossing error (CDC) is calculated at every fetch of Tx or Rx > timestamps. It includes a division. Especially on arm32 based systems it is > expensive. It also requires two conditionals in the hotpath. > > Add a compensation value cache to struct plat_stmmacenet_data and subtract it > unconditionally in the RX/TX functions which spares the conditionals. > > The value is initialized to 0 and if supported calculated in the PTP > initialization code. > > Suggested-by: Thomas Gleixner > Signed-off-by: Kurt Kanzenbach > --- Nit: "Caclucate" in the subject -- per aspera ad upstream _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel