Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp3164589pxu; Sat, 19 Dec 2020 14:41:32 -0800 (PST) X-Google-Smtp-Source: ABdhPJxUqySQthmC1yQP0yKp3AMFv1BXzxujFbOm/dKwKWYj7ig/ZXJuabHiGUBZinkjHpyvMU/7 X-Received: by 2002:a17:906:2681:: with SMTP id t1mr9956184ejc.29.1608417692384; Sat, 19 Dec 2020 14:41:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608417692; cv=none; d=google.com; s=arc-20160816; b=Y9Jy25rOY9ikJZszsk77eTZmoGd4YlaF4Rgq9HeIvnqjUudJe/nKimlMg+xqfSnhRp pwaCb35+3kr+SDRvKdpTf13PY2Fp8L3oYq1wmiQJasVo22iZXuOklSRHaA8nYsT8T4Hz jvd0221B4aUXsLqYD5JW1Oro2/pD6Gkqlqqvez04/DZ9XYs/flfqwoVTJJVrwGPMhnD1 84sGqWbLybqCdSsOoJ6rkRPDXlKjYQsKlaIav9WAZkU/B4p8Xh24dVnFb6YIDboobpqQ c3VE4tmTrz40Z3YGuHhGpOUsJHUoVfCk5/m4OtDru1Y6vkrFSQtrZ/dalx32ohPxIvhh lg9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=3kfO/cCpJ6dTCtRANlf2ZvCPmTfbvJvYLOve9Fhsc3I=; b=an/hq3XEyK2FWS6Ajb0WRzL3BAGL56WGxx4leewDhRe/y3Xbib+apcFmp46yf6nxkm Et9jdPBQ8dr8NU0iupYE7LLt7FvzKeKIUrpqoH2vYrQw95vVwuJqLcfrU/R2OdnsocuN 9JdBh7lhvpCYmNOZb6jMgCINiA7ZwXKPl/SWLR0Dw4IYvLHAx9VNbIl4YbC6XGwi7XtE iuT1NkTPEi49ZjZBJk8NKFmMtN7SpPiQkVvc8LEVU0Bi/3+57RS7EXESAkj1096ZrHIC 61myLC02MA7Gp5itHfLdIagGZej//S9VrChtyL+MT2L5JmZk4LaCKv4Db8UOyG7KQ2J5 THaQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=GAZNK58c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b22si8984538edj.13.2020.12.19.14.40.56; Sat, 19 Dec 2020 14:41:32 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=GAZNK58c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726443AbgLSWjS (ORCPT + 99 others); Sat, 19 Dec 2020 17:39:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44242 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725944AbgLSWjR (ORCPT ); Sat, 19 Dec 2020 17:39:17 -0500 Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89CC5C0613CF; Sat, 19 Dec 2020 14:38:37 -0800 (PST) Received: by mail-ej1-x632.google.com with SMTP id q22so8447895eja.2; Sat, 19 Dec 2020 14:38:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=3kfO/cCpJ6dTCtRANlf2ZvCPmTfbvJvYLOve9Fhsc3I=; b=GAZNK58c3CTwPMGH0U4zl4ENKCkxRtPBrZAfMRjcgWV8qZzaeO24jM02RqHRDiR8S4 s8+nUWsbsvGY6u3o3MVuSdKo0RTQkr9rPGcElU8Hmb4yYcIbEJWYAiCPCpkpE8YM/fRL RJnsbqCQUj0q7UwuWtNXnwD2P0Eh9y0e3dwpN5jiMdNzs5uNK8amj9otw5DonKuJQxJ8 isWEmUEEAFR7aBUFiT8xiuN4hTst7h37gW9acjF7KgpkGCI06TauHVTMomGaECfKOE8M 4OR1c8FVJnpVsTQGNhYbvGMjqVa0MHYRbtVhqGhBY1pGBEQibhKZumQTcs5fFROCD4R2 grNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=3kfO/cCpJ6dTCtRANlf2ZvCPmTfbvJvYLOve9Fhsc3I=; b=tKjqmPpGnBBpmuEdIpN8S7GCN2XyELHxV4vEa/NZI7jbEFECOCbHLXLT+PgMu3R1/K bYloxO4gPA0dqiYjidY2MRziUwOdcp5OVYUjVPY8rpvwAfIyVdp6dygM76P8g3sAX3M3 Bl+YYm4ppyGMv/kK1lEF+MEgMcRq8sv12cfX/kjIhe8Eret2mwwdjPBzjQbRDxAYE5l5 wfrBJM2hJqtexZBlkpUBzlI7/qIuMPCyJILWG71hi7tQsfyTXuK4TdgQTSV7175QFgJ7 bTze891zFeEUFeAhAgC/b6hjgPLLb+uowWs9zcuF/EGGrJBNL/vIq1oo9gYF9+G4M5F2 A5iA== X-Gm-Message-State: AOAM5337rz7nZuQ7aoAd6SggsEHPozdA/iOJ3iIf5iE+v7KX+Ydvdx0O HTTHUFtSE2wZTv9kjIyQTh2Fnn91aa967hXrHxpvtpgG X-Received: by 2002:a17:906:4050:: with SMTP id y16mr9680503ejj.537.1608417516054; Sat, 19 Dec 2020 14:38:36 -0800 (PST) MIME-Version: 1.0 References: <20201219125344.671832095@linuxfoundation.org> <20201219125345.376925474@linuxfoundation.org> <20201219215139.GA29536@amd> In-Reply-To: <20201219215139.GA29536@amd> From: Martin Blumenstingl Date: Sat, 19 Dec 2020 23:38:25 +0100 Message-ID: Subject: Re: [PATCH 5.9 14/49] net: stmmac: dwmac-meson8b: fix mask definition of the m250_sel mux To: Pavel Machek Cc: Greg Kroah-Hartman , linux-kernel@vger.kernel.org, stable@vger.kernel.org, Jerome Brunet , Jakub Kicinski Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Pavel, On Sat, Dec 19, 2020 at 10:51 PM Pavel Machek wrote: [...] > I can't say I like this one: > > > > clk_configs->m250_mux.reg = dwmac->regs + PRG_ETH0; > > - clk_configs->m250_mux.shift = PRG_ETH0_CLK_M250_SEL_SHIFT; > > - clk_configs->m250_mux.mask = PRG_ETH0_CLK_M250_SEL_MASK; > > + clk_configs->m250_mux.shift = __ffs(PRG_ETH0_CLK_M250_SEL_MASK); > > It replaces constant with computation done at runtime; compiler can't > optimize it as __ffs is implemented with asm(). what do you suggest to use instead? personally I don't see a problem because this is only called once at driver probe time. Best regards, Martin