dm: treewide: Rename 'platdata' variables to just 'plat'

We use 'priv' for private data but often use 'platdata' for platform data.
We can't really use 'pdata' since that is ambiguous (it could mean private
or platform data).

Rename some of the latter variables to end with 'plat' for consistency.

Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Simon Glass
2020-12-03 16:55:18 -07:00
parent 41575d8e4c
commit caa4daa2ae
575 changed files with 1633 additions and 1644 deletions

View File

@@ -72,7 +72,7 @@ static int sandbox_serial_probe(struct udevice *dev)
static int sandbox_serial_remove(struct udevice *dev)
{
struct sandbox_serial_platdata *plat = dev->platdata;
struct sandbox_serial_platdata *plat = dev->plat;
if (plat->colour != -1)
output_ansi_reset();
@@ -83,7 +83,7 @@ static int sandbox_serial_remove(struct udevice *dev)
static int sandbox_serial_putc(struct udevice *dev, const char ch)
{
struct sandbox_serial_priv *priv = dev_get_priv(dev);
struct sandbox_serial_platdata *plat = dev->platdata;
struct sandbox_serial_platdata *plat = dev->plat;
/* With of-platdata we don't real the colour correctly, so disable it */
if (!CONFIG_IS_ENABLED(OF_PLATDATA) && priv->start_of_line &&
@@ -203,7 +203,7 @@ static const char * const ansi_colour[] = {
static int sandbox_serial_ofdata_to_platdata(struct udevice *dev)
{
struct sandbox_serial_platdata *plat = dev->platdata;
struct sandbox_serial_platdata *plat = dev->plat;
const char *colour;
int i;
@@ -242,7 +242,7 @@ U_BOOT_DRIVER(sandbox_serial) = {
.id = UCLASS_SERIAL,
.of_match = sandbox_serial_ids,
.ofdata_to_platdata = sandbox_serial_ofdata_to_platdata,
.platdata_auto = sizeof(struct sandbox_serial_platdata),
.plat_auto = sizeof(struct sandbox_serial_platdata),
.priv_auto = sizeof(struct sandbox_serial_priv),
.probe = sandbox_serial_probe,
.remove = sandbox_serial_remove,
@@ -257,6 +257,6 @@ static const struct sandbox_serial_platdata platdata_non_fdt = {
U_BOOT_DEVICE(serial_sandbox_non_fdt) = {
.name = "sandbox_serial",
.platdata = &platdata_non_fdt,
.plat = &platdata_non_fdt,
};
#endif