From: Ahmad Fatoum <ahmad@a3f.at>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <ahmad@a3f.at>
Subject: [PATCH] fixup! spi: add litex spiflash driver
Date: Mon, 23 Aug 2021 13:57:51 +0200 [thread overview]
Message-ID: <20210823115751.140020-1-ahmad@a3f.at> (raw)
In-Reply-To: <20210817101104.114945-6-antonynpavlov@gmail.com>
bitio.h checks for a setbits macro and would define its own if none was
defined. This means setbits can't be used as symbol name later. Fix
this.
Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
---
drivers/spi/litex_spiflash.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/spi/litex_spiflash.c b/drivers/spi/litex_spiflash.c
index 26ef207699eb..6701e9866a13 100644
--- a/drivers/spi/litex_spiflash.c
+++ b/drivers/spi/litex_spiflash.c
@@ -35,7 +35,7 @@ static inline void litex_spiflash_spi_wr(struct litex_spiflash_spi *sp, u32 val,
writel(val, sp->regs + reg);
}
-static inline void setbits(struct litex_spiflash_spi *sp, int bits, int on)
+static inline void litex_spiflash_setbits(struct litex_spiflash_spi *sp, int bits, int on)
{
/*
* We are the only user of SCSPTR so no locking is required.
@@ -62,7 +62,7 @@ static inline void setsck(struct spi_device *spi, int on)
{
struct litex_spiflash_spi *sc = litex_spiflash_spidev_to_sp(spi);
- setbits(sc, SPIFLASH_BB_CLK, on);
+ litex_spiflash_setbits(sc, SPIFLASH_BB_CLK, on);
}
static inline void setmosi(struct spi_device *spi, int on)
@@ -70,14 +70,14 @@ static inline void setmosi(struct spi_device *spi, int on)
struct litex_spiflash_spi *sc = litex_spiflash_spidev_to_sp(spi);
sc->val &= ~SPIFLASH_BB_DIR;
- setbits(sc, SPIFLASH_BB_MOSI, on);
+ litex_spiflash_setbits(sc, SPIFLASH_BB_MOSI, on);
}
static inline u32 getmiso(struct spi_device *spi)
{
struct litex_spiflash_spi *sc = litex_spiflash_spidev_to_sp(spi);
- setbits(sc, SPIFLASH_BB_DIR, 1);
+ litex_spiflash_setbits(sc, SPIFLASH_BB_DIR, 1);
return !!((litex_spiflash_spi_rr(sc, SPIFLASH_MISO) & 1));
}
@@ -87,7 +87,7 @@ static inline u32 getmiso(struct spi_device *spi)
static inline void litex_spiflash_spi_chipselect(struct litex_spiflash_spi *sc, int on)
{
- setbits(sc, SPIFLASH_BB_CSN, on);
+ litex_spiflash_setbits(sc, SPIFLASH_BB_CSN, on);
}
static int litex_spiflash_spi_setup(struct spi_device *spi)
--
2.33.0
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2021-08-23 11:59 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-17 10:10 [PATCH RESEND v4 0/8] RISC-V: add LiteX SoC support Antony Pavlov
2021-08-17 10:10 ` [PATCH RESEND v4 1/8] clocksource: timer-riscv: select CSR from device tree Antony Pavlov
2021-08-23 12:08 ` Ahmad Fatoum
2021-08-31 4:07 ` Antony Pavlov
2021-10-01 10:12 ` Ahmad Fatoum
2021-08-17 10:10 ` [PATCH RESEND v4 2/8] serial: add litex UART driver Antony Pavlov
2021-08-23 11:58 ` Ahmad Fatoum
2021-08-17 10:10 ` [PATCH RESEND v4 3/8] console: support set baudrate for fixed baudrate drivers Antony Pavlov
2021-08-23 12:01 ` Ahmad Fatoum
2021-08-17 10:11 ` [PATCH RESEND v4 4/8] gpio: add driver for 74xx-ICs with MMIO access Antony Pavlov
2021-10-01 10:13 ` Ahmad Fatoum
2021-08-17 10:11 ` [PATCH RESEND v4 5/8] spi: add litex spiflash driver Antony Pavlov
2021-08-23 11:57 ` Ahmad Fatoum [this message]
2021-10-01 10:13 ` Ahmad Fatoum
2021-08-17 10:11 ` [PATCH RESEND v4 6/8] net: add LiteEth driver Antony Pavlov
2021-10-01 10:14 ` Ahmad Fatoum
2021-08-17 10:11 ` [PATCH RESEND v4 7/8] RISC-V: add LiteX SoC and linux-on-litex-vexriscv support Antony Pavlov
2021-08-23 12:06 ` Ahmad Fatoum
2021-08-31 4:38 ` Antony Pavlov
2021-10-01 10:21 ` Ahmad Fatoum
2021-08-17 10:11 ` [PATCH RESEND v4 8/8] RISC-V: add litex_linux_defconfig Antony Pavlov
2021-10-01 10:18 ` Ahmad Fatoum
2021-10-04 12:02 ` [PATCH RESEND v4 0/8] RISC-V: add LiteX SoC support Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210823115751.140020-1-ahmad@a3f.at \
--to=ahmad@a3f.at \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox