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 smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (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 21D97C47DD9 for ; Wed, 28 Feb 2024 16:20:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id EB22660E7F; Wed, 28 Feb 2024 16:20:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nY5fNaHpBqgH; Wed, 28 Feb 2024 16:20:54 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.166.34; helo=ash.osuosl.org; envelope-from=intel-wired-lan-bounces@osuosl.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 6425760E79 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org; s=default; t=1709137254; bh=mdo+WCwYssTHA5Y/xcZDi9YAkmpmO4mLfP1Bdut2TaY=; h=Date:From:To:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: Cc:From; b=R6FCf6n+yD8cAqFAa/Rbs80xOCIDQNh+DpD2KeVRhYZP5fU4CGnqdjgfAv1wPLShU xoZ6ThtbTt6SCk/5OUSck6k3OWPMq7jjOrL8EGDjwzTyrA0kmgD9jWxevtkwzsVcAM mEG4qCIAKphhhP8jhnopbVgripp4mrW/hJk0Nu2S9FGofHP7GS4FkPjtEvH7q7HG5Y SQO197vwsdzJnYyQnyjXafd6J+pf4s3tRosu8m4VBTXMe/Lz7W8i7nBLu9Ft8kt6Gw ZniLfFnD0N7/3gqW1ETYJ1fPpMxL1pgXB4e9OJinuczBOJUcCPeIdCVlvAZzjaaESL TrqU5a8XpKx/Q== Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id 6425760E79; Wed, 28 Feb 2024 16:20:54 +0000 (UTC) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 7CD461BF2B3 for ; Wed, 28 Feb 2024 16:20:52 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 68B2181495 for ; Wed, 28 Feb 2024 16:20:52 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JzYkZwiD90I7 for ; Wed, 28 Feb 2024 16:20:51 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2607:f8b0:4864:20::112b; helo=mail-yw1-x112b.google.com; envelope-from=yury.norov@gmail.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp1.osuosl.org A8AE38148B DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org A8AE38148B Received: from mail-yw1-x112b.google.com (mail-yw1-x112b.google.com [IPv6:2607:f8b0:4864:20::112b]) by smtp1.osuosl.org (Postfix) with ESMTPS id A8AE38148B for ; Wed, 28 Feb 2024 16:20:51 +0000 (UTC) Received: by mail-yw1-x112b.google.com with SMTP id 00721157ae682-608ed07bdc5so38350717b3.3 for ; Wed, 28 Feb 2024 08:20:51 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709137250; x=1709742050; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=mdo+WCwYssTHA5Y/xcZDi9YAkmpmO4mLfP1Bdut2TaY=; b=w0SfXN6H3jVzb92aoea5Asa8CAVvASPgC4dAHcuWEHM59L/bHlMgy68S2V0It6ISWG GZP7sih35Gqh/Z80bB4Ld/DzNC4sbTP/nTuBL4mE3i62fxCNbuWVZ0nTZ1IZzATHNc+1 fNWnr3fAjk3pxnGKDijHZuc0VqOdQBBfeCGtPhoriHC+/Jmc5bvYVP6vMMo2VZrMaXhC m9IZbp8YbHQYcx6/TKYUVi7q5copmndfhi8zXQ3dIODEdin0g4ae/XGZKJ5P4O+6ouUF WmAd6hVsVCGeof6ieawekCSxYaUe5HQjDppHd5+pyNfMrAMetlnRIhr/4e1tSkF+CogY qf6g== X-Forwarded-Encrypted: i=1; AJvYcCULm0OLfSiPjyJoxjLoOaCumMOEIue6Rm0tZBeqkLegbEkHPu9VrNyevCNREpKaCew1ZdVYZhFeZ9wsPYjT1saP5SVgVu4OP9bAuzF8v+JKsQ== X-Gm-Message-State: AOJu0YyiuZ7zlv/gFUWjGfUtIyeOIJ6o+8FmWMHNqOqiOYiS4cmc9aYY 4g38IadQcnGF7AmTQmRcPI2HTuF3+4Ky3Rf3QtmIpinpfLHsd7KO X-Google-Smtp-Source: AGHT+IFog7Zlb1nyvjIUA4ujLfkoca4T12KmwBu9waTIaa8SAH+ATAMvMCHoJTwS61raA1yWNAPR4A== X-Received: by 2002:a81:e349:0:b0:608:d188:6fd9 with SMTP id w9-20020a81e349000000b00608d1886fd9mr5510309ywl.33.1709137250415; Wed, 28 Feb 2024 08:20:50 -0800 (PST) Received: from localhost ([2601:344:8301:57f0:2256:57ae:919c:373f]) by smtp.gmail.com with ESMTPSA id v1-20020a81a541000000b005fff0d150adsm2393743ywg.122.2024.02.28.08.20.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Feb 2024 08:20:50 -0800 (PST) Date: Wed, 28 Feb 2024 08:20:49 -0800 From: Yury Norov To: Alexander Lobakin Message-ID: References: <20240201122216.2634007-1-aleksander.lobakin@intel.com> <20240201122216.2634007-6-aleksander.lobakin@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240201122216.2634007-6-aleksander.lobakin@intel.com> X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709137250; x=1709742050; darn=lists.osuosl.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=mdo+WCwYssTHA5Y/xcZDi9YAkmpmO4mLfP1Bdut2TaY=; b=if0VktKgsHuMATu+OdWYZng9ksp0Lc55etMaz4hwPwEA56LFtp59U2TOPGWNDfsXGZ NFrx5BMB3AooPKv53gA5zvXPCoHZy4pIGzqGtWIOIDMF9tNmfy0LL5InTWFSDw0NsQih pND2saXEUOnz9Kn4KohjdnPAolpMsHOTI87SahgW7fuiqEgXRYaOcqFbCTl99etHJVrS JjjdVIqylgtq0mrLCLX4/OxBwNNHlqYDDebV/uBiOcItOrIz4odUXH0wkZkWytH6iUI6 vSOXuPX+L4wXbE7Ck6oXKTHfatArzJfxpcOhr7DoECyKlfArqhEeTm7NBs5t1dpHdMp0 13KA== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dmarc=pass (p=none dis=none) header.from=gmail.com X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=if0VktKg Subject: Re: [Intel-wired-lan] [PATCH net-next v5 05/21] bitops: make BYTES_TO_BITS() treewide-available X-BeenThere: intel-wired-lan@osuosl.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rasmus Villemoes , dm-devel@redhat.com, Alexander Potapenko , Jiri Pirko , linux-s390@vger.kernel.org, Przemek Kitszel , intel-wired-lan@lists.osuosl.org, Jakub Kicinski , Paolo Abeni , Wojciech Drewek , Ido Schimmel , Andy Shevchenko , Andy Shevchenko , Eric Dumazet , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Marcin Szycik , Simon Horman , Michal Swiatkowski , ntfs3@lists.linux.dev, "David S. Miller" , linux-btrfs@vger.kernel.org Errors-To: intel-wired-lan-bounces@osuosl.org Sender: "Intel-wired-lan" On Thu, Feb 01, 2024 at 01:22:00PM +0100, Alexander Lobakin wrote: > Avoid open-coding that simple expression each time by moving > BYTES_TO_BITS() from the probes code to to export > it to the rest of the kernel. > Simplify the macro while at it. `BITS_PER_LONG / sizeof(long)` always > equals to %BITS_PER_BYTE, regardless of the target architecture. > Do the same for the tools ecosystem as well (incl. its version of > bitops.h). The previous implementation had its implicit type of long, > while the new one is int, so adjust the format literal accordingly in > the perf code. > > Suggested-by: Andy Shevchenko > Reviewed-by: Przemek Kitszel > Signed-off-by: Alexander Lobakin Acked-by: Yury Norov