lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 17 Aug 2016 23:19:23 -0500 From: Timur Tabi <timur@...eaurora.org> To: Florian Fainelli <f.fainelli@...il.com>, Al Stone <al.stone@...aro.org>, Rob Herring <robh@...nel.org> Cc: netdev <netdev@...r.kernel.org>, "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>, linux-arm-msm <linux-arm-msm@...r.kernel.org>, Sagar Dharia <sdharia@...eaurora.org>, Shanker Donthineni <shankerd@...eaurora.org>, Vikram Sethi <vikrams@...eaurora.org>, Christopher Covington <cov@...eaurora.org>, Gilad Avidov <gavidov@...eaurora.org>, Andrew Lunn <andrew@...n.ch>, Bjorn Andersson <bjorn.andersson@...aro.org>, Mark Langsdorf <mlangsdo@...hat.com>, "jcm@...hat.com" <jcm@...hat.com>, Andy Gross <agross@...eaurora.org>, David Miller <davem@...emloft.net>, Lino Sanfilippo <LinoSanfilippo@....de>, "Rafael J. Wysocki" <rjw@...ysocki.net>, "Abdulhamid, Harb" <harba@...eaurora.org> Subject: Re: [PATCH] [v7] net: emac: emac gigabit ethernet controller driver Florian Fainelli wrote: > The larger issue is that the emac_sgmii node in the form you posted > is going to be backed by a platform device in Linux while you want a > PHY device with a reg property that describes a MDIO address > (#address-cells = 1, #size-cells = 0). But how do I get the platform device for the emac_sgmii node? If I create an of_device_id ID for it, like this: static const struct of_device_id emac_dt_match[] = { { .compatible = "qcom,fsm9900-emac", }, {} }; static const struct of_device_id emac_sgmii_dt_match[] = { { .compatible = "qcom,fsm9900-emac-sgmii", }, {} }; Then the probe function will be called for qcom,fsm9900-emac-sgmii separately from qcom,fsm9900-emac, which just confuses things. So I can't create emac_sgmii_dt_match. I know this is standard DT stuff, and I used to do a lot of work on DT so maybe I should know this already. But it seems to me that I need to manually create the platform_device for qcom,fsm9900-emac-sgmii. > IIRC the amd xgbe driver mainline had a similar design but still > implemented a PHY device anyway although it may not have been using > Device Tree. It should still be possible to implement a PHY driver > that you manually register and bind to its device_node pointer such > that of_phy_find_device and friends still work. You would do this > from the emac_sgmii platform device driver and parent devices in a > way that satisfy the PHY device driver lifecycle as well. > > Hope this helps. It doesn't, sorry. The emac_sgmii is really just another register block for the driver to program. Creating another PHY driver for it doesn't really make sense. It's not on an MDIO bus. -- Sent by an employee of the Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, hosted by The Linux Foundation.
Powered by blists - more mailing lists