Re: RFC Need advice on reworking gpio-ep93xx.c to DT support

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

 



On Mon, Mar 22, 2021 at 1:19 PM <nikita.shubin@xxxxxxxxxxx> wrote:

> So the work will be split into 2 stages:
> - breaking gpio platform data into pieces, adapting gpio-ep93xx.c
> - adding DT support for gpio-ep93xx.c
>
> Please advise me on this issue.

If that is your preferred way of working then use that, seems OK to me.

What I have done traditionally has been lazier: I just write the specification
for the device tree bindings as the hardware shall be described (noadays
using the YAML syntax) then adapt the driver to probing from that.

Then when all non-DT users are gone I just delete the old code.

During transitions from boardfile to DT we have often taken this
approach:

1. Add a specific DT boardfile
2. Make this boot
3. Add DT support to all drivers
4. Delete the old boardfiles
5. Delete the old platform data handling from the drivers

As you see, this makes the kernel bigger, then shrinks it.
This is what we have usually done: not refactor stuff into the
form it needs for DT support, instead implement DT on the
side and then eventually delete the old non-DT code.

Smoother transitions can work as well, I just never attempted
that, believeing that it is much more work.

Yours,
Linus Walleij



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux