Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp80964rwl; Thu, 23 Mar 2023 13:00:57 -0700 (PDT) X-Google-Smtp-Source: AKy350ZYka2AyIDtbMhqU2YRn35ox7N72EB1u9aMRtG5+F60+WnJ1oq63uoJT6diLhodc9Nk4a89 X-Received: by 2002:a17:90a:4bca:b0:23d:2d91:ab71 with SMTP id u10-20020a17090a4bca00b0023d2d91ab71mr268656pjl.6.1679601656742; Thu, 23 Mar 2023 13:00:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679601656; cv=none; d=google.com; s=arc-20160816; b=g/1C3s3pAkbVQFyzteAtugcyhckWweQD78EMp0e1C652T6v7QiWGwVXfL9uwOmg1kw ywDOQYsy7G3/gzZWMqdwxW/LQKvK7Tlw56kFw5v08YmvrkOEMRCkMZyLPrC5Nzkz+rwc +VplUhyYANEPozHcJzmHADWcULlRnbFCeu9kgfMxdHxBfljvKqPf9ZGcBaNpKyDDzJVa R7p8XnYcPZna56gThcsaClKMEbyGMc+8KbWc+RcQt0jkuC+FYxcJFpy5c6eiBhSuK0Su DYVeSX/YvMkOmJk3C9wU9BoJzQP7CPlAKy2YIacxaIHXYyXdFUc7z/R1Gfark4A6QTd6 /g4A== 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-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Cs3kw5n3QceAoZs6+6Pk6Dr8Q9QM7dE5PeddOR33BGU=; b=ja8+9AP0U6N5PEzrBG+OBnn4HYC93nmecGvgd9Oukj5H+QTyW6yyWjogyvaFMHABMs gyAYMpAuwXaNquGaFA+/o7Ve2Yx+OCHHWHkk0xwL/gcnNrVRzD5/4VanR5Tl45Zb3YbY E1SFl4TPlr04lrvNPNMcF5jm/1WCbQzNWzD9YrGfAdtAbLNYO1n/UiCVXu868bv6Ubtd 9fiFcNWwFLwxQcmyl/lmaGvjv2NCHSIBVIgg1mDYk6XFo9OnHGJA3lQEkDWLP91w3HWt WWPJSoGWgaCSSY3tzD5HD1nFyfAp/T8/3jhSprV8u1m5M/OmL9f6bu4bEtiZ0WbynnEi tJHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mailo.com header.s=mailo header.b="d/RQhi09"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mailo.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id oa10-20020a17090b1bca00b0023d1679ac2dsi2507211pjb.169.2023.03.23.13.00.35; Thu, 23 Mar 2023 13:00:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@mailo.com header.s=mailo header.b="d/RQhi09"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mailo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229702AbjCWTq5 (ORCPT + 99 others); Thu, 23 Mar 2023 15:46:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52756 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231329AbjCWTqv (ORCPT ); Thu, 23 Mar 2023 15:46:51 -0400 Received: from msg-2.mailo.com (msg-2.mailo.com [213.182.54.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2E50B23C7D for ; Thu, 23 Mar 2023 12:46:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mailo.com; s=mailo; t=1679600790; bh=Ofo5WnknXu2q4PHMQtHwGNgTsx9PA3GsytL7rSclMoM=; h=X-EA-Auth:Date:From:To:Cc:Subject:Message-ID:References: MIME-Version:Content-Type:In-Reply-To; b=d/RQhi09FV2kGD7zsVGy49E61BrwVVX1p8onsuoJ937QJonp0xESkL1t0xv6efXLs 6v9HL8quo3/fR0D7I9sVGtQZmExwTGNZ6A+i+nbkaCnf7g2qLRwyi233ZTlNa5pXKI 3IWFT/21lXvvaEX0neoGaJl9+cXCBpVzlNSPzYdE= Received: by b221-3.in.mailobj.net [192.168.90.23] with ESMTP via ip-20.mailobj.net [213.182.54.20] Thu, 23 Mar 2023 20:46:30 +0100 (CET) X-EA-Auth: jRldBc3fw9HBPmS2VhRtuXpKewjU9HPr0zvL+RMjtoTBXoNrOPkyuG56v9mN9SoAFgEQrrgGpYQwP1A4u5xeLZPK9L+o8cFj Date: Fri, 24 Mar 2023 01:16:26 +0530 From: Deepak R Varma To: Greg KH Cc: Julia Lawall , Alex Elder , Menna Mahmoud , outreachy@lists.linux.dev, johan@kernel.org, elder@kernel.org, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev Subject: Re: [PATCH v2] staging: greybus: use inline function for macros Message-ID: References: <20230321183456.10385-1-eng.mennamahmoud.mm@gmail.com> <2e869677-2693-6419-ea25-f0cc2efcf3dd@ieee.org> <5efa6e6d-8573-31de-639a-d15b2e9deca0@ieee.org> <48674d8f-9753-780c-f37c-f83ea2855ae6@ieee.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 23, 2023 at 06:22:55AM +0100, Greg KH wrote: > On Thu, Mar 23, 2023 at 10:35:59AM +0530, Deepak R Varma wrote: > > On Thu, Mar 23, 2023 at 05:58:02AM +0100, Greg KH wrote: > > > Nice, that shows that it is the same both ways as the compiler version > > > you are using is smart enough > > > > > > Which compiler and version is this? Does it work the same for all of > > > the supported versions we have to support (i.e. really old gcc?) > > > > > > For the most part, sysfs files are not on any sort of "fast path" so a > > > > Hello, > > Is there a guideline/documentation on how to identify if a code is part of > > fast/slow path? > > Not really, the general rule is if the code is used in a function that > is time criticial, then it is in the "fast path". > > Normally the code path for I/O or for determining what process to > schedule next is a "fast path" as you want to do the least amount of > work in the kernel so as to get the I/O to the hardware or caller, or > you want to schedule the next process faster so that it can do the real > work that is wanted. > > But for some I/O, where the hardware is the limiting factor (like slow > USB or serial connections), no matter how optimized the kernel is, the > data can not get to the user any faster because the hardware just can > not provide it, so for that, it's not really that critical. > > Note that "time critical" can change depending on the user of the system > and as hardware evolves. > > One example would be the creation of a number of sysfs entries for the > disks in the systems. On a "normal" system, creating them all is trivial > as there are not many disks. But on some "big" systems with many tens > of thousands of disks, it can become a boot time bottleneck. > > So it's usually "you know it when you see it show up on a profile", use > the perf tool to test your workload on, to see where in the kernel > things are taking up too much time so you know what needs to be made > faster. > > hope this helps, Thank you Greg. Yes, it definitely is very helpful. I sincerely appreciate the explanation and the time you took to write it in so detail. I am Obliged. Regards, Deepak. > > greg k-h