aboutsummaryrefslogtreecommitdiff
path: root/drivers/pci
diff options
context:
space:
mode:
authorSimon Glass2020-12-03 16:55:23 -0700
committerSimon Glass2020-12-13 16:51:09 -0700
commit8a8d24bdf174851ebb8607f359d54b72e3283b97 (patch)
tree89fe2b9fd0c33209ce154170f9bda61f624dd9cd /drivers/pci
parentb012ff1f1b0d662587dcf8707fe7cbf1c1f35d2f (diff)
dm: treewide: Rename ..._platdata variables to just ..._plat
Try to maintain some consistency between these variables by using _plat as a suffix for them. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/pci')
-rw-r--r--drivers/pci/pci-emul-uclass.c2
-rw-r--r--drivers/pci/pci-uclass.c26
-rw-r--r--drivers/pci/pci_rom.c8
-rw-r--r--drivers/pci/pci_sandbox.c2
-rw-r--r--drivers/pci/pcie_mediatek.c2
5 files changed, 20 insertions, 20 deletions
diff --git a/drivers/pci/pci-emul-uclass.c b/drivers/pci/pci-emul-uclass.c
index f71ba42c389..756d8ad7449 100644
--- a/drivers/pci/pci-emul-uclass.c
+++ b/drivers/pci/pci-emul-uclass.c
@@ -111,7 +111,7 @@ UCLASS_DRIVER(pci_emul) = {
/*
* This uclass is a child of the pci bus. Its plat is not defined here so
- * is defined by its parent, UCLASS_PCI, which uses struct pci_child_platdata.
+ * is defined by its parent, UCLASS_PCI, which uses struct pci_child_plat.
* See per_child_plat_auto in UCLASS_DRIVER(pci).
*/
UCLASS_DRIVER(pci_emul_parent) = {
diff --git a/drivers/pci/pci-uclass.c b/drivers/pci/pci-uclass.c
index e46c59b98ee..9fc13e39e83 100644
--- a/drivers/pci/pci-uclass.c
+++ b/drivers/pci/pci-uclass.c
@@ -49,7 +49,7 @@ struct udevice *pci_get_controller(struct udevice *dev)
pci_dev_t dm_pci_get_bdf(const struct udevice *dev)
{
- struct pci_child_platdata *pplat = dev_get_parent_plat(dev);
+ struct pci_child_plat *pplat = dev_get_parent_plat(dev);
struct udevice *bus = dev->parent;
/*
@@ -136,7 +136,7 @@ int pci_bus_find_devfn(const struct udevice *bus, pci_dev_t find_devfn,
for (device_find_first_child(bus, &dev);
dev;
device_find_next_child(&dev)) {
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
pplat = dev_get_parent_plat(dev);
if (pplat && pplat->devfn == find_devfn) {
@@ -162,7 +162,7 @@ int dm_pci_bus_find_bdf(pci_dev_t bdf, struct udevice **devp)
static int pci_device_matches_ids(struct udevice *dev,
struct pci_device_id *ids)
{
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
int i;
pplat = dev_get_parent_plat(dev);
@@ -218,7 +218,7 @@ static int dm_pci_bus_find_device(struct udevice *bus, unsigned int vendor,
unsigned int device, int *indexp,
struct udevice **devp)
{
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
struct udevice *dev;
for (device_find_first_child(bus, &dev);
@@ -261,7 +261,7 @@ int dm_pci_find_class(uint find_class, int index, struct udevice **devp)
for (pci_find_first_device(&dev);
dev;
pci_find_next_device(&dev)) {
- struct pci_child_platdata *pplat = dev_get_parent_plat(dev);
+ struct pci_child_plat *pplat = dev_get_parent_plat(dev);
if (pplat->class == find_class && !index--) {
*devp = dev;
@@ -524,7 +524,7 @@ static void set_vga_bridge_bits(struct udevice *dev)
int pci_auto_config_devices(struct udevice *bus)
{
struct pci_controller *hose = bus->uclass_priv;
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
unsigned int sub_bus;
struct udevice *dev;
int ret;
@@ -807,7 +807,7 @@ int pci_bind_bus_devices(struct udevice *bus)
PCI_MAX_PCI_FUNCTIONS - 1);
for (bdf = PCI_BDF(bus->seq, 0, 0); bdf <= end;
bdf += PCI_BDF(0, 0, 1)) {
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
struct udevice *dev;
ulong class;
@@ -1080,7 +1080,7 @@ static int pci_uclass_post_probe(struct udevice *bus)
static int pci_uclass_child_post_bind(struct udevice *dev)
{
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
if (!dev_of_valid(dev))
return 0;
@@ -1441,7 +1441,7 @@ pci_addr_t dm_pci_phys_to_bus(struct udevice *dev, phys_addr_t phys_addr,
}
static phys_addr_t dm_pci_map_ea_virt(struct udevice *dev, int ea_off,
- struct pci_child_platdata *pdata)
+ struct pci_child_plat *pdata)
{
phys_addr_t addr = 0;
@@ -1472,7 +1472,7 @@ static phys_addr_t dm_pci_map_ea_virt(struct udevice *dev, int ea_off,
}
static void *dm_pci_map_ea_bar(struct udevice *dev, int bar, int flags,
- int ea_off, struct pci_child_platdata *pdata)
+ int ea_off, struct pci_child_plat *pdata)
{
int ea_cnt, i, entry_size;
int bar_id = (bar - PCI_BASE_ADDRESS_0) >> 2;
@@ -1523,7 +1523,7 @@ static void *dm_pci_map_ea_bar(struct udevice *dev, int bar, int flags,
void *dm_pci_map_bar(struct udevice *dev, int bar, int flags)
{
- struct pci_child_platdata *pdata = dev_get_parent_plat(dev);
+ struct pci_child_plat *pdata = dev_get_parent_plat(dev);
struct udevice *udev = dev;
pci_addr_t pci_bus_addr;
u32 bar_response;
@@ -1725,7 +1725,7 @@ int pci_sriov_init(struct udevice *pdev, int vf_en)
bdf += PCI_BDF(0, 0, vf_offset);
for (vf = 0; vf < num_vfs; vf++) {
- struct pci_child_platdata *pplat;
+ struct pci_child_plat *pplat;
ulong class;
pci_bus_read_config(bus, bdf, PCI_CLASS_DEVICE,
@@ -1797,7 +1797,7 @@ UCLASS_DRIVER(pci) = {
.post_probe = pci_uclass_post_probe,
.child_post_bind = pci_uclass_child_post_bind,
.per_device_auto = sizeof(struct pci_controller),
- .per_child_plat_auto = sizeof(struct pci_child_platdata),
+ .per_child_plat_auto = sizeof(struct pci_child_plat),
};
static const struct dm_pci_ops pci_bridge_ops = {
diff --git a/drivers/pci/pci_rom.c b/drivers/pci/pci_rom.c
index 9c98496d7a3..4a21813a82f 100644
--- a/drivers/pci/pci_rom.c
+++ b/drivers/pci/pci_rom.c
@@ -68,7 +68,7 @@ __weak uint32_t board_map_oprom_vendev(uint32_t vendev)
static int pci_rom_probe(struct udevice *dev, struct pci_rom_header **hdrp)
{
- struct pci_child_platdata *pplat = dev_get_parent_plat(dev);
+ struct pci_child_plat *pplat = dev_get_parent_plat(dev);
struct pci_rom_header *rom_header;
struct pci_rom_data *rom_data;
u16 rom_vendor, rom_device;
@@ -236,7 +236,7 @@ void setup_video(struct screen_info *screen_info)
int dm_pci_run_vga_bios(struct udevice *dev, int (*int15_handler)(void),
int exec_method)
{
- struct pci_child_platdata *pplat = dev_get_parent_plat(dev);
+ struct pci_child_plat *pplat = dev_get_parent_plat(dev);
struct pci_rom_header *rom = NULL, *ram = NULL;
int vesa_mode = -1;
bool emulate, alloced;
@@ -328,7 +328,7 @@ err:
#ifdef CONFIG_DM_VIDEO
int vbe_setup_video_priv(struct vesa_mode_info *vesa,
struct video_priv *uc_priv,
- struct video_uc_platdata *plat)
+ struct video_uc_plat *plat)
{
if (!vesa->x_resolution)
return log_msg_ret("No x resolution", -ENXIO);
@@ -363,7 +363,7 @@ int vbe_setup_video_priv(struct vesa_mode_info *vesa,
int vbe_setup_video(struct udevice *dev, int (*int15_handler)(void))
{
- struct video_uc_platdata *plat = dev_get_uclass_plat(dev);
+ struct video_uc_plat *plat = dev_get_uclass_plat(dev);
struct video_priv *uc_priv = dev_get_uclass_priv(dev);
int ret;
diff --git a/drivers/pci/pci_sandbox.c b/drivers/pci/pci_sandbox.c
index e2924105bd1..ca44d002371 100644
--- a/drivers/pci/pci_sandbox.c
+++ b/drivers/pci/pci_sandbox.c
@@ -132,5 +132,5 @@ U_BOOT_DRIVER(pci_sandbox) = {
/* Attach an emulator if we can */
.child_post_bind = dm_scan_fdt_dev,
- .per_child_plat_auto = sizeof(struct pci_child_platdata),
+ .per_child_plat_auto = sizeof(struct pci_child_plat),
};
diff --git a/drivers/pci/pcie_mediatek.c b/drivers/pci/pcie_mediatek.c
index 41c38ed731b..16a9dbfcb83 100644
--- a/drivers/pci/pcie_mediatek.c
+++ b/drivers/pci/pcie_mediatek.c
@@ -251,7 +251,7 @@ static struct mtk_pcie_port *mtk_pcie_find_port(const struct udevice *bus,
struct mtk_pcie *pcie = dev_get_priv(bus);
struct mtk_pcie_port *port;
struct udevice *dev;
- struct pci_child_platdata *pplat = NULL;
+ struct pci_child_plat *pplat = NULL;
int ret = 0;
if (PCI_BUS(bdf) != 0) {