From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752868AbcF2S7h (ORCPT ); Wed, 29 Jun 2016 14:59:37 -0400 Received: from mail-pf0-f182.google.com ([209.85.192.182]:36652 "EHLO mail-pf0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752328AbcF2S7b (ORCPT ); Wed, 29 Jun 2016 14:59:31 -0400 Subject: Re: [RFC 0/7] net: ethernet: bgmac: Add platform device support To: Jon Mason , zajec5@gmail.com References: <1467142484-11161-1-git-send-email-jon.mason@broadcom.com> Cc: davem@davemloft.net, hauke@hauke-m.de, bcm-kernel-feedback-list@broadcom.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org From: Florian Fainelli Message-ID: <577418EA.5090306@gmail.com> Date: Wed, 29 Jun 2016 11:52:26 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.8.0 MIME-Version: 1.0 In-Reply-To: <1467142484-11161-1-git-send-email-jon.mason@broadcom.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/28/2016 12:34 PM, Jon Mason wrote: > I'm sending out this RFC to see if this is the direction the maintainers > would like to go to add support for other, non-bcma iProc SoC's to the > bgmac driver. Specifically, we are interested in adding support for the > NSP, Cygnus, and NS2 families (with more possible down the road). > > To support non-bcma enabled SoCs, we need to add the standard device > tree "platform device" support. Unfortunately, this driver is very > tighly coupled with the bcma bus and much unwinding is needed. I tried > to break this up into a number of patches to make it more obvious what > was being done to add platform device support. I was able to verify > that the bcma code still works using a 53012K board (NS SoC), and that > the platform code works using a 58625K board (NSP SoC). > > It is worth noting that the phy logic present in the driver needs to be > moved to drivers/phy. However, I was not able to fully decouple that > code from the bgmac driver. I was able to move it into a separate C > file, with only 2 function calls needed to create and destroy the mii > bus. Someone with more knowledge of this and HW to test it needs to do > it properly. This would natually dovetail into creating an interface > which the NSP bgmac can use for the external MDIO Phy to properly > connect (instead of using the fixed phy). This looks very good to me, and I just tested this with a BCM58625 w/ b53-srab on top of that, and everything works nicely: Tested-by: Florian Fainelli -- Florian