Re: [PATCH] net: add init-regs for of_phy support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Mon, Feb 17, 2014 at 01:50:28PM +0000, Ben Dooks wrote:
> On 17/02/14 13:44, Mark Rutland wrote:
> > On Mon, Feb 17, 2014 at 01:08:04PM +0000, Ben Dooks wrote:
> >> Add new init-regs field for of_phy nodes and make sure these
> >> get applied when the phy is configured.
> >>
> >> This allows any phy node in an fdt to initialise registers
> >> that may not be set as standard by the driver at initialisation
> >> time, such as LED controls.
> >
> > Why not have a driver for the particular PHY? If it's not standard we
> > don't need to pretend it is. If it has some extensions then the standard
> > compatible string can be a fallback entry in the compatible list.
> 
> I was trying to provide some useful and reasonably generic code
> to setup PHYs without having to add specific arguments to each of
> them.
> 
> I could have added something like ksz8041,led-mode1 = <1> and
> updated the micrel driver.

Perhaps. It depends on precisely what the property is describing.

I think describing the hardware and letting Linux figure out what to do
is better than giving it a set of opaque instructions for it to blindly
follow.

Thanks,
Mark.
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]
  Powered by Linux