Received: by 2002:ab2:784b:0:b0:1fd:adc2:8405 with SMTP id m11csp376442lqp; Mon, 10 Jun 2024 06:57:18 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX/XsuCDKn4FV6FFvDgiJuYI+3SrfNOK3MGIFRYvQWxtU/9FvOei1kJqoSWi1M1Tr38oKpFdZv/9yvVNvRCwjuuLvyixwQ8ZEb4TEBalA== X-Google-Smtp-Source: AGHT+IF6ekh44JNhs6scfR7+oAfl0m/vcIN2up+MvfDSIVmrj8pVizlEC0lWSnlwf1fkFz+vZ/g2 X-Received: by 2002:ac8:7fd6:0:b0:440:535c:6408 with SMTP id d75a77b69052e-440535c67e0mr85873391cf.19.1718027838303; Mon, 10 Jun 2024 06:57:18 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718027838; cv=pass; d=google.com; s=arc-20160816; b=fKQvXgf28RinY9GPCDBNI/osyKL9TJ5NW5/O59lV7dUAAUTzihvDa3QBX1+FWQ5J5x cyRxGltK4qWXmOp0KioNBlAzLVNqsrp/tWi6XAtW8Xbynqj4Cb3zO9vl0DNklJip8Kn7 xSyU8cT0nrJt+LMbS4NzHWuYqhjLQpLXGHOxcxZvAT2gyF8Qzx+vXhDyEyQpVgA47WBo HBI14mihhjkXMhMiQ8ZIGQHyr5cq8jGTTp1R8yvEvkZ1LoyPwt9nckTPOeLAJS1rSSRy bHD+Dgal7cdoUEo3UDOq86j5PlijMx4PHMef5cDWL1Smyp95sGTaASVzNFlqAQGzo1Ds zTHw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=z+YAHBI/Z+3VNc3TEhUT33G8bD0GATdmtiU4ObQgIxU=; fh=gtIhpoKzZls18bYplJpRwQfq5nA5eeUFrKCkjuCRSCk=; b=kBQVyKZfiqPlAGJmYrQm+QR+fLQbuxsoVPICWItSmIElA0cljr1w/QmQWhQML5/VV0 bzsQblrJcsgLJHkhU7KgEd+MDWwEvl0lvklM+ug/qS5Mc2X2FE2gx+8i3aQHiDGnLTFg B88WCZw21OTCs9wC0zmJbYRJiCtD+/3UmNkYsB9D6lzCYYAkfECJ7gHGaYfsPJowQAJw fikWZDe0HPlmO3yb4KhO62mqN0uUxmPFIKShanACyQ7SIabvv3+NDzLvcs3525t4zxJo A5sE+5IMHMjxLW4rPvYMvSq0FIBTQz00HNngmE25ZTjuWfr5pz/5TU8O5RAAxG0+/3nM ipGA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@denx.de header.s=phobos-20191101 header.b=oswnRRgJ; arc=pass (i=1 spf=pass spfdomain=denx.de dkim=pass dkdomain=denx.de dmarc=pass fromdomain=denx.de); spf=pass (google.com: domain of linux-kernel+bounces-208293-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-208293-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=denx.de Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-4412cefe40asi2952491cf.145.2024.06.10.06.57.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Jun 2024 06:57:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-208293-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@denx.de header.s=phobos-20191101 header.b=oswnRRgJ; arc=pass (i=1 spf=pass spfdomain=denx.de dkim=pass dkdomain=denx.de dmarc=pass fromdomain=denx.de); spf=pass (google.com: domain of linux-kernel+bounces-208293-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-208293-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=denx.de 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 0B94B1C22ACC for ; Mon, 10 Jun 2024 13:57:18 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8FC041304AD; Mon, 10 Jun 2024 13:45:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b="oswnRRgJ" Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 088E1824A7; Mon, 10 Jun 2024 13:45:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=85.214.62.61 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718027130; cv=none; b=PxF8crccpttrEtJfBjVpGn8cA2ojq5VVOOAQcLRteOkjV3C4o/vCenjxCA2VJP8opP4z8XLucVCRF2MntCPLx5eqojAOUo3482OL7NBPxN82AA43NzkxWVmYtSjEYCiDPB0RhnafqJ2nBHblChIH0BdF68Y1giPd1yhmdPu9UXI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718027130; c=relaxed/simple; bh=HUzVcOKwt3n8v4S633OoGkbwS2m/jgHHZmt+g82ohZY=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=dCH6zQAlChgHc8eE3EmtCVtdMrXcQmaWuMlqP7lEBv+OjtMlYdd8um5oBH6LZG81R5y3Jb2l/ti+bMnBQWl+YtbyC0ncl2Tm1AzlwiGeZSp6GHXRNMmwSVWhyKJ5bH3rP2Rq9HZXnyE+dYaBos1mthXm4rxTsiOGhoxjZ662Rlw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de; spf=pass smtp.mailfrom=denx.de; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b=oswnRRgJ; arc=none smtp.client-ip=85.214.62.61 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=denx.de Received: from [127.0.0.1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id CB023883D2; Mon, 10 Jun 2024 15:45:25 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1718027127; bh=z+YAHBI/Z+3VNc3TEhUT33G8bD0GATdmtiU4ObQgIxU=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=oswnRRgJs0dZeDx6cEzRP+cjqeMFnq3UbuJLyc5aJTofIafPTT9C8bKu9mgtbOqAc +V6Y9/sXhHD8dNsYWqwsSsyLtHOw25bbSc1AV5moxNghJeMYnZ3x2fZstr6cHrt5rz A7jNAkDI/liwIuAQk4YweZns11YDYRMu/KdZMjrmm+wMC+NP2uQKd02tqTmUY5i+gC Hb+ya75YE4ks9RncB4P1ZlH7tG8qdngaFYwSxp31zRfo0SIV1bku5KxLeT/pG1ewzY tO09rOcb9RaUY3rC5qsLHbJYxQETX/nwayPj9oTG5pBShdPehD5OBmM9TuQRv3zvPU i/taDf05suEhg== Message-ID: <09105afe-1123-407a-96c3-2ea88602aad0@denx.de> Date: Mon, 10 Jun 2024 15:43:52 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [net-next,PATCH v6 7/8] net: stmmac: dwmac-stm32: Mask support for PMCR configuration To: Christophe ROULLIER , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Maxime Coquelin , Alexandre Torgue , Richard Cochran , Jose Abreu , Liam Girdwood , Mark Brown Cc: netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20240610071459.287500-1-christophe.roullier@foss.st.com> <20240610071459.287500-8-christophe.roullier@foss.st.com> <20139233-4e95-4fe5-84ca-734ee866afca@denx.de> Content-Language: en-US From: Marek Vasut In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean On 6/10/24 1:45 PM, Christophe ROULLIER wrote: > > On 6/10/24 12:39, Marek Vasut wrote: >> On 6/10/24 9:14 AM, Christophe Roullier wrote: >> >> [...] >> >>>   static int stm32mp1_set_mode(struct plat_stmmacenet_data *plat_dat) >>> @@ -303,7 +307,7 @@ static int stm32mcu_set_mode(struct >>> plat_stmmacenet_data *plat_dat) >>>       dev_dbg(dwmac->dev, "Mode %s", >>> phy_modes(plat_dat->mac_interface)); >>>         return regmap_update_bits(dwmac->regmap, reg, >>> -                 dwmac->ops->syscfg_eth_mask, val << 23); >>> +                 SYSCFG_MCU_ETH_MASK, val << 23); >>>   } >>>     static void stm32_dwmac_clk_disable(struct stm32_dwmac *dwmac, >>> bool suspend) >>> @@ -348,8 +352,15 @@ static int stm32_dwmac_parse_data(struct >>> stm32_dwmac *dwmac, >>>           return PTR_ERR(dwmac->regmap); >>>         err = of_property_read_u32_index(np, "st,syscon", 1, >>> &dwmac->mode_reg); >>> -    if (err) >>> +    if (err) { >>>           dev_err(dev, "Can't get sysconfig mode offset (%d)\n", err); >>> +        return err; >>> +    } >>> + >>> +    dwmac->mode_mask = SYSCFG_MP1_ETH_MASK; >>> +    err = of_property_read_u32_index(np, "st,syscon", 2, >>> &dwmac->mode_mask); >>> +    if (err) >>> +        dev_dbg(dev, "Warning sysconfig register mask not set\n"); >> >> Isn't this an error , so dev_err() ? > No, it is only "warning" information, for MP1 the mask is not needed > (and for backward compatibility is not planned to put mask parameter > mandatory) Should this be an error for anything newer than MP15 then ?