Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp757514imm; Thu, 6 Sep 2018 09:38:30 -0700 (PDT) X-Google-Smtp-Source: ANB0VdadZL/ds+g2+RGS/xkoPyxS6+Sr1SqwaV+iHuS04r4U+7MohMPfLb02u0ZSNhtWDS2RWX6f X-Received: by 2002:a63:2354:: with SMTP id u20-v6mr3737118pgm.122.1536251910908; Thu, 06 Sep 2018 09:38:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536251910; cv=none; d=google.com; s=arc-20160816; b=fB7dcGjV+mA5FuYGQZ/jAzeaDbkHKuzMUJrY3CkTKHoFomBSaX0iAYjA9JVOlhFmZs qlrZOgUCiBmyTaps1P0QpBOe2BYgJ5fv/o71PHpC/WQHXV3OA7AykWakGWje0RJYmUww /9tjs//9RbeLn2AXfqVQq5+j3Vq8k9XXZnTUs39RLFg3wjjArGOe5GrIfFLTERLH2u+B WDY3+Z0CXbVYaTQpaIg6H/F7+rdd8TEiuaVT1XNz8glmBdizd+ICPrx8f0Z01e11nFeB lw88GtU6cyo5kqw0du2ZxkYOOrSpOeP0ua2icNDy1OtIbOhb/Qv4xzk01sx1WYGDul85 Rzrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature; bh=yi2igLuJhmIhzzM3bfj6xZSZt3cVTIi8gAYJ45AYoLg=; b=SQXZWoSP3uYCJGw7qExQ3s8BTK0gHQKGLtFrrkXTfdalgTe2q3APJaoy230Il+ad7k 4T317Vgdulsoo5iYyVkRdUR0oNMUMZQ7Fme9Gy7UzSXUZfCCSZ9AWHbogE7zQv6pMVaK cKZFeA4TsR/m1V3SUedHkUjBoT6Z1qzqLTnfJyXdSaAZDcASd4C/qdIVIOKQQlgbd9IA f/RNI32cWM9Ga72gFahVPsqcFY9vhJhdTmiLe6sTTFfa30hW6Z+A1d3bV5VeRC/ESkk+ Jk8/ez+Oxsn4X7wURLwAYaKDa8HRUoQa3swreOgSvEQ3hElhfr4APNFSPuM6IFWmfM91 y3Eg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ettus-com.20150623.gappssmtp.com header.s=20150623 header.b=ntdFo3o6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d8-v6si5778947pfg.115.2018.09.06.09.38.15; Thu, 06 Sep 2018 09:38:30 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ettus-com.20150623.gappssmtp.com header.s=20150623 header.b=ntdFo3o6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728034AbeIFVMn (ORCPT + 99 others); Thu, 6 Sep 2018 17:12:43 -0400 Received: from mail-yb1-f196.google.com ([209.85.219.196]:38191 "EHLO mail-yb1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727723AbeIFVMn (ORCPT ); Thu, 6 Sep 2018 17:12:43 -0400 Received: by mail-yb1-f196.google.com with SMTP id e18-v6so4364081ybq.5 for ; Thu, 06 Sep 2018 09:36:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ettus-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=yi2igLuJhmIhzzM3bfj6xZSZt3cVTIi8gAYJ45AYoLg=; b=ntdFo3o60LRdVLiLO8lkSK2GrXRwh23swy4ujNUlmcJhtrBxnrvLh5FA3ZfJ171G+u mgtRa8idcsnSNtsRiZEJ8o1MunRJAO3jS6A6N+c4v+T3e8/rzeb3sWYtQqBBYFNSY/Jg WhEg+vg87xIfCnrQxQ/djWvrL4Vb0oV8c+P9jfOwqSXP0DISTi410wmyx/1Iv0bSRxe3 GpBEcFSjt8yb3y6O+o5I8FkAHADP0d1DV3KdzSNJD+wBo+z8g13zEGOx6Xm3NjkeCdBO mM2P6S3e5/ubJG79fyzubaI4+FQK3b1V86344BPqrP90R8Op3ZJouJkDgfE0FFHMAvbn 7EeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=yi2igLuJhmIhzzM3bfj6xZSZt3cVTIi8gAYJ45AYoLg=; b=DDujHIsjM9310L1lNNvXLuRwYlZqju2JeqNWGsx/skqEWmS2xfxEHwHcL7nc3ZO5Xn kO+lLn6JPpj9CL6/o+ZSbtz+jXiIyLkLcAG8Z9zcva9cDh03vPzn7FEmj+Z8baDYOJkE ++w40uZTllz4x/98n26qqxD2uyhCDG9zlT4pp9G6VCu0LwnZa7Va6lHljRa7dDktFfK1 yDQtWcl0sn1u2JrOjSDpf6+74qlPYw0FvBOrxJc0wFREjxV5PZ3TdlmEoVGWRyys233r 7ZwUo/N8ki36S7ZzCEp+V9s4NmGNWKQvqxDlA9SWWAoga/goaw18iv7u+Vb5p1ktuaAp SoKg== X-Gm-Message-State: APzg51AxD+zYmIfEGRXi8clIlb5z4nsaoB3QEVxCqvv823/2/YHYFu5d zFf1cn9sDKAR8QWsdFtxJ/duHt3u93SaU9v/qN7PrA== X-Received: by 2002:a25:6c86:: with SMTP id h128-v6mr1995827ybc.354.1536251784502; Thu, 06 Sep 2018 09:36:24 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a0d:e106:0:0:0:0:0 with HTTP; Thu, 6 Sep 2018 09:36:23 -0700 (PDT) In-Reply-To: <20180905123101.GA26739@lunn.ch> References: <20180905001535.19168-1-mdf@kernel.org> <20180905123101.GA26739@lunn.ch> From: Moritz Fischer Date: Thu, 6 Sep 2018 09:36:23 -0700 Message-ID: Subject: Re: [RFC/PATCH] net: nixge: Add PHYLINK support To: Andrew Lunn Cc: Florian Fainelli , netdev@vger.kernel.org, "David S. Miller" , Alex Williams , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Andrew, On Wed, Sep 5, 2018 at 5:31 AM, Andrew Lunn wrote: >> Let me check, it seems there is a register that indicates whether the MAC can >> do either 1G or 10G. I might be able to use that for some of the above, but >> there is not really much in terms of writable registers there. > > Can the MAC do 10 or 100? At the moment, you don't have anything > stopping the PHY anto-neg'ing 10Half. If the MAC does not fully > implement standard Ethernet, you need to tell the PHY driver about > this. That is what the validate call is about. phylink and phylib > knows what the PHY supports. It passes that list to the validate > call. You need to then remove all the modes the MAC does not support. Makes sense, thanks for clarifying. I'll do some more research on this. > >> It's like a DMA engine with a bit of MDIO on the side. Let me see if >> I can make it look less weird with that. If not I'll go with a >> comment explaining that there isn't much to do for the MLO_AN_PHY >> case and the MLO_FIXED cases? > > You again need to configure the MAC to the selected speed, duplex, > etc. If the link is down, you want to disable the MAC. You need this > for both MLO_AN_PHY and MLO_FIXED, because both specify speeds, > duplex, etc. I'll look into it. Moritz