diff options
author | Simon Glass <sjg@chromium.org> | 2020-12-16 21:20:07 -0700 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2020-12-18 20:32:21 -0700 |
commit | 8b85dfc675f12de8d04126c07f3c796965b990c2 (patch) | |
tree | 9b8d6df956b02734a1b910b0a4c072e1e80b672a /drivers/watchdog | |
parent | 0b2fa98aa5e5dbdac4f5e2b2f67a34cc34dcc6b8 (diff) | |
download | u-boot-8b85dfc675f12de8d04126c07f3c796965b990c2.zip u-boot-8b85dfc675f12de8d04126c07f3c796965b990c2.tar.gz u-boot-8b85dfc675f12de8d04126c07f3c796965b990c2.tar.bz2 |
dm: Avoid accessing seq directly
At present various drivers etc. access the device's 'seq' member directly.
This makes it harder to change the meaning of that member. Change access
to go through a function instead.
The drivers/i2c/lpc32xx_i2c.c file is left unchanged for now.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/watchdog')
-rw-r--r-- | drivers/watchdog/ast_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/at91sam9_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/cdns_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/omap_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/orion_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/sbsa_gwdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/sp805_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/tangier_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/xilinx_tb_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/xilinx_wwdt.c | 2 |
10 files changed, 10 insertions, 10 deletions
diff --git a/drivers/watchdog/ast_wdt.c b/drivers/watchdog/ast_wdt.c index 0b8668d..f7b5a1a 100644 --- a/drivers/watchdog/ast_wdt.c +++ b/drivers/watchdog/ast_wdt.c @@ -113,7 +113,7 @@ static const struct udevice_id ast_wdt_ids[] = { static int ast_wdt_probe(struct udevice *dev) { - debug("%s() wdt%u\n", __func__, dev->seq); + debug("%s() wdt%u\n", __func__, dev_seq(dev)); ast_wdt_stop(dev); return 0; diff --git a/drivers/watchdog/at91sam9_wdt.c b/drivers/watchdog/at91sam9_wdt.c index 10d9974..9e0d89b 100644 --- a/drivers/watchdog/at91sam9_wdt.c +++ b/drivers/watchdog/at91sam9_wdt.c @@ -108,7 +108,7 @@ static int at91_wdt_probe(struct udevice *dev) if (!priv->regs) return -EINVAL; - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/cdns_wdt.c b/drivers/watchdog/cdns_wdt.c index 06de5bd..966d010 100644 --- a/drivers/watchdog/cdns_wdt.c +++ b/drivers/watchdog/cdns_wdt.c @@ -223,7 +223,7 @@ static int cdns_wdt_stop(struct udevice *dev) */ static int cdns_wdt_probe(struct udevice *dev) { - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/omap_wdt.c b/drivers/watchdog/omap_wdt.c index db9a7d7..ca2bc7c 100644 --- a/drivers/watchdog/omap_wdt.c +++ b/drivers/watchdog/omap_wdt.c @@ -242,7 +242,7 @@ static int omap3_wdt_probe(struct udevice *dev) return -EINVAL; priv->wdt_trgr_pattern = 0x1234; - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/orion_wdt.c b/drivers/watchdog/orion_wdt.c index 35e25d4..167af90 100644 --- a/drivers/watchdog/orion_wdt.c +++ b/drivers/watchdog/orion_wdt.c @@ -158,7 +158,7 @@ static int orion_wdt_probe(struct udevice *dev) struct orion_wdt_priv *priv = dev_get_priv(dev); int ret; - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); orion_wdt_stop(dev); ret = clk_get_by_name(dev, "fixed", &priv->clk); diff --git a/drivers/watchdog/sbsa_gwdt.c b/drivers/watchdog/sbsa_gwdt.c index 7538215..df68adb 100644 --- a/drivers/watchdog/sbsa_gwdt.c +++ b/drivers/watchdog/sbsa_gwdt.c @@ -88,7 +88,7 @@ static int sbsa_gwdt_expire_now(struct udevice *dev, ulong flags) static int sbsa_gwdt_probe(struct udevice *dev) { - debug("%s: Probing wdt%u (sbsa-gwdt)\n", __func__, dev->seq); + debug("%s: Probing wdt%u (sbsa-gwdt)\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/sp805_wdt.c b/drivers/watchdog/sp805_wdt.c index 3249220..291aad7 100644 --- a/drivers/watchdog/sp805_wdt.c +++ b/drivers/watchdog/sp805_wdt.c @@ -105,7 +105,7 @@ static int sp805_wdt_expire_now(struct udevice *dev, ulong flags) static int sp805_wdt_probe(struct udevice *dev) { - debug("%s: Probing wdt%u (sp805-wdt)\n", __func__, dev->seq); + debug("%s: Probing wdt%u (sp805-wdt)\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/tangier_wdt.c b/drivers/watchdog/tangier_wdt.c index 358a9b9..bdc6559 100644 --- a/drivers/watchdog/tangier_wdt.c +++ b/drivers/watchdog/tangier_wdt.c @@ -80,7 +80,7 @@ static const struct udevice_id tangier_wdt_ids[] = { static int tangier_wdt_probe(struct udevice *dev) { - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/xilinx_tb_wdt.c b/drivers/watchdog/xilinx_tb_wdt.c index d71ae6c..1687a45 100644 --- a/drivers/watchdog/xilinx_tb_wdt.c +++ b/drivers/watchdog/xilinx_tb_wdt.c @@ -85,7 +85,7 @@ static int xlnx_wdt_start(struct udevice *dev, u64 timeout, ulong flags) static int xlnx_wdt_probe(struct udevice *dev) { - debug("%s: Probing wdt%u\n", __func__, dev->seq); + debug("%s: Probing wdt%u\n", __func__, dev_seq(dev)); return 0; } diff --git a/drivers/watchdog/xilinx_wwdt.c b/drivers/watchdog/xilinx_wwdt.c index 49f2043..9137d87 100644 --- a/drivers/watchdog/xilinx_wwdt.c +++ b/drivers/watchdog/xilinx_wwdt.c @@ -128,7 +128,7 @@ static int xlnx_wwdt_probe(struct udevice *dev) struct xlnx_wwdt_plat *plat = dev_get_plat(dev); struct xlnx_wwdt_priv *wdt = dev_get_priv(dev); - dev_dbg(dev, "%s: Probing wdt%u\n", __func__, dev->seq); + dev_dbg(dev, "%s: Probing wdt%u\n", __func__, dev_seq(dev)); ret = regmap_init_mem(dev_ofnode(dev), &wdt->regs); if (ret) { |