OSDN Git Service

pata: ixp4xx: Rewrite to use device tree
authorLinus Walleij <linus.walleij@linaro.org>
Mon, 26 Jul 2021 08:44:45 +0000 (10:44 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 4 Aug 2021 10:20:44 +0000 (12:20 +0200)
commit47adef20e67d657696c953f4b8023017c6005c1b
treecf72c7617e11cf76d8291ff9a84f4cbed899b950
parentbe470496eece679490dda90ebe497493f4c8faf6
pata: ixp4xx: Rewrite to use device tree

This rewrites the IXP4xx CF (IDE) libata driver to use the
device tree exclusively to look up its resources:

- Probe exclusively from the device tree and look up all
  resources from there.
- Allocate a local state container with devres and pass
  this around in .private_data.
- Initialize with struct ata_port_info.
- Use the .set_piomode() callback instead of the much
  wider .set_mode(), we only support PIO after all.
- Bump driver version number from 0.2 to 1.0 to reflect this
  wider change.
- Get a handle on the expansion bus syscon regmap to alter
  the timings on the chip select.
- Put in the more elaborate timing adjustment code for PIO0
  to PIO4 in 8 and 16bit mode from the downstream OpenWrt
  patch.

The board file initialization path and platform data include
is dropped because the board files will be deleted at the same
time as this patch is merged.

The platform data file is not deleted right now so as not to
conflict with the removal of board files.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/ata/pata_ixp4xx_cf.c