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 81CE9C6FD19 for ; Thu, 16 Mar 2023 18:53:38 +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:MIME-Version:References:In-Reply-To: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=mMemdmxPBE/8oYH/Vyvbzhr4ynmKItCqif+pVQDJUjs=; b=RCO2WM0UPFZWO6 2WEAtinPCEjDLcw+oEZyRjUSXfeZERi+PlwfAr++oLXGcix/zAIziTR4s69f6OABVwiTvqFwTm8WI 0Tu/MmdNe5x/RHJZdv6nu1b338foALnubPl0IXlGrf8x/9/7rDpcRJIG7M5rTtj5q+k8Da3ovuNTp ttT8DvwbqSfowfC2fShi3Qelf0vd0rD4ljIqF4yH5V+QjH5iI5d3o6OBUXJkXtBc0Ip0TyaNFVvPT co3gj15vd8BkTwzPA6nOPPKy2mCZ/iQGbpMb/0oYnXhWCjoqy/4fDWFxAf8U0jqSSNuBzc/wh82lm BwUUAsD/+E2HZN1IyeSg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pcsiR-00HIPQ-0Y; Thu, 16 Mar 2023 18:52:43 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pcsiO-00HIOw-0O for linux-arm-kernel@lists.infradead.org; Thu, 16 Mar 2023 18:52:41 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id CC35F620B9; Thu, 16 Mar 2023 18:52:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ECD8AC433EF; Thu, 16 Mar 2023 18:52:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1678992757; bh=59kceHKTQ9pP2wUCJX8jKFzLo8hYVTu7itr7dC78eII=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=PGUIcaZp6+rvtdA+AXlsWzUw+mepWVcL6mXTXRgW0sgMF6pYGsV9aGt95mIYsEPPn mzR0GYlsSB8sEZ3LLO5iUqDWrNzh5Nt6HAgUhzT7o6VTkakqrGjq7kTr2cH10BBHCr OCo5l8B4olKfIqW8YTjTcNro8TfwpLnUErrl6QLzMDzn1LuMaECLpL/frKH3ydjtov 98a0yAp+TFpFg+L3Qe+M5G46OTDt6AqowmZer9SfOghnhOB35do/BwnWONyOswUr/6 /H2Im6x3rgFHDG+u7QfFUyhJiTRD9aUvzjRAv5JfnwbNRHk1pIg+XRHf/yJRir8/BP iv0OYqCiOSLXg== Date: Thu, 16 Mar 2023 11:52:34 -0700 From: Jakub Kicinski To: Andrew Halaney Cc: linux-kernel@vger.kernel.org, agross@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, vkoul@kernel.org, bhupesh.sharma@linaro.org, mturquette@baylibre.com, sboyd@kernel.org, peppe.cavallaro@st.com, alexandre.torgue@foss.st.com, joabreu@synopsys.com, mcoquelin.stm32@gmail.com, richardcochran@gmail.com, linux@armlinux.org.uk, veekhee@apple.com, tee.min.tan@linux.intel.com, mohammad.athari.ismail@intel.com, jonathanh@nvidia.com, ruppala@nvidia.com, bmasney@redhat.com, andrey.konovalov@linaro.org, linux-arm-msm@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-clk@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, ncai@quicinc.com, jsuraj@qti.qualcomm.com, hisunil@quicinc.com Subject: Re: [PATCH net-next 08/11] net: stmmac: Add EMAC3 variant of dwmac4 Message-ID: <20230316115234.393bca5d@kernel.org> In-Reply-To: <20230316183609.a3ymuku2cmhpyrpc@halaney-x13s> References: <20230313165620.128463-1-ahalaney@redhat.com> <20230313165620.128463-9-ahalaney@redhat.com> <20230313173904.3d611e83@kernel.org> <20230316183609.a3ymuku2cmhpyrpc@halaney-x13s> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230316_115240_224882_D0883EE2 X-CRM114-Status: GOOD ( 10.98 ) 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 Thu, 16 Mar 2023 13:36:09 -0500 Andrew Halaney wrote: > static void emac3_config_cbs(struct mac_device_info *hw, u32 send_slope, > u32 idle_slope, u32 high_credit, > u32 low_credit, u32 queue) > > I agree, that's quite gnarly to read. the emac3_config_cbs is the > callback, so it's already at 6 arguments, so there's nothing I can > trim there. I could create some struct for readability, populate that, > then call the do_config_cbs() func with it from emac3_config_cbs. > Is that the sort of thing you want to see? Yes, a structure is much better, because it can be initialized member by member, struct bla my_bla = { .this = 1, .that = 2, .and = 3, another = 4, }; That's much easier to read. A poor man's version of Python's keyword arguments, if you will. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel