Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp154027rdb; Sun, 28 Jan 2024 19:02:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IFhlu348K6V+RSpbSPpdz8Z/rA/Dn8OcMeTZR+mA7kSfiqtIJ722bjWSBUgCljGxwvrsZgF X-Received: by 2002:a05:6808:1442:b0:3bd:c0f4:c4a1 with SMTP id x2-20020a056808144200b003bdc0f4c4a1mr5757635oiv.11.1706497343372; Sun, 28 Jan 2024 19:02:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706497343; cv=pass; d=google.com; s=arc-20160816; b=PJHiMrgt2A8gx5fRymbMMP8uOINyjzIEjCA8hegk5x3ZiAWSYG/jnGMI8p6y8RzVia 08hCNu5TY4LMf/CmFFqRKMCWJyhoDLEQgUh9MLnElMD7Sob9mvNBsMy/k1iYL9cBD5yL pd3+2yxuBC4k7f2v4M8ITOrN2Ji4sWGGjAv5tOWp8RU7GY2bcLf+1lSXt9lSdzaF4RiL Ltke07sD71/xjDqDMI6ORdjv3hVJdeOsgfAAOLWd/rVcBFHh6HPHEtSOnmTSlo6gqK0f kaL99e6EtUw+cTHJTJ6gnfp8KnrUFr5CHTCq9zhe7WdKLdkAJlk09elDbZm+0p9aiML9 9efg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=uZgzfc4q8wyPtVrbuYJMWOoz4ZtMUHFMRKeo6UesNQA=; fh=72VhXorOtJ4z09r6haZG0qEOKu4MCVq+n8DvZ2uIVvo=; b=K/oZgfYpqCh3ON/Ko9bU3Nbl0QNKy1fVxPAoxRRBkM+psWfxe2uMkHb9/NifbNaSmR pH7l7zXwOXJyv2blpAltV49tW8wFZHf3AwHAg+mXO2kNQK4VLV4r9zUrUx9VxDUIF9dw MlK2wKJdfJlHK/Wclj16CbS+/80/zJUVVLyG1AanJoyRqWgBUNPkr2Qvm0T5cXZWuqfz jaqahTq6Io5J/bwS9nkjWW9NUmNRhXnruTDbjVWW+t9agh8tF1N2UW4g4USPhs8M884b nJNmLB7eoxiVOD7GeQABLTgfAJaywLC4UmRZ+xLbXbPPGaTLGpHRYNa4dVVeas3RQKou 8V2A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=S6zWdLaB; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-42113-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-42113-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id q6-20020aa79826000000b006dd9213a323si5018439pfl.333.2024.01.28.19.02.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 28 Jan 2024 19:02:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-42113-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=S6zWdLaB; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-42113-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-42113-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 1060CB22AFA for ; Mon, 29 Jan 2024 03:01:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0AF38F9EA; Mon, 29 Jan 2024 03:01:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="S6zWdLaB" Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BA8551078D for ; Mon, 29 Jan 2024 03:01:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706497299; cv=none; b=JSMB66fo5kyrwaTCAbZV5115RIh3Rb/zldl/r721vuqNGYsVOVbAm83X77f0etVnHwTSy77EpRswrpipH2DbbzOaNurbkAMZ0oM1IKMxPpI6ToD+kRRqpX0mLHhsnZ0wJqH8jvRMzdjn+q1GQH2Tl/cy3CGDJPEPibT0DiwywKc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706497299; c=relaxed/simple; bh=Q1j+KR/FHxsj92SR8cJe4NVvdgceho6xI2qepjHH75w=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=G/TQhWYggpQy1KvTpr3tuSQIM2sQh1qR09roJeWXInJWlzZtx3b5GsYNOpY+MrhvW5lzmQBZV5SK5R7fpq9evPBeqJ9AP8Xg60aAnqTFj5UCEsKmK4zwujxwBO01nTqfoFbWcfauf1ANSZ/VvsieOsoDzy63c5SYKmrSyZ+jD6k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=S6zWdLaB; arc=none smtp.client-ip=170.10.133.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1706497296; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=uZgzfc4q8wyPtVrbuYJMWOoz4ZtMUHFMRKeo6UesNQA=; b=S6zWdLaBwGTNfptAzO+HzaPX6XJlvW+g3MqXn0naqYDUMFpHPzJoKkbBx3X2M58wi+bZkC n9UXHYYOJXllywZnqa51u5uCta2F6Y4HunrraW5hi487Tu7gT58Dq98KPI4Kzlrlhjsyr1 NSJevGxfC+QS8zcFWe3Ta+CiRy1XRLU= Received: from mail-pg1-f198.google.com (mail-pg1-f198.google.com [209.85.215.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-30-VQoPQ3B4NfGhgCr6SrlVGg-1; Sun, 28 Jan 2024 22:01:35 -0500 X-MC-Unique: VQoPQ3B4NfGhgCr6SrlVGg-1 Received: by mail-pg1-f198.google.com with SMTP id 41be03b00d2f7-5ce53c43ea1so1606765a12.2 for ; Sun, 28 Jan 2024 19:01:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706497294; x=1707102094; h=content-transfer-encoding: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=uZgzfc4q8wyPtVrbuYJMWOoz4ZtMUHFMRKeo6UesNQA=; b=omFdE3DlfJibTAX6k5OsMHHSxfMSLCr4+uKEgO8CTw2V5/Ucn+4TyMzScFQJ0A13KP UVCGfgCKe5+/kw8w/6rjBckAj4PYIU1VV4MIOagwIlsS/uTgKK01AZjj4QNBvNqE/zgs 3V4Xafy/zOgRa7UMj/jg6MjldGg/lD3iHaezDkc9rLHrtngf5TbUil7g4RwMZkV0jJUc ehjoof+22988fQ+0B1pVsHdDs7F1zQy6dicP5zSM5bNpdzomYfLYJkjY14IxDlwHEBRy makr59CoGbx3Z+IiTUC4DO8gQhNSeL+oKG2cIYcqwD3hUocgQIxmhmSYT/kxsNIGDmlQ TwEA== X-Gm-Message-State: AOJu0YwFENDp50FYK/t31YEIy/Ryk51eG0A8XVMrvmF+XWIfo6BY6XTE /g2V3X1ZMnxFvepHuxlMlr1xtlidBXAQupcPVnpXrLAmWPQYQkeiaUBblc73Oc8b1d2qP61c6q9 f3ohJMDlaDRy+4rwl1mSHYV+L+ucafPsdBmDHCkBSXHdWfnaV/lhqQKcICo7TIdoIeDf/c7WXEY a76++Y3+WiL9AwoUFSU9i6FJKt5E7mec1WjcPY X-Received: by 2002:a05:6a20:94c5:b0:19c:ae3f:7d66 with SMTP id ht5-20020a056a2094c500b0019cae3f7d66mr336817pzb.22.1706497294004; Sun, 28 Jan 2024 19:01:34 -0800 (PST) X-Received: by 2002:a05:6a20:94c5:b0:19c:ae3f:7d66 with SMTP id ht5-20020a056a2094c500b0019cae3f7d66mr336803pzb.22.1706497293738; Sun, 28 Jan 2024 19:01:33 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240126002550.169608-1-stephen@networkplumber.org> In-Reply-To: <20240126002550.169608-1-stephen@networkplumber.org> From: Jason Wang Date: Mon, 29 Jan 2024 11:01:22 +0800 Message-ID: Subject: Re: [PATCH] net/tun: use reciprocal_scale To: Stephen Hemminger Cc: netdev@vger.kernel.org, Willem de Bruijn , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , open list Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Jan 26, 2024 at 8:26=E2=80=AFAM Stephen Hemminger wrote: > > Use the inline function reciprocal_scale rather than open coding > the scale optimization. Also, remove unnecessary initializations. > Resulting compiled code is unchanged (according to godbolt). > > Signed-off-by: Stephen Hemminger Acked-by: Jason Wang Thanks