[U-Boot] [PATCH v4] spi: davinci: Full dm conversion
Adam Ford
aford173 at gmail.com
Tue Aug 7 12:49:29 UTC 2018
On Tue, Aug 7, 2018 at 1:30 AM Jagan Teki <jagan at amarulasolutions.com> wrote:
>
> davinci_spi now support dt along with platform data,
> respective boards need to switch into dm for the same.
>
> Cc: Adam Ford <aford173 at gmail.com>
> Cc: Vitaly Andrianov <vitalya at ti.com>
> Cc: Stefano Babic <sbabic at denx.de>
> Cc: Peter Howard <phoward at gme.net.au>
> Cc: Tom Rini <trini at konsulko.com>
> Signed-off-by: Jagan Teki <jagan at amarulasolutions.com>
> ---
> Changes for v4, v3, v2:
> - rebased to master
>
I reset to origin/master and applied this patch and attempted to build
da850evm_defconfig, but I got build errors.
I confirmed that both DM_SPI and DM_SPI_FLASH are both 'y'
drivers/spi/davinci_spi.c: In function ‘davinci_spi_claim_bus’:
drivers/spi/davinci_spi.c:272:16: error: dereferencing pointer to
incomplete type ‘struct dm_spi_slave_platdata’
if (slave_plat->cs >= ds->num_cs) {
^~
drivers/spi/davinci_spi.c: In function ‘davinci_spi_xfer’:
drivers/spi/davinci_spi.c:345:11: error: dereferencing pointer to
incomplete type ‘struct dm_spi_slave_platdata’
if (slave->cs >= ds->num_cs) {
^~
drivers/spi/davinci_spi.c: At top level:
drivers/spi/davinci_spi.c:388:21: error: variable ‘davinci_spi_ops’
has initializer but incomplete type
static const struct dm_spi_ops davinci_spi_ops = {
^~~~~~~~~~
drivers/spi/davinci_spi.c:389:3: error: ‘const struct dm_spi_ops’ has
no member named ‘claim_bus’
.claim_bus = davinci_spi_claim_bus,
^~~~~~~~~
drivers/spi/davinci_spi.c:389:15: warning: excess elements in struct initializer
.claim_bus = davinci_spi_claim_bus,
^~~~~~~~~~~~~~~~~~~~~
drivers/spi/davinci_spi.c:389:15: note: (near initialization for
‘davinci_spi_ops’)
drivers/spi/davinci_spi.c:390:3: error: ‘const struct dm_spi_ops’ has
no member named ‘release_bus’
.release_bus = davinci_spi_release_bus,
^~~~~~~~~~~
drivers/spi/davinci_spi.c:390:17: warning: excess elements in struct initializer
.release_bus = davinci_spi_release_bus,
^~~~~~~~~~~~~~~~~~~~~~~
drivers/spi/davinci_spi.c:390:17: note: (near initialization for
‘davinci_spi_ops’)
drivers/spi/davinci_spi.c:391:3: error: ‘const struct dm_spi_ops’ has
no member named ‘xfer’
.xfer = davinci_spi_xfer,
^~~~
drivers/spi/davinci_spi.c:391:11: warning: excess elements in struct initializer
.xfer = davinci_spi_xfer,
^~~~~~~~~~~~~~~~
drivers/spi/davinci_spi.c:391:11: note: (near initialization for
‘davinci_spi_ops’)
drivers/spi/davinci_spi.c:392:3: error: ‘const struct dm_spi_ops’ has
no member named ‘set_speed’
.set_speed = davinci_spi_set_speed,
^~~~~~~~~
drivers/spi/davinci_spi.c:392:15: warning: excess elements in struct initializer
.set_speed = davinci_spi_set_speed,
^~~~~~~~~~~~~~~~~~~~~
drivers/spi/davinci_spi.c:392:15: note: (near initialization for
‘davinci_spi_ops’)
drivers/spi/davinci_spi.c:393:3: error: ‘const struct dm_spi_ops’ has
no member named ‘set_mode’
.set_mode = davinci_spi_set_mode,
^~~~~~~~
drivers/spi/davinci_spi.c:393:14: warning: excess elements in struct initializer
.set_mode = davinci_spi_set_mode,
^~~~~~~~~~~~~~~~~~~~
drivers/spi/davinci_spi.c:393:14: note: (near initialization for
‘davinci_spi_ops’)
drivers/spi/davinci_spi.c:388:32: error: storage size of
‘davinci_spi_ops’ isn’t known
static const struct dm_spi_ops davinci_spi_ops = {
^~~~~~~~~~~~~~~
scripts/Makefile.build:278: recipe for target
'spl/drivers/spi/davinci_spi.o' failed
> drivers/spi/Kconfig | 12 +-
> drivers/spi/davinci_spi.c | 289 +++++++------------------
> include/dm/platform_data/spi_davinci.h | 15 ++
> 3 files changed, 97 insertions(+), 219 deletions(-)
> create mode 100644 include/dm/platform_data/spi_davinci.h
>
[snip]
> --
> 2.18.0.321.gffc6fa0e3
>
More information about the U-Boot
mailing list