diff options
author | Philipp Hortmann <philipp.g.hortmann@gmail.com> | 2022-04-16 11:00:55 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-04-20 19:45:15 +0300 |
commit | 08bea7da71b34c60b9aca1258a2098fed3bc3ce6 (patch) | |
tree | 437e8380a83d6f0c10ac683c3a922df9a280e4e5 /drivers/staging/vt6655/srom.c | |
parent | bcac7e6eecd746a8f6fc0f992f887ea2d916a937 (diff) | |
download | linux-08bea7da71b34c60b9aca1258a2098fed3bc3ce6.tar.xz |
staging: vt6655: Replace VNSvInPortB with ioread8
Replace macro VNSvInPortB with ioread8. Avoid cast of the return
value is possible with one exception.
The name of macro and the arguments use CamelCase which
is not accepted by checkpatch.pl
Since there are more than one checkpatch issue per line,
more steps are rquired to fix.
Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/fd71797d9d55d53f95c5c4e2df826bf85dd4626a.1650094595.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vt6655/srom.c')
-rw-r--r-- | drivers/staging/vt6655/srom.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/vt6655/srom.c b/drivers/staging/vt6655/srom.c index e26a4baa2590..8786b55161fa 100644 --- a/drivers/staging/vt6655/srom.c +++ b/drivers/staging/vt6655/srom.c @@ -65,7 +65,7 @@ unsigned char SROMbyReadEmbedded(void __iomem *iobase, unsigned char byOrg; byData = 0xFF; - VNSvInPortB(iobase + MAC_REG_I2MCFG, &byOrg); + byOrg = ioread8(iobase + MAC_REG_I2MCFG); /* turn off hardware retry for getting NACK */ VNSvOutPortB(iobase + MAC_REG_I2MCFG, (byOrg & (~I2MCFG_NORETRY))); for (wNoACK = 0; wNoACK < W_MAX_I2CRETRY; wNoACK++) { @@ -76,7 +76,7 @@ unsigned char SROMbyReadEmbedded(void __iomem *iobase, VNSvOutPortB(iobase + MAC_REG_I2MCSR, I2MCSR_EEMR); /* wait DONE be set */ for (wDelay = 0; wDelay < W_MAX_TIMEOUT; wDelay++) { - VNSvInPortB(iobase + MAC_REG_I2MCSR, &byWait); + byWait = ioread8(iobase + MAC_REG_I2MCSR); if (byWait & (I2MCSR_DONE | I2MCSR_NACK)) break; udelay(CB_DELAY_LOOP_WAIT); @@ -86,7 +86,7 @@ unsigned char SROMbyReadEmbedded(void __iomem *iobase, break; } } - VNSvInPortB(iobase + MAC_REG_I2MDIPT, &byData); + byData = ioread8(iobase + MAC_REG_I2MDIPT); VNSvOutPortB(iobase + MAC_REG_I2MCFG, byOrg); return byData; } |