--- Log opened Fri Dec 27 00:00:27 2013 | ||
stekern | andresjk: yeah, unfortunately I don't have much time for it nowadays | 05:04 |
---|---|---|
-!- Netsplit *.net <-> *.split quits: Amadiro, enghong, xlro | 07:42 | |
-!- Netsplit over, joins: xlro, Amadiro | 08:05 | |
maxpaln | ok, anyone know anything about the openrisc linux distribution? | 14:21 |
maxpaln | I am trying to debug the ethernet driver issues - it seems Linux is unable to match teh HW to the driver | 14:21 |
maxpaln | but I can't follow how Linux is identifying the HW | 14:21 |
stekern | it's identifying it by using the device tree | 14:22 |
maxpaln | can you point me at the right place in the file system | 14:22 |
maxpaln | I was expecting to see a device ID or a manufacturer/ID or something like that | 14:23 |
maxpaln | that I could use to cross reference against the drivers | 14:23 |
maxpaln | this works on the 'full' installations of redhat and so on- | 14:23 |
maxpaln | I can see things like Intel ... or Reraltek... | 14:24 |
stekern | http://git.openrisc.net/cgit.cgi/jonas/linux/tree/arch/openrisc/boot/dts/or1ksim.dts | 14:24 |
maxpaln | thanks - I see that | 14:24 |
maxpaln | but how does the connection with a particular driver get made? | 14:25 |
stekern | http://git.openrisc.net/cgit.cgi/jonas/linux/tree/drivers/net/ethernet/ethoc.c#n1196 | 14:26 |
stekern | and the other information in the device tree node is used in this function: http://git.openrisc.net/cgit.cgi/jonas/linux/tree/drivers/net/ethernet/ethoc.c#n917 | 14:27 |
maxpaln | ok, this is making a bit more sense | 14:31 |
stekern | as for the PHY devices, I would assume they would automagically be probed with the mdio interface functions provided by the ethernet mac driver | 14:32 |
maxpaln | ok, that makes sense - but how does Linux know which driver to use - | 14:32 |
maxpaln | as in which actual set of values to write to which registers | 14:33 |
maxpaln | I can't seem to follow the link from ethoc/c to one of the set of drivers in 'drivers/net/...' | 14:33 |
maxpaln | I suspect that there are no matches found when Linux boots so the PHY isn't actual setup with anything other than the defaults | 14:34 |
maxpaln | Fopr example, I am looking in marvell.c (./drivers/net/phy/marvell.c) | 14:37 |
maxpaln | the marvell_drivers struct would appear to hold the link to all the various settings that need to be loaded for each PHY etc. | 14:38 |
stekern | mmm, I'm not sure how the PHY probing takes place without digging myself | 14:38 |
maxpaln | ok, well you starting me in the right direction | 14:39 |
stekern | but I would assume it's initiated by this: http://git.openrisc.net/cgit.cgi/jonas/linux/tree/drivers/net/ethernet/ethoc.c#n675 | 14:39 |
maxpaln | hmmm, that';s worth investigating | 14:40 |
stekern | and a wild guess is that it reads the vendor/product id from the standard regs and matches a driver to that | 14:40 |
maxpaln | It could track through to the right place | 14:40 |
maxpaln | I'll do some digging and let you know what I find | 14:41 |
stekern | great! ;) | 14:41 |
--- Log closed Sat Dec 28 00:00:28 2013 |
Generated by irclog2html.py 2.15.2 by Marius Gedminas - find it at mg.pov.lt!