Revert "Merge tag 'dm-pull-20jul20' of git://git.denx.de/u-boot-dm"

This reverts commit 5d3a21df66, reversing
changes made to 56d37f1c56.

Unfortunately this is causing CI failures:
https://travis-ci.org/github/trini/u-boot/jobs/711313649

Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
Tom Rini 2020-07-24 08:42:06 -04:00
parent 5d3a21df66
commit 7208396bbf
319 changed files with 653 additions and 2503 deletions

View file

@ -158,7 +158,7 @@ jobs:
./tools/binman/binman --toolpath ${UBOOT_TRAVIS_BUILD_DIR}/tools test
./tools/buildman/buildman -t
./tools/dtoc/dtoc -t
./tools/patman/patman test
./tools/patman/patman --test
make O=${UBOOT_TRAVIS_BUILD_DIR} testconfig
EOF
cat build.sh

3
.gitignore vendored
View file

@ -92,6 +92,3 @@ GTAGS
*.orig
*~
\#*#
# Python cache
__pycache__

View file

@ -169,7 +169,7 @@ Run binman, buildman, dtoc, Kconfig and patman testsuites:
./tools/binman/binman --toolpath ${UBOOT_TRAVIS_BUILD_DIR}/tools test;
./tools/buildman/buildman -t;
./tools/dtoc/dtoc -t;
./tools/patman/patman test;
./tools/patman/patman --test;
make testconfig
Run tests for Nokia RX-51 (aka N900):

View file

@ -257,7 +257,7 @@ script:
export PYTHONPATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc/pylibfdt";
export PATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc:${PATH}";
./tools/binman/binman --toolpath ${UBOOT_TRAVIS_BUILD_DIR}/tools test &&
./tools/patman/patman test &&
./tools/patman/patman --test &&
./tools/buildman/buildman -t &&
./tools/dtoc/dtoc -t &&
make testconfig;

View file

@ -62,9 +62,4 @@
clocks = <&k3_clks 115 1>;
power-domains = <&k3_pds 115 TI_SCI_PD_EXCLUSIVE>;
};
chipid: chipid@43000014 {
compatible = "ti,am654-chipid";
reg = <0x43000014 0x4>;
};
};

View file

@ -246,7 +246,3 @@
u-boot,dm-spl;
};
};
&chipid {
u-boot,dm-spl;
};

View file

@ -211,7 +211,3 @@
&mcu_fss0_ospi1_pins_default {
u-boot,dm-spl;
};
&chipid {
u-boot,dm-spl;
};

View file

@ -316,9 +316,4 @@
ti,cpts-periodic-outputs = <2>;
};
};
chipid: chipid@43000014 {
compatible = "ti,am654-chipid";
reg = <0x0 0x43000014 0x0 0x4>;
};
};

View file

@ -25,7 +25,6 @@
#include <fs.h>
#include <env.h>
#include <elf.h>
#include <soc.h>
struct ti_sci_handle *get_ti_sci_handle(void)
{
@ -309,27 +308,38 @@ void reset_cpu(ulong ignored)
#if defined(CONFIG_DISPLAY_CPUINFO)
int print_cpuinfo(void)
{
struct udevice *soc;
char name[64];
int ret;
u32 soc, rev;
char *name;
soc = (readl(CTRLMMR_WKUP_JTAG_ID) &
JTAG_ID_PARTNO_MASK) >> JTAG_ID_PARTNO_SHIFT;
rev = (readl(CTRLMMR_WKUP_JTAG_ID) &
JTAG_ID_VARIANT_MASK) >> JTAG_ID_VARIANT_SHIFT;
printf("SoC: ");
switch (soc) {
case AM65X:
name = "AM65x";
break;
case J721E:
name = "J721E";
break;
default:
name = "Unknown Silicon";
};
ret = soc_get(&soc);
if (ret) {
printf("UNKNOWN\n");
return 0;
}
ret = soc_get_family(soc, name, 64);
if (!ret) {
printf("%s ", name);
}
ret = soc_get_revision(soc, name, 64);
if (!ret) {
printf("%s\n", name);
}
printf("%s SR ", name);
switch (rev) {
case REV_PG1_0:
name = "1.0";
break;
case REV_PG2_0:
name = "2.0";
break;
default:
name = "Unknown Revision";
};
printf("%s\n", name);
return 0;
}

View file

@ -8,6 +8,12 @@
#include <asm/armv7_mpu.h>
#define AM65X 0xbb5a
#define J721E 0xbb64
#define REV_PG1_0 0
#define REV_PG2_0 1
struct fwl_data {
const char *name;
u16 fwl_id;

View file

@ -15,6 +15,7 @@
#endif
/* Assuming these addresses and definitions stay common across K3 devices */
#define CTRLMMR_WKUP_JTAG_ID 0x43000014
#define JTAG_ID_VARIANT_SHIFT 28
#define JTAG_ID_VARIANT_MASK (0xf << 28)
#define JTAG_ID_PARTNO_SHIFT 12

View file

@ -114,7 +114,7 @@ static int msm_clk_probe(struct udevice *dev)
{
struct msm_clk_priv *priv = dev_get_priv(dev);
priv->base = dev_read_addr(dev);
priv->base = devfdt_get_addr(dev);
if (priv->base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -56,7 +56,7 @@ static int msm_pinctrl_probe(struct udevice *dev)
{
struct msm_pinctrl_priv *priv = dev_get_priv(dev);
priv->base = dev_read_addr(dev);
priv->base = devfdt_get_addr(dev);
priv->data = (struct msm_pinctrl_data *)dev->driver_data;
return priv->base == FDT_ADDR_T_NONE ? -EINVAL : 0;

View file

@ -79,8 +79,7 @@ int arch_cpu_init_dm(void)
return 0;
}
static int altera_nios2_get_desc(const struct udevice *dev, char *buf,
int size)
static int altera_nios2_get_desc(struct udevice *dev, char *buf, int size)
{
const char *cpu_name = "Nios-II";
@ -91,8 +90,7 @@ static int altera_nios2_get_desc(const struct udevice *dev, char *buf,
return 0;
}
static int altera_nios2_get_info(const struct udevice *dev,
struct cpu_info *info)
static int altera_nios2_get_info(struct udevice *dev, struct cpu_info *info)
{
info->cpu_freq = gd->cpu_clk;
info->features = (1 << CPU_FEAT_L1_CACHE) |
@ -101,7 +99,7 @@ static int altera_nios2_get_info(const struct udevice *dev,
return 0;
}
static int altera_nios2_get_count(const struct udevice *dev)
static int altera_nios2_get_count(struct udevice *dev)
{
return 1;
}

View file

@ -521,10 +521,6 @@
};
};
chipid: chipid {
compatible = "sandbox,soc";
};
i2s: i2s {
compatible = "sandbox,i2s";
#sound-dai-cells = <1>;

View file

@ -9,7 +9,7 @@
#include <asm/cpu_common.h>
#include <asm/cpu_x86.h>
static int apl_get_info(const struct udevice *dev, struct cpu_info *info)
static int apl_get_info(struct udevice *dev, struct cpu_info *info)
{
return cpu_intel_get_info(info, INTEL_BCLK_MHZ);
}

View file

@ -150,7 +150,7 @@ static unsigned long tsc_freq(void)
return bclk * ((platform_info.lo >> 8) & 0xff);
}
static int baytrail_get_info(const struct udevice *dev, struct cpu_info *info)
static int baytrail_get_info(struct udevice *dev, struct cpu_info *info)
{
info->cpu_freq = tsc_freq();
info->features = 1 << CPU_FEAT_L1_CACHE | 1 << CPU_FEAT_MMU;
@ -158,7 +158,7 @@ static int baytrail_get_info(const struct udevice *dev, struct cpu_info *info)
return 0;
}
static int baytrail_get_count(const struct udevice *dev)
static int baytrail_get_count(struct udevice *dev)
{
int ecx = 0;

View file

@ -626,12 +626,12 @@ void cpu_set_power_limits(int power_limit_1_time)
}
}
static int broadwell_get_info(const struct udevice *dev, struct cpu_info *info)
static int broadwell_get_info(struct udevice *dev, struct cpu_info *info)
{
return cpu_intel_get_info(info, INTEL_BCLK_MHZ);
}
static int broadwell_get_count(const struct udevice *dev)
static int broadwell_get_count(struct udevice *dev)
{
return 4;
}

View file

@ -26,7 +26,7 @@ int cpu_x86_bind(struct udevice *dev)
return 0;
}
int cpu_x86_get_vendor(const struct udevice *dev, char *buf, int size)
int cpu_x86_get_vendor(struct udevice *dev, char *buf, int size)
{
const char *vendor = cpu_vendor_name(gd->arch.x86_vendor);
@ -38,7 +38,7 @@ int cpu_x86_get_vendor(const struct udevice *dev, char *buf, int size)
return 0;
}
int cpu_x86_get_desc(const struct udevice *dev, char *buf, int size)
int cpu_x86_get_desc(struct udevice *dev, char *buf, int size)
{
char *ptr;
@ -52,7 +52,7 @@ int cpu_x86_get_desc(const struct udevice *dev, char *buf, int size)
return 0;
}
int cpu_x86_get_count(const struct udevice *dev)
int cpu_x86_get_count(struct udevice *dev)
{
int node, cpu;
int num = 0;

View file

@ -410,15 +410,14 @@ static int model_206ax_init(struct udevice *dev)
return 0;
}
static int model_206ax_get_info(const struct udevice *dev,
struct cpu_info *info)
static int model_206ax_get_info(struct udevice *dev, struct cpu_info *info)
{
return cpu_intel_get_info(info, INTEL_BCLK_MHZ);
return 0;
}
static int model_206ax_get_count(const struct udevice *dev)
static int model_206ax_get_count(struct udevice *dev)
{
return 4;
}

View file

@ -10,7 +10,7 @@
#include <qfw.h>
#include <asm/cpu.h>
int cpu_qemu_get_desc(const struct udevice *dev, char *buf, int size)
int cpu_qemu_get_desc(struct udevice *dev, char *buf, int size)
{
if (size < CPU_MAX_NAME_LEN)
return -ENOSPC;
@ -20,7 +20,7 @@ int cpu_qemu_get_desc(const struct udevice *dev, char *buf, int size)
return 0;
}
static int cpu_qemu_get_count(const struct udevice *dev)
static int cpu_qemu_get_count(struct udevice *dev)
{
return qemu_fwcfg_online_cpus();
}

View file

@ -28,7 +28,7 @@ int cpu_x86_bind(struct udevice *dev);
* @size: Size of string space
* @return: 0 if OK, -ENOSPC if buffer is too small, other -ve on error
*/
int cpu_x86_get_desc(const struct udevice *dev, char *buf, int size);
int cpu_x86_get_desc(struct udevice *dev, char *buf, int size);
/**
* cpu_x86_get_count() - Get the number of cores for an x86 CPU
@ -40,7 +40,7 @@ int cpu_x86_get_desc(const struct udevice *dev, char *buf, int size);
* @return: Number of cores if successful,
* -ENOENT if not "/cpus" entry is found in the device tree
*/
int cpu_x86_get_count(const struct udevice *dev);
int cpu_x86_get_count(struct udevice *dev);
/**
* cpu_x86_get_vendor() - Get a vendor string for an x86 CPU
@ -53,6 +53,6 @@ int cpu_x86_get_count(const struct udevice *dev);
* @size: Size of string space
* @return: 0 if OK, -ENOSPC if buffer is too small, other -ve on error
*/
int cpu_x86_get_vendor(const struct udevice *dev, char *buf, int size);
int cpu_x86_get_vendor(struct udevice *dev, char *buf, int size);
#endif /* _ASM_CPU_X86_H */

View file

@ -33,12 +33,12 @@ int fdtdec_board_setup(const void *fdt_blob)
int dram_init(void)
{
return fdtdec_setup_mem_size_base();
return fdtdec_setup_mem_size_base_fdt(gd->fdt_blob);
}
int dram_init_banksize(void)
{
fdtdec_setup_memory_banksize();
fdtdec_setup_memory_banksize_fdt(gd->fdt_blob);
return 0;
}

View file

@ -65,8 +65,6 @@ int fdt_find_regions(const void *fdt, char * const inc[], int inc_count,
stop_at = offset;
prop = fdt_get_property_by_offset(fdt, offset, NULL);
str = fdt_string(fdt, fdt32_to_cpu(prop->nameoff));
if (!str)
return -FDT_ERR_BADSTRUCTURE;
if (str_in_list(str, exc_prop, exc_prop_count))
include = 0;
break;

View file

@ -816,8 +816,8 @@ static int fdt_del_partitions(void *blob, int parent_offset)
return 0;
}
static int fdt_node_set_part_info(void *blob, int parent_offset,
struct mtd_device *dev)
int fdt_node_set_part_info(void *blob, int parent_offset,
struct mtd_device *dev)
{
struct list_head *pentry;
struct part_info *part;
@ -951,35 +951,27 @@ void fdt_fixup_mtdparts(void *blob, const struct node_info *node_info,
struct mtd_device *dev;
int i, idx;
int noff;
bool inited = false;
if (mtdparts_init() != 0)
return;
for (i = 0; i < node_info_size; i++) {
idx = 0;
noff = -1;
while ((noff = fdt_node_offset_by_compatible(blob, noff,
node_info[i].compat)) >= 0) {
const char *prop;
prop = fdt_getprop(blob, noff, "status", NULL);
if (prop && !strcmp(prop, "disabled"))
continue;
noff = fdt_node_offset_by_compatible(blob, -1,
node_info[i].compat);
while (noff != -FDT_ERR_NOTFOUND) {
debug("%s: %s, mtd dev type %d\n",
fdt_get_name(blob, noff, 0),
node_info[i].compat, node_info[i].type);
if (!inited) {
if (mtdparts_init() != 0)
return;
inited = true;
}
dev = device_find(node_info[i].type, idx++);
if (dev) {
if (fdt_node_set_part_info(blob, noff, dev))
return; /* return on error */
}
/* Jump to next flash node */
noff = fdt_node_offset_by_compatible(blob, noff,
node_info[i].compat);
}
}
}

View file

@ -146,5 +146,3 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0x6162
CONFIG_USB_GADGET_DOWNLOAD=y
CONFIG_FAT_WRITE=y
CONFIG_OF_LIBFDT_OVERLAY=y
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -120,5 +120,3 @@ CONFIG_TIMER=y
CONFIG_SPL_TIMER=y
CONFIG_OMAP_TIMER=y
CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -148,5 +148,3 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0x6162
CONFIG_USB_GADGET_DOWNLOAD=y
CONFIG_FAT_WRITE=y
CONFIG_OF_LIBFDT_OVERLAY=y
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -121,5 +121,3 @@ CONFIG_TIMER=y
CONFIG_SPL_TIMER=y
CONFIG_OMAP_TIMER=y
CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -170,5 +170,3 @@ CONFIG_CADENCE_UFS=y
CONFIG_TI_J721E_UFS=y
CONFIG_FAT_WRITE=y
CONFIG_OF_LIBFDT_OVERLAY=y
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -135,5 +135,3 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0x6163
CONFIG_USB_GADGET_DOWNLOAD=y
CONFIG_FS_EXT4=y
CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -158,5 +158,3 @@ CONFIG_CADENCE_UFS=y
CONFIG_TI_J721E_UFS=y
CONFIG_FAT_WRITE=y
CONFIG_OF_LIBFDT_OVERLAY=y
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -116,5 +116,3 @@ CONFIG_SPL_TIMER=y
CONFIG_OMAP_TIMER=y
CONFIG_FS_EXT4=y
CONFIG_FS_FAT_MAX_CLUSTSIZE=16384
CONFIG_SOC_DEVICE=y
CONFIG_SOC_DEVICE_TI_K3=y

View file

@ -118,7 +118,6 @@ CONFIG_LED_GPIO=y
CONFIG_DM_MAILBOX=y
CONFIG_SANDBOX_MBOX=y
CONFIG_MISC=y
CONFIG_SOC_DEVICE=y
CONFIG_CROS_EC=y
CONFIG_CROS_EC_I2C=y
CONFIG_CROS_EC_LPC=y

View file

@ -139,7 +139,6 @@ CONFIG_LED_GPIO=y
CONFIG_DM_MAILBOX=y
CONFIG_SANDBOX_MBOX=y
CONFIG_MISC=y
CONFIG_SOC_DEVICE=y
CONFIG_CROS_EC=y
CONFIG_CROS_EC_I2C=y
CONFIG_CROS_EC_LPC=y

View file

@ -103,7 +103,6 @@ CONFIG_LED_GPIO=y
CONFIG_DM_MAILBOX=y
CONFIG_SANDBOX_MBOX=y
CONFIG_MISC=y
CONFIG_SOC_DEVICE=y
CONFIG_CROS_EC=y
CONFIG_CROS_EC_I2C=y
CONFIG_CROS_EC_LPC=y

View file

@ -120,7 +120,6 @@ CONFIG_LED_GPIO=y
CONFIG_DM_MAILBOX=y
CONFIG_SANDBOX_MBOX=y
CONFIG_MISC=y
CONFIG_SOC_DEVICE=y
CONFIG_CROS_EC=y
CONFIG_CROS_EC_I2C=y
CONFIG_CROS_EC_LPC=y

View file

@ -19,6 +19,5 @@ Driver Model
pmic-framework
remoteproc-framework
serial-howto
soc-framework
spi-howto
usb-info

View file

@ -1,68 +0,0 @@
.. SPDX-License-Identifier: GPL-2.0+
.. (C) Copyright 2020
.. Texas Instruments Incorporated - http://www.ti.com/
SOC ID Framework
================
Introduction
------------
The driver-model SOC ID framework is able to provide identification
information about a specific SoC in use at runtime, and also provide matching
from a set of identification information from an array. This can be useful for
enabling small quirks in drivers that exist between SoC variants that are
impractical to implement using device tree flags. It is based on UCLASS_SOC.
UCLASS_SOC:
- drivers/soc/soc-uclass.c
- include/soc.h
Configuration:
- CONFIG_SOC_DEVICE is selected by drivers as needed.
Implementing a UCLASS_SOC provider
----------------------------------
The purpose of this framework is to allow UCLASS_SOC provider drivers to supply
identification information about the SoC in use at runtime. The framework
allows drivers to define soc_ops that return identification strings. All
soc_ops need not be defined and can be left as NULL, in which case the
framework will return -ENOSYS and not consider the value when doing an
soc_device_match.
It is left to the driver implementor to decide how the information returned is
determined, but in general the same SOC should always return the same set of
identifying information. Information returned must be in the form of a NULL
terminated string.
See include/soc.h for documentation of the available soc_ops and the intended
meaning of the values that can be returned. See drivers/soc/soc_sandbox.c for
an example UCLASS_SOC provider driver.
Using a UCLASS_SOC driver
-------------------------
The framework provides the ability to retrieve and use the identification
strings directly. It also has the ability to return a match from a list of
different sets of SoC data using soc_device_match.
An array of 'struct soc_attr' can be defined, each containing ID information
for a specific SoC, and when passed to soc_device_match, the identifier values
for each entry in the list will be compared against the values provided by the
UCLASS_SOC driver that is in use. The first entry in the list that matches all
non-null values will be returned by soc_device_match.
An example of various uses of the framework can be found at test/dm/soc.c.
Describing the device using device tree
---------------------------------------
.. code-block:: none
chipid: chipid {
compatible = "sandbox,soc";
};
All that is required in a DT node is a compatible for a corresponding
UCLASS_SOC driver.

View file

@ -167,15 +167,6 @@ Specifies that keys used to sign the FIT are required. This means that they
must be verified for the image to boot. Without this option, the verification
will be optional (useful for testing but not for release).
.TP
.BI "\-t
Update the timestamp in the FIT.
Normally the FIT timestamp is created the first time mkimage is run on a FIT,
when converting the source .its to the binary .fit file. This corresponds to
using the -f flag. But if the original input to mkimage is a binary file
(already compiled) then the timestamp is assumed to have been set previously.
.SH EXAMPLES
List image information:

View file

@ -106,7 +106,7 @@ int exynos_adc_ofdata_to_platdata(struct udevice *dev)
struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev);
struct exynos_adc_priv *priv = dev_get_priv(dev);
priv->regs = dev_read_addr_ptr(dev);
priv->regs = (struct exynos_adc_v2 *)devfdt_get_addr(dev);
if (priv->regs == (struct exynos_adc_v2 *)FDT_ADDR_T_NONE) {
pr_err("Dev: %s - can't get address!", dev->name);
return -ENODATA;

View file

@ -34,7 +34,7 @@ static int dwc_ahci_ofdata_to_platdata(struct udevice *dev)
struct dwc_ahci_priv *priv = dev_get_priv(dev);
fdt_addr_t addr;
priv->base = map_physmem(dev_read_addr(dev), sizeof(void *),
priv->base = map_physmem(devfdt_get_addr(dev), sizeof(void *),
MAP_NOCACHE);
addr = devfdt_get_addr_index(dev, 1);

View file

@ -553,7 +553,7 @@ static int socfpga_clk_ofdata_to_platdata(struct udevice *dev)
struct socfpga_clk_platdata *plat = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;
plat->regs = (void __iomem *)addr;

View file

@ -285,7 +285,7 @@ static int socfpga_a10_clk_probe(struct udevice *dev)
socfpga_a10_handoff_workaround(dev);
if (!fdt_node_check_compatible(fdt, offset, "altr,clk-mgr")) {
plat->regs = dev_read_addr(dev);
plat->regs = devfdt_get_addr(dev);
} else {
pdev = dev_get_parent(dev);
if (!pdev)

View file

@ -95,7 +95,7 @@ static int exynos7420_clk_topc_probe(struct udevice *dev)
fdt_addr_t base;
int ret;
base = dev_read_addr(dev);
base = devfdt_get_addr(dev);
if (base == FDT_ADDR_T_NONE)
return -EINVAL;
@ -149,7 +149,7 @@ static int exynos7420_clk_top0_probe(struct udevice *dev)
if (!priv)
return -EINVAL;
base = dev_read_addr(dev);
base = devfdt_get_addr(dev);
if (base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -283,7 +283,7 @@ int gen2_clk_probe(struct udevice *dev)
u32 cpg_mode;
int ret;
priv->base = dev_read_addr_ptr(dev);
priv->base = (struct gen2_base *)devfdt_get_addr(dev);
if (!priv->base)
return -EINVAL;

View file

@ -359,7 +359,7 @@ int gen3_clk_probe(struct udevice *dev)
u32 cpg_mode;
int ret;
priv->base = dev_read_addr_ptr(dev);
priv->base = (struct gen3_base *)devfdt_get_addr(dev);
if (!priv->base)
return -EINVAL;

View file

@ -253,7 +253,7 @@ static int uniphier_clk_probe(struct udevice *dev)
struct uniphier_clk_priv *priv = dev_get_priv(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev->parent);
addr = devfdt_get_addr(dev->parent);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -82,8 +82,7 @@ static int device_bind_common(struct udevice *parent, const struct driver *drv,
* This is just a 'requested' sequence, and will be
* resolved (and ->seq updated) when the device is probed.
*/
if (CONFIG_IS_ENABLED(OF_CONTROL) &&
!CONFIG_IS_ENABLED(OF_PLATDATA)) {
if (CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)) {
if (uc->uc_drv->name && ofnode_valid(node))
dev_read_alias_seq(dev, &dev->req_seq);
#if CONFIG_IS_ENABLED(OF_PRIOR_STAGE)

View file

@ -379,7 +379,7 @@ static const struct bmips_cpu_hw bmips_cpu_bcm6838 = {
};
/* Generic CPU Ops */
static int bmips_cpu_get_desc(const struct udevice *dev, char *buf, int size)
static int bmips_cpu_get_desc(struct udevice *dev, char *buf, int size)
{
struct bmips_cpu_priv *priv = dev_get_priv(dev);
const struct bmips_cpu_hw *hw = priv->hw;
@ -387,7 +387,7 @@ static int bmips_cpu_get_desc(const struct udevice *dev, char *buf, int size)
return hw->get_cpu_desc(priv, buf, size);
}
static int bmips_cpu_get_info(const struct udevice *dev, struct cpu_info *info)
static int bmips_cpu_get_info(struct udevice *dev, struct cpu_info *info)
{
struct bmips_cpu_priv *priv = dev_get_priv(dev);
const struct bmips_cpu_hw *hw = priv->hw;
@ -400,7 +400,7 @@ static int bmips_cpu_get_info(const struct udevice *dev, struct cpu_info *info)
return 0;
}
static int bmips_cpu_get_count(const struct udevice *dev)
static int bmips_cpu_get_count(struct udevice *dev)
{
struct bmips_cpu_priv *priv = dev_get_priv(dev);
const struct bmips_cpu_hw *hw = priv->hw;
@ -408,7 +408,7 @@ static int bmips_cpu_get_count(const struct udevice *dev)
return hw->get_cpu_count(priv);
}
static int bmips_cpu_get_vendor(const struct udevice *dev, char *buf, int size)
static int bmips_cpu_get_vendor(struct udevice *dev, char *buf, int size)
{
snprintf(buf, size, "Broadcom");

View file

@ -69,7 +69,7 @@ struct udevice *cpu_get_current_dev(void)
return cpu;
}
int cpu_get_desc(const struct udevice *dev, char *buf, int size)
int cpu_get_desc(struct udevice *dev, char *buf, int size)
{
struct cpu_ops *ops = cpu_get_ops(dev);
@ -79,7 +79,7 @@ int cpu_get_desc(const struct udevice *dev, char *buf, int size)
return ops->get_desc(dev, buf, size);
}
int cpu_get_info(const struct udevice *dev, struct cpu_info *info)
int cpu_get_info(struct udevice *dev, struct cpu_info *info)
{
struct cpu_ops *ops = cpu_get_ops(dev);
@ -92,7 +92,7 @@ int cpu_get_info(const struct udevice *dev, struct cpu_info *info)
return ops->get_info(dev, info);
}
int cpu_get_count(const struct udevice *dev)
int cpu_get_count(struct udevice *dev)
{
struct cpu_ops *ops = cpu_get_ops(dev);
@ -102,7 +102,7 @@ int cpu_get_count(const struct udevice *dev)
return ops->get_count(dev);
}
int cpu_get_vendor(const struct udevice *dev, char *buf, int size)
int cpu_get_vendor(struct udevice *dev, char *buf, int size)
{
struct cpu_ops *ops = cpu_get_ops(dev);

View file

@ -8,14 +8,14 @@
#include <dm.h>
#include <cpu.h>
int cpu_sandbox_get_desc(const struct udevice *dev, char *buf, int size)
int cpu_sandbox_get_desc(struct udevice *dev, char *buf, int size)
{
snprintf(buf, size, "LEG Inc. SuperMegaUltraTurbo CPU No. 1");
return 0;
}
int cpu_sandbox_get_info(const struct udevice *dev, struct cpu_info *info)
int cpu_sandbox_get_info(struct udevice *dev, struct cpu_info *info)
{
info->cpu_freq = 42 * 42 * 42 * 42 * 42;
info->features = 0x42424242;
@ -24,12 +24,12 @@ int cpu_sandbox_get_info(const struct udevice *dev, struct cpu_info *info)
return 0;
}
int cpu_sandbox_get_count(const struct udevice *dev)
int cpu_sandbox_get_count(struct udevice *dev)
{
return 42;
}
int cpu_sandbox_get_vendor(const struct udevice *dev, char *buf, int size)
int cpu_sandbox_get_vendor(struct udevice *dev, char *buf, int size)
{
snprintf(buf, size, "Languid Example Garbage Inc.");

View file

@ -100,7 +100,7 @@ static int cpu_imx_get_temp(struct cpu_imx_platdata *plat)
}
#endif
int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size)
int cpu_imx_get_desc(struct udevice *dev, char *buf, int size)
{
struct cpu_imx_platdata *plat = dev_get_platdata(dev);
int ret, temp;
@ -126,7 +126,7 @@ int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size)
return 0;
}
static int cpu_imx_get_info(const struct udevice *dev, struct cpu_info *info)
static int cpu_imx_get_info(struct udevice *dev, struct cpu_info *info)
{
struct cpu_imx_platdata *plat = dev_get_platdata(dev);
@ -135,7 +135,7 @@ static int cpu_imx_get_info(const struct udevice *dev, struct cpu_info *info)
return 0;
}
static int cpu_imx_get_count(const struct udevice *dev)
static int cpu_imx_get_count(struct udevice *dev)
{
ofnode node;
int num = 0;
@ -157,7 +157,7 @@ static int cpu_imx_get_count(const struct udevice *dev)
return num;
}
static int cpu_imx_get_vendor(const struct udevice *dev, char *buf, int size)
static int cpu_imx_get_vendor(struct udevice *dev, char *buf, int size)
{
snprintf(buf, size, "NXP");
return 0;

View file

@ -60,7 +60,7 @@ static inline u32 get_spridr(void)
* determine_type() - Determine CPU family of MPC83xx device
* @dev: CPU device from which to read CPU family from
*/
static inline void determine_family(const struct udevice *dev)
static inline void determine_family(struct udevice *dev)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
/* Upper 12 bits of PARTID field (bits 0-23 in SPRIDR) */
@ -95,7 +95,7 @@ static inline void determine_family(const struct udevice *dev)
* determine_type() - Determine CPU type of MPC83xx device
* @dev: CPU device from which to read CPU type from
*/
static inline void determine_type(const struct udevice *dev)
static inline void determine_type(struct udevice *dev)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
/* Upper 16 bits of PVR (Processor Version Register) */
@ -169,7 +169,7 @@ static inline void determine_type(const struct udevice *dev)
* determine_e300_type() - Determine e300 core type of MPC83xx device
* @dev: CPU device from which to read e300 core type from
*/
static inline void determine_e300_type(const struct udevice *dev)
static inline void determine_e300_type(struct udevice *dev)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
/* Upper 16 bits of PVR (Processor Version Register) */
@ -198,7 +198,7 @@ static inline void determine_e300_type(const struct udevice *dev)
* determine_revid() - Determine revision ID of CPU device
* @dev: CPU device from which to read revision ID
*/
static inline void determine_revid(const struct udevice *dev)
static inline void determine_revid(struct udevice *dev)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
u32 REVID_MAJOR_MASK;
@ -221,7 +221,7 @@ static inline void determine_revid(const struct udevice *dev)
* determine_cpu_data() - Determine CPU information from hardware
* @dev: CPU device from which to read information
*/
static void determine_cpu_data(const struct udevice *dev)
static void determine_cpu_data(struct udevice *dev)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
const u32 E_FLAG_MASK = 0x00010000;
@ -239,7 +239,7 @@ static void determine_cpu_data(const struct udevice *dev)
priv->is_e_processor = !bitfield_extract_by_mask(spridr, E_FLAG_MASK);
}
static int mpc83xx_cpu_get_desc(const struct udevice *dev, char *buf, int size)
static int mpc83xx_cpu_get_desc(struct udevice *dev, char *buf, int size)
{
struct mpc83xx_cpu_priv *priv = dev_get_priv(dev);
struct clk core_clk;
@ -248,14 +248,14 @@ static int mpc83xx_cpu_get_desc(const struct udevice *dev, char *buf, int size)
char csb_freq[32];
int ret;
ret = clk_get_by_index((struct udevice *)dev, 0, &core_clk);
ret = clk_get_by_index(dev, 0, &core_clk);
if (ret) {
debug("%s: Failed to get core clock (err = %d)\n",
dev->name, ret);
return ret;
}
ret = clk_get_by_index((struct udevice *)dev, 1, &csb_clk);
ret = clk_get_by_index(dev, 1, &csb_clk);
if (ret) {
debug("%s: Failed to get CSB clock (err = %d)\n",
dev->name, ret);
@ -278,14 +278,13 @@ static int mpc83xx_cpu_get_desc(const struct udevice *dev, char *buf, int size)
return 0;
}
static int mpc83xx_cpu_get_info(const struct udevice *dev,
struct cpu_info *info)
static int mpc83xx_cpu_get_info(struct udevice *dev, struct cpu_info *info)
{
struct clk clock;
int ret;
ulong freq;
ret = clk_get_by_index((struct udevice *)dev, 0, &clock);
ret = clk_get_by_index(dev, 0, &clock);
if (ret) {
debug("%s: Failed to get core clock (err = %d)\n",
dev->name, ret);
@ -304,14 +303,13 @@ static int mpc83xx_cpu_get_info(const struct udevice *dev,
return 0;
}
static int mpc83xx_cpu_get_count(const struct udevice *dev)
static int mpc83xx_cpu_get_count(struct udevice *dev)
{
/* We have one e300cX core */
return 1;
}
static int mpc83xx_cpu_get_vendor(const struct udevice *dev, char *buf,
int size)
static int mpc83xx_cpu_get_vendor(struct udevice *dev, char *buf, int size)
{
snprintf(buf, size, "NXP");

View file

@ -17,7 +17,7 @@
DECLARE_GLOBAL_DATA_PTR;
static int riscv_cpu_get_desc(const struct udevice *dev, char *buf, int size)
static int riscv_cpu_get_desc(struct udevice *dev, char *buf, int size)
{
const char *isa;
@ -30,7 +30,7 @@ static int riscv_cpu_get_desc(const struct udevice *dev, char *buf, int size)
return 0;
}
static int riscv_cpu_get_info(const struct udevice *dev, struct cpu_info *info)
static int riscv_cpu_get_info(struct udevice *dev, struct cpu_info *info)
{
int ret;
struct clk clk;
@ -39,7 +39,7 @@ static int riscv_cpu_get_info(const struct udevice *dev, struct cpu_info *info)
u32 d_cache_size;
/* First try getting the frequency from the assigned clock */
ret = clk_get_by_index((struct udevice *)dev, 0, &clk);
ret = clk_get_by_index(dev, 0, &clk);
if (!ret) {
ret = clk_get_rate(&clk);
if (!IS_ERR_VALUE(ret))
@ -67,7 +67,7 @@ static int riscv_cpu_get_info(const struct udevice *dev, struct cpu_info *info)
return 0;
}
static int riscv_cpu_get_count(const struct udevice *dev)
static int riscv_cpu_get_count(struct udevice *dev)
{
ofnode node;
int num = 0;

View file

@ -546,7 +546,7 @@ static int ti_edma3_ofdata_to_platdata(struct udevice *dev)
{
struct ti_edma3_priv *priv = dev_get_priv(dev);
priv->base = dev_read_addr(dev);
priv->base = devfdt_get_addr(dev);
return 0;
}

View file

@ -88,7 +88,7 @@ static int altera_pio_ofdata_to_platdata(struct udevice *dev)
{
struct altera_pio_platdata *plat = dev_get_platdata(dev);
plat->regs = map_physmem(dev_read_addr(dev),
plat->regs = map_physmem(devfdt_get_addr(dev),
sizeof(struct altera_pio_regs),
MAP_NOCACHE);
plat->gpio_count = fdtdec_get_int(gd->fdt_blob, dev_of_offset(dev),

View file

@ -299,7 +299,7 @@ static int atmel_pio4_probe(struct udevice *dev)
clk_free(&clk);
addr_base = dev_read_addr(dev);
addr_base = devfdt_get_addr(dev);
if (addr_base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -121,7 +121,7 @@ static int bcm2835_gpio_ofdata_to_platdata(struct udevice *dev)
struct bcm2835_gpio_platdata *plat = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -545,7 +545,7 @@ static int davinci_gpio_ofdata_to_platdata(struct udevice *dev)
struct davinci_gpio_platdata *plat = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -148,7 +148,7 @@ static int rcar_gpio_probe(struct udevice *dev)
int node = dev_of_offset(dev);
int ret;
priv->regs = dev_read_addr_ptr(dev);
priv->regs = (void __iomem *)devfdt_get_addr(dev);
uc_priv->bank_name = dev->name;
ret = fdtdec_parse_phandle_with_args(gd->fdt_blob, node, "gpio-ranges",

View file

@ -112,7 +112,7 @@ static int r7s72100_gpio_probe(struct udevice *dev)
uc_priv->bank_name = dev->name;
dev = dev_get_parent(dev);
addr_base = dev_read_addr(dev);
addr_base = devfdt_get_addr(dev);
if (addr_base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -142,7 +142,7 @@ static int uniphier_gpio_probe(struct udevice *dev)
struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -96,7 +96,7 @@ static int msm_gpio_probe(struct udevice *dev)
{
struct msm_gpio_bank *priv = dev_get_priv(dev);
priv->base = dev_read_addr(dev);
priv->base = devfdt_get_addr(dev);
return priv->base == FDT_ADDR_T_NONE ? -EINVAL : 0;
}

View file

@ -90,7 +90,7 @@ static int mvebu_gpio_probe(struct udevice *dev)
struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
struct mvebu_gpio_priv *priv = dev_get_priv(dev);
priv->regs = dev_read_addr_ptr(dev);
priv->regs = (struct mvebu_gpio_regs *)devfdt_get_addr(dev);
uc_priv->gpio_count = MVEBU_GPIOS_PER_BANK;
priv->name[0] = 'A' + dev->req_seq;
uc_priv->bank_name = priv->name;

View file

@ -300,7 +300,7 @@ static int mxc_gpio_ofdata_to_platdata(struct udevice *dev)
fdt_addr_t addr;
struct mxc_gpio_plat *plat = dev_get_platdata(dev);
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -275,7 +275,7 @@ static int mxs_ofdata_to_platdata(struct udevice *dev)
int node = dev_of_offset(dev);
int ret;
plat->bank = dev_read_addr(dev);
plat->bank = devfdt_get_addr(dev);
if (plat->bank == FDT_ADDR_T_NONE) {
printf("%s: No 'reg' property defined!\n", __func__);
return -EINVAL;

View file

@ -308,7 +308,7 @@ static int omap_gpio_bind(struct udevice *dev)
if (plat)
return 0;
base_addr = dev_read_addr(dev);
base_addr = devfdt_get_addr(dev);
if (base_addr == FDT_ADDR_T_NONE)
return -EINVAL;
@ -347,7 +347,7 @@ static int omap_gpio_ofdata_to_platdata(struct udevice *dev)
struct omap_gpio_platdata *plat = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -256,7 +256,7 @@ static int pm8941_pwrkey_probe(struct udevice *dev)
struct pm8916_gpio_bank *priv = dev_get_priv(dev);
int reg;
priv->pid = dev_read_addr(dev);
priv->pid = devfdt_get_addr(dev);
if (priv->pid == FDT_ADDR_T_NONE)
return log_msg_ret("bad address", -EINVAL);

View file

@ -316,7 +316,7 @@ static int gpio_exynos_bind(struct udevice *parent)
if (plat)
return 0;
base = dev_read_addr_ptr(parent);
base = (struct s5p_gpio_bank *)devfdt_get_addr(parent);
for (node = fdt_first_subnode(blob, dev_of_offset(parent)), bank = base;
node > 0;
node = fdt_next_subnode(blob, node), bank++) {
@ -339,7 +339,7 @@ static int gpio_exynos_bind(struct udevice *parent)
dev_set_of_offset(dev, node);
reg = dev_read_addr(dev);
reg = devfdt_get_addr(dev);
if (reg != FDT_ADDR_T_NONE)
bank = (struct s5p_gpio_bank *)((ulong)base + reg);

View file

@ -159,7 +159,7 @@ static int sifive_gpio_ofdata_to_platdata(struct udevice *dev)
struct sifive_gpio_platdata *plat = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -293,7 +293,7 @@ static int gpio_sunxi_bind(struct udevice *parent)
if (plat)
return 0;
ctlr = dev_read_addr_ptr(parent);
ctlr = (struct sunxi_gpio_reg *)devfdt_get_addr(parent);
for (bank = 0; bank < soc_data->no_banks; bank++) {
struct sunxi_gpio_platdata *plat;
struct udevice *dev;

View file

@ -109,7 +109,7 @@ static int vybrid_gpio_odata_to_platdata(struct udevice *dev)
struct vybrid_gpio_platdata *plat = dev_get_platdata(dev);
fdt_addr_t base_addr;
base_addr = dev_read_addr(dev);
base_addr = devfdt_get_addr(dev);
if (base_addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -225,7 +225,7 @@ static int at91_i2c_ofdata_to_platdata(struct udevice *dev)
struct at91_i2c_bus *bus = dev_get_priv(dev);
int node = dev_of_offset(dev);
bus->regs = dev_read_addr_ptr(dev);
bus->regs = (struct at91_i2c_regs *)devfdt_get_addr(dev);
bus->pdata = (struct at91_i2c_pdata *)dev_get_driver_data(dev);
bus->clock_frequency = fdtdec_get_int(blob, node,
"clock-frequency", 100000);

View file

@ -471,7 +471,7 @@ static int davinci_i2c_probe(struct udevice *dev)
struct i2c_bus *i2c_bus = dev_get_priv(dev);
i2c_bus->id = dev->seq;
i2c_bus->regs = dev_read_addr_ptr(dev);
i2c_bus->regs = (struct i2c_regs *)devfdt_get_addr(dev);
i2c_bus->speed = 100000;
_davinci_i2c_init(i2c_bus->regs, i2c_bus->speed, 0);

View file

@ -525,7 +525,7 @@ static int s3c_i2c_ofdata_to_platdata(struct udevice *dev)
node = dev_of_offset(dev);
i2c_bus->hsregs = dev_read_addr_ptr(dev);
i2c_bus->hsregs = (struct exynos5_hsi2c *)devfdt_get_addr(dev);
i2c_bus->id = pinmux_decode_periph_id(blob, node);

View file

@ -94,7 +94,7 @@ static int uniphier_fi2c_probe(struct udevice *dev)
fdt_addr_t addr;
struct uniphier_fi2c_priv *priv = dev_get_priv(dev);
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -50,7 +50,7 @@ static int uniphier_i2c_probe(struct udevice *dev)
fdt_addr_t addr;
struct uniphier_i2c_priv *priv = dev_get_priv(dev);
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -447,7 +447,7 @@ static int imx_lpi2c_probe(struct udevice *bus)
i2c_bus->driver_data = dev_get_driver_data(bus);
addr = dev_read_addr(bus);
addr = devfdt_get_addr(bus);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -678,7 +678,7 @@ static int iproc_i2c_ofdata_to_platdata(struct udevice *bus)
int node = dev_of_offset(bus);
const void *blob = gd->fdt_blob;
bus_prvdata->base = map_physmem(dev_read_addr(bus),
bus_prvdata->base = map_physmem(devfdt_get_addr(bus),
sizeof(void *),
MAP_NOCACHE);

View file

@ -899,7 +899,7 @@ static int mxc_i2c_probe(struct udevice *bus)
i2c_bus->driver_data = dev_get_driver_data(bus);
addr = dev_read_addr(bus);
addr = devfdt_get_addr(bus);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -1067,7 +1067,7 @@ static int omap_i2c_ofdata_to_platdata(struct udevice *bus)
{
struct omap_i2c_platdata *plat = dev_get_platdata(bus);
plat->base = dev_read_addr(bus);
plat->base = devfdt_get_addr(bus);
plat->speed = dev_read_u32_default(bus, "clock-frequency",
I2C_SPEED_STANDARD_RATE);
plat->ip_rev = dev_get_driver_data(bus);

View file

@ -310,7 +310,7 @@ static int s3c_i2c_ofdata_to_platdata(struct udevice *dev)
node = dev_of_offset(dev);
i2c_bus->regs = dev_read_addr_ptr(dev);
i2c_bus->regs = (struct s3c24x0_i2c *)devfdt_get_addr(dev);
i2c_bus->id = pinmux_decode_periph_id(blob, node);

View file

@ -291,7 +291,7 @@ static int tegra_kbd_probe(struct udevice *dev)
struct input_config *input = &uc_priv->input;
int ret;
priv->kbc = dev_read_addr_ptr(dev);
priv->kbc = (struct kbc_tegra *)devfdt_get_addr(dev);
if ((fdt_addr_t)priv->kbc == FDT_ADDR_T_NONE) {
debug("%s: No keyboard register found\n", __func__);
return -EINVAL;

View file

@ -153,7 +153,7 @@ static int tegra_hsp_probe(struct udevice *dev)
debug("%s(dev=%p)\n", __func__, dev);
thsp->regs = dev_read_addr(dev);
thsp->regs = devfdt_get_addr(dev);
if (thsp->regs == FDT_ADDR_T_NONE)
return -ENODEV;

View file

@ -73,7 +73,7 @@ static int altera_sysid_ofdata_to_platdata(struct udevice *dev)
{
struct altera_sysid_platdata *plat = dev_get_platdata(dev);
plat->regs = map_physmem(dev_read_addr(dev),
plat->regs = map_physmem(devfdt_get_addr(dev),
sizeof(struct altera_sysid_regs),
MAP_NOCACHE);

View file

@ -187,7 +187,7 @@ static int imx8_scu_probe(struct udevice *dev)
debug("%s(dev=%p) (plat=%p)\n", __func__, dev, plat);
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -26,7 +26,7 @@ static int microchip_flexcom_ofdata_to_platdata(struct udevice *dev)
struct microchip_flexcom_platdata *plat = dev_get_platdata(dev);
int ret;
plat->regs = map_physmem(dev_read_addr(dev),
plat->regs = map_physmem(devfdt_get_addr(dev),
sizeof(struct microchip_flexcom_regs),
MAP_NOCACHE);

View file

@ -34,7 +34,7 @@ static int aspeed_sdhci_probe(struct udevice *dev)
goto free;
host->name = dev->name;
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
max_clk = clk_get_rate(&clk);
if (IS_ERR_VALUE(max_clk)) {

View file

@ -69,7 +69,7 @@ static int atmel_sdhci_probe(struct udevice *dev)
return ret;
host->name = dev->name;
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
host->quirks = SDHCI_QUIRK_WAIT_SEND_CMD;
host->bus_width = fdtdec_get_int(gd->fdt_blob, dev_of_offset(dev),

View file

@ -182,7 +182,7 @@ static int bcm2835_sdhci_probe(struct udevice *dev)
int ret;
int clock_id = (int)dev_get_driver_data(dev);
base = dev_read_addr(dev);
base = devfdt_get_addr(dev);
if (base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -766,7 +766,7 @@ static int bcm2835_probe(struct udevice *dev)
upriv->mmc = &plat->mmc;
plat->cfg.name = dev->name;
host->phys_addr = dev_read_addr(dev);
host->phys_addr = devfdt_get_addr(dev);
if (host->phys_addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -62,7 +62,7 @@ static int sdhci_bcmstb_probe(struct udevice *dev)
fdt_addr_t base;
int ret;
base = dev_read_addr(dev);
base = devfdt_get_addr(dev);
if (base == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -395,7 +395,7 @@ static int ftsdc010_mmc_ofdata_to_platdata(struct udevice *dev)
struct ftsdc_priv *priv = dev_get_priv(dev);
struct ftsdc010_chip *chip = &priv->chip;
chip->name = dev->name;
chip->ioaddr = dev_read_addr_ptr(dev);
chip->ioaddr = (void *)devfdt_get_addr(dev);
chip->buswidth = fdtdec_get_int(gd->fdt_blob, dev_of_offset(dev),
"bus-width", 4);
chip->priv = dev;

View file

@ -33,7 +33,7 @@ static int hi6220_dwmmc_ofdata_to_platdata(struct udevice *dev)
struct dwmci_host *host = &priv->host;
host->name = dev->name;
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
host->buswidth = fdtdec_get_int(gd->fdt_blob, dev_of_offset(dev),
"bus-width", 4);

View file

@ -188,7 +188,7 @@ static int iproc_sdhci_probe(struct udevice *dev)
iproc_host->shadow_blk = 0;
host->name = dev->name;
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
host->voltages = MMC_VDD_165_195 |
MMC_VDD_32_33 | MMC_VDD_33_34;
host->quirks = SDHCI_QUIRK_BROKEN_VOLTAGE | SDHCI_QUIRK_BROKEN_R1B;

View file

@ -450,7 +450,7 @@ static int jz_mmc_ofdata_to_platdata(struct udevice *dev)
struct mmc_config *cfg;
int ret;
priv->regs = map_physmem(dev_read_addr(dev), 0x100, MAP_NOCACHE);
priv->regs = map_physmem(devfdt_get_addr(dev), 0x100, MAP_NOCACHE);
cfg = &plat->cfg;
cfg->name = "MSC";

View file

@ -228,7 +228,7 @@ static int meson_mmc_ofdata_to_platdata(struct udevice *dev)
struct meson_mmc_platdata *pdata = dev_get_platdata(dev);
fdt_addr_t addr;
addr = dev_read_addr(dev);
addr = devfdt_get_addr(dev);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;

View file

@ -171,7 +171,7 @@ static int msm_ofdata_to_platdata(struct udevice *dev)
int node = dev_of_offset(dev);
host->name = strdup(dev->name);
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
host->bus_width = fdtdec_get_int(gd->fdt_blob, node, "bus-width", 4);
host->index = fdtdec_get_uint(gd->fdt_blob, node, "index", 0);
priv->base = (void *)fdtdec_get_addr_size_auto_parent(gd->fdt_blob,

View file

@ -112,7 +112,7 @@ static int mv_sdhci_probe(struct udevice *dev)
int ret;
host->name = MVSDH_NAME;
host->ioaddr = dev_read_addr_ptr(dev);
host->ioaddr = (void *)devfdt_get_addr(dev);
host->quirks = SDHCI_QUIRK_32BIT_DMA_ADDR | SDHCI_QUIRK_WAIT_SEND_CMD;
host->mmc = &plat->mmc;
host->mmc->dev = dev;

Some files were not shown because too many files have changed in this diff Show more