summaryrefslogtreecommitdiff
path: root/src/soc/sifive/fu540
diff options
context:
space:
mode:
authorElyes Haouas <ehaouas@noos.fr>2023-09-09 08:50:01 +0200
committerFelix Held <felix-coreboot@felixheld.de>2023-09-19 13:13:27 +0000
commite53baa6bfff7e3f8962c9e2310e62e28da88c54b (patch)
tree0c676c1071582993c2e75b01163b373bb0e06668 /src/soc/sifive/fu540
parentf0ed2737287a06557c43616aa8e0f69c1c852e39 (diff)
soc/sifive/fu540: Remove space after a cast
Change-Id: I6a64015326c6ec7e14a0465fe081a2cb4606cdc8 Signed-off-by: Elyes Haouas <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/c/coreboot/+/77734 Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/sifive/fu540')
-rw-r--r--src/soc/sifive/fu540/spi.c6
-rw-r--r--src/soc/sifive/fu540/ux00ddr.h6
2 files changed, 6 insertions, 6 deletions
diff --git a/src/soc/sifive/fu540/spi.c b/src/soc/sifive/fu540/spi.c
index 87c59a4716..2fd67b1294 100644
--- a/src/soc/sifive/fu540/spi.c
+++ b/src/soc/sifive/fu540/spi.c
@@ -28,7 +28,7 @@ static void spi_tx(volatile struct spi_ctrl *spictrl, uint8_t in)
);
} while (r < 0);
#else
- while ((int32_t) spictrl->txdata.raw_bits < 0)
+ while ((int32_t)spictrl->txdata.raw_bits < 0)
;
spictrl->txdata.data = in;
#endif
@@ -40,9 +40,9 @@ static void spi_tx(volatile struct spi_ctrl *spictrl, uint8_t in)
static uint8_t spi_rx(volatile struct spi_ctrl *spictrl)
{
int32_t out;
- while ((out = (int32_t) spictrl->rxdata.raw_bits) < 0)
+ while ((out = (int32_t)spictrl->rxdata.raw_bits) < 0)
;
- return (uint8_t) out;
+ return (uint8_t)out;
}
static int spi_claim_bus_(const struct spi_slave *slave)
diff --git a/src/soc/sifive/fu540/ux00ddr.h b/src/soc/sifive/fu540/ux00ddr.h
index d468a8ede7..aebf91a2d4 100644
--- a/src/soc/sifive/fu540/ux00ddr.h
+++ b/src/soc/sifive/fu540/ux00ddr.h
@@ -48,8 +48,8 @@ static inline void phy_reset(volatile uint32_t *ddrphyreg, const uint32_t *physe
}
static inline void ux00ddr_writeregmap(size_t ahbregaddr, const uint32_t *ctlsettings, const uint32_t *physettings) {
- volatile uint32_t *ddrctlreg = (volatile uint32_t *) ahbregaddr;
- volatile uint32_t *ddrphyreg = ((volatile uint32_t *) ahbregaddr) + (0x2000 / sizeof(uint32_t));
+ volatile uint32_t *ddrctlreg = (volatile uint32_t *)ahbregaddr;
+ volatile uint32_t *ddrphyreg = ((volatile uint32_t *)ahbregaddr) + (0x2000 / sizeof(uint32_t));
unsigned int i;
for (i=0;i<=264;i++) {
@@ -102,7 +102,7 @@ static inline void ux00ddr_mask_leveling_completed_interrupt(size_t ahbregaddr)
static inline void ux00ddr_setuprangeprotection(size_t ahbregaddr, size_t end_addr) {
_REG32(209<<2, ahbregaddr) = 0x0;
size_t end_addr_16Kblocks = ((end_addr >> 14) & 0x7FFFFF)-1;
- _REG32(210<<2, ahbregaddr) = ((uint32_t) end_addr_16Kblocks);
+ _REG32(210<<2, ahbregaddr) = ((uint32_t)end_addr_16Kblocks);
_REG32(212<<2, ahbregaddr) = 0x0;
_REG32(214<<2, ahbregaddr) = 0x0;
_REG32(216<<2, ahbregaddr) = 0x0;