diff options
author | Elyes Haouas <ehaouas@noos.fr> | 2022-11-18 15:08:13 +0100 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2022-11-23 16:30:58 +0000 |
commit | 977673894ff486af2ff74ba5585ca6039701eb8f (patch) | |
tree | b9719dc91560c7f5fcb791da0c767979e9bb48e0 /src/soc | |
parent | 334772008c547d971e2591ef53bd570c176572ed (diff) |
src/soc/qualcomm: Remove unnecessary space after casts
Change-Id: Ic6c711fe3fad19c24ca4c01f8d0a4bc002f14bd6
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/69807
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc')
-rw-r--r-- | src/soc/qualcomm/common/include/soc/qspi_common.h | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/common/qspi.c | 24 | ||||
-rw-r--r-- | src/soc/qualcomm/common/qupv3_config.c | 4 | ||||
-rw-r--r-- | src/soc/qualcomm/common/usb/qusb_phy.c | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/common/usb/snps_usb_phy.c | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/ipq40xx/blobs_init.c | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/ipq40xx/spi.c | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/ipq806x/blobs_init.c | 4 | ||||
-rw-r--r-- | src/soc/qualcomm/qcs405/spi.c | 2 | ||||
-rw-r--r-- | src/soc/qualcomm/sc7280/pcie.c | 30 |
10 files changed, 37 insertions, 37 deletions
diff --git a/src/soc/qualcomm/common/include/soc/qspi_common.h b/src/soc/qualcomm/common/include/soc/qspi_common.h index 6a1496aed1..a0c8e46812 100644 --- a/src/soc/qualcomm/common/include/soc/qspi_common.h +++ b/src/soc/qualcomm/common/include/soc/qspi_common.h @@ -30,7 +30,7 @@ struct qcom_qspi_regs { }; check_member(qcom_qspi_regs, rd_fifo, 0x50); -static struct qcom_qspi_regs * const qcom_qspi = (void *) QSPI_BASE; +static struct qcom_qspi_regs * const qcom_qspi = (void *)QSPI_BASE; // MSTR_CONFIG register diff --git a/src/soc/qualcomm/common/qspi.c b/src/soc/qualcomm/common/qspi.c index 1c345ccf12..eb0c062a81 100644 --- a/src/soc/qualcomm/common/qspi.c +++ b/src/soc/qualcomm/common/qspi.c @@ -66,7 +66,7 @@ static void dma_transfer_chain(struct cmd_desc *chain) uint32_t mstr_int_status; write32(&qcom_qspi->mstr_int_sts, 0xFFFFFFFF); - write32(&qcom_qspi->next_dma_desc_addr, (uint32_t)(uintptr_t) chain); + write32(&qcom_qspi->next_dma_desc_addr, (uint32_t)(uintptr_t)chain); while (1) { mstr_int_status = read32(&qcom_qspi->mstr_int_sts); @@ -87,15 +87,15 @@ static void flush_chain(void) if (desc->direction == MASTER_READ) { if (desc->bounce_length == 0) dcache_invalidate_by_mva( - (void *)(uintptr_t) desc->data_address, + (void *)(uintptr_t)desc->data_address, desc->length); else { - src = (void *)(uintptr_t) desc->bounce_src; - dst = (void *)(uintptr_t) desc->bounce_dst; + src = (void *)(uintptr_t)desc->bounce_src; + dst = (void *)(uintptr_t)desc->bounce_dst; memcpy(dst, src, desc->bounce_length); } } - desc = (void *)(uintptr_t) desc->next_descriptor; + desc = (void *)(uintptr_t)desc->next_descriptor; } curr_desc_idx = -1; } @@ -112,7 +112,7 @@ static struct cmd_desc *allocate_descriptor(void) index = ++curr_desc_idx; next = &dma->descriptors[index]; - next->data_address = (uint32_t) (uintptr_t) dma->buffers[index]; + next->data_address = (uint32_t)(uintptr_t)dma->buffers[index]; next->next_descriptor = 0; next->direction = MASTER_READ; @@ -131,7 +131,7 @@ static struct cmd_desc *allocate_descriptor(void) next->bounce_length = 0; if (current) - current->next_descriptor = (uint32_t)(uintptr_t) next; + current->next_descriptor = (uint32_t)(uintptr_t)next; return next; } @@ -164,13 +164,13 @@ static void queue_bounce_data(uint8_t *data, uint32_t data_bytes, desc = allocate_descriptor(); desc->direction = write; desc->multi_io_mode = data_mode; - ptr = (void *)(uintptr_t) desc->data_address; + ptr = (void *)(uintptr_t)desc->data_address; if (write) { memcpy(ptr, data, data_bytes); } else { - desc->bounce_src = (uint32_t)(uintptr_t) ptr; - desc->bounce_dst = (uint32_t)(uintptr_t) data; + desc->bounce_src = (uint32_t)(uintptr_t)ptr; + desc->bounce_dst = (uint32_t)(uintptr_t)data; desc->bounce_length = data_bytes; } @@ -185,7 +185,7 @@ static void queue_direct_data(uint8_t *data, uint32_t data_bytes, desc = allocate_descriptor(); desc->direction = write; desc->multi_io_mode = data_mode; - desc->data_address = (uint32_t)(uintptr_t) data; + desc->data_address = (uint32_t)(uintptr_t)data; desc->length = data_bytes; if (write) @@ -291,7 +291,7 @@ static int xfer(enum qspi_mode mode, const void *dout, size_t out_bytes, return -1; } - queue_data((uint8_t *) (out_bytes ? dout : din), + queue_data((uint8_t *)(out_bytes ? dout : din), in_bytes | out_bytes, mode, !!out_bytes); flush_chain(); diff --git a/src/soc/qualcomm/common/qupv3_config.c b/src/soc/qualcomm/common/qupv3_config.c index b243fdded8..919c11bf4e 100644 --- a/src/soc/qualcomm/common/qupv3_config.c +++ b/src/soc/qualcomm/common/qupv3_config.c @@ -188,7 +188,7 @@ void gpi_firmware_load(int addr) struct gsi_fw_hdr *gsi_hdr; struct gsi_fw_iep *fwIep; struct gsi_fw_iram *fwIRam; - struct gsi_regs *regs = (struct gsi_regs *)(uintptr_t) addr; + struct gsi_regs *regs = (struct gsi_regs *)(uintptr_t)addr; static const char * const filename = "fallback/gsi_fw"; /* Assign firmware header base */ @@ -241,7 +241,7 @@ static void qup_common_init(int addr) { struct qupv3_common_reg *qupv3_common; /* HPG section 3.1.2 */ - qupv3_common = (struct qupv3_common_reg *)(uintptr_t) addr; + qupv3_common = (struct qupv3_common_reg *)(uintptr_t)addr; setbits32(&qupv3_common->qupv3_common_cfg_reg, QUPV3_COMMON_CFG_FAST_SWITCH_TO_HIGH_DISABLE_BMSK); diff --git a/src/soc/qualcomm/common/usb/qusb_phy.c b/src/soc/qualcomm/common/usb/qusb_phy.c index 494f7cd3b3..ddb087f0aa 100644 --- a/src/soc/qualcomm/common/usb/qusb_phy.c +++ b/src/soc/qualcomm/common/usb/qusb_phy.c @@ -96,7 +96,7 @@ void hs_usb_phy_init(void *board_data) hs_phy_reg = &qusb_phy; - hs_phy_reg->board_data = (struct usb_board_data *) board_data; + hs_phy_reg->board_data = (struct usb_board_data *)board_data; /* PWR_CTRL: set the power down bit to disable the PHY */ diff --git a/src/soc/qualcomm/common/usb/snps_usb_phy.c b/src/soc/qualcomm/common/usb/snps_usb_phy.c index 1b2d869bc4..d04694b0c7 100644 --- a/src/soc/qualcomm/common/usb/snps_usb_phy.c +++ b/src/soc/qualcomm/common/usb/snps_usb_phy.c @@ -36,7 +36,7 @@ struct hs_usb_phy_reg *hs_phy_reg = (void *)HS_USB_PRIM_PHY_BASE; void hs_usb_phy_init(void *board_data) { struct usb_board_data *override_data = - (struct usb_board_data *) board_data; + (struct usb_board_data *)board_data; clrsetbits32(&hs_phy_reg->cfg0, UTMI_PHY_CMN_CTRL_OVERRIDE_EN, UTMI_PHY_CMN_CTRL_OVERRIDE_EN); diff --git a/src/soc/qualcomm/ipq40xx/blobs_init.c b/src/soc/qualcomm/ipq40xx/blobs_init.c index 60e4f0de04..ef19053692 100644 --- a/src/soc/qualcomm/ipq40xx/blobs_init.c +++ b/src/soc/qualcomm/ipq40xx/blobs_init.c @@ -31,7 +31,7 @@ static void *load_ipq_blob(const char *file_name) (blob_mbn->mbn_total_size > blob_size)) return NULL; - blob_dest = (void *) blob_mbn->mbn_destination; + blob_dest = (void *)blob_mbn->mbn_destination; if (blob_mbn->mbn_destination) { /* Copy the blob to the appropriate memory location. */ diff --git a/src/soc/qualcomm/ipq40xx/spi.c b/src/soc/qualcomm/ipq40xx/spi.c index 0893dfc687..ab8f53016f 100644 --- a/src/soc/qualcomm/ipq40xx/spi.c +++ b/src/soc/qualcomm/ipq40xx/spi.c @@ -591,7 +591,7 @@ static int spi_ctrlr_xfer(const struct spi_slave *slave, const void *dout, write_force_cs(slave, 1); if (dout != NULL) { - ret = blsp_spi_write(ds, txp, (unsigned int) out_bytes); + ret = blsp_spi_write(ds, txp, (unsigned int)out_bytes); if (ret != SUCCESS) goto out; } diff --git a/src/soc/qualcomm/ipq806x/blobs_init.c b/src/soc/qualcomm/ipq806x/blobs_init.c index 15068a59de..851ee814d4 100644 --- a/src/soc/qualcomm/ipq806x/blobs_init.c +++ b/src/soc/qualcomm/ipq806x/blobs_init.c @@ -27,7 +27,7 @@ static void *load_ipq_blob(const char *file_name) (blob_mbn->mbn_total_size > blob_size)) return NULL; - blob_dest = (void *) blob_mbn->mbn_destination; + blob_dest = (void *)blob_mbn->mbn_destination; if (blob_mbn->mbn_destination) { /* Copy the blob to the appropriate memory location. */ memcpy(blob_dest, blob_mbn + 1, blob_mbn->mbn_total_size); @@ -99,7 +99,7 @@ void start_rpm(void) return; } - load_addr = (u32) load_ipq_blob("rpm.mbn"); + load_addr = (u32)load_ipq_blob("rpm.mbn"); if (!load_addr) die("could not find or map RPM code\n"); diff --git a/src/soc/qualcomm/qcs405/spi.c b/src/soc/qualcomm/qcs405/spi.c index e212b84421..48631884c7 100644 --- a/src/soc/qualcomm/qcs405/spi.c +++ b/src/soc/qualcomm/qcs405/spi.c @@ -660,7 +660,7 @@ static int spi_ctrlr_xfer(const struct spi_slave *slave, const void *dout, return ret; if (dout != NULL) { - ret = blsp_spi_write(ds, txp, (unsigned int) out_bytes); + ret = blsp_spi_write(ds, txp, (unsigned int)out_bytes); if (ret != SUCCESS) goto out; } diff --git a/src/soc/qualcomm/sc7280/pcie.c b/src/soc/qualcomm/sc7280/pcie.c index 28d520c486..edc73b0313 100644 --- a/src/soc/qualcomm/sc7280/pcie.c +++ b/src/soc/qualcomm/sc7280/pcie.c @@ -140,13 +140,13 @@ static const struct qcom_qmp_phy_init_tbl sc7280_qmp_gen3x2_pcie_misc_tbl[] = { }; static pcie_cntlr_cfg_t pcie_host = { - .parf = (void *) PCIE1_PCIE_PARF, - .dbi_base = (void *) PCIE1_GEN3X2_PCIE_DBI, - .elbi = (void *) PCIE1_GEN3X2_PCIE_ELBI, - .atu_base = (void *) PCIE1_GEN3X2_DWC_PCIE_DM_IATU, - .cfg_base = (void *) PCIE1_GEN3X2_PCIE_DBI + PCIE_EP_CONF_OFFSET, - .pcie_bcr = (void *) PCIE1_BCR, - .qmp_phy_bcr = (void *) GCC_PCIE_1_PHY_BCR, + .parf = (void *)PCIE1_PCIE_PARF, + .dbi_base = (void *)PCIE1_GEN3X2_PCIE_DBI, + .elbi = (void *)PCIE1_GEN3X2_PCIE_ELBI, + .atu_base = (void *)PCIE1_GEN3X2_DWC_PCIE_DM_IATU, + .cfg_base = (void *)PCIE1_GEN3X2_PCIE_DBI + PCIE_EP_CONF_OFFSET, + .pcie_bcr = (void *)PCIE1_BCR, + .qmp_phy_bcr = (void *)GCC_PCIE_1_PHY_BCR, .lanes = PCIE_3x2_NUM_LANES, .cfg_size = PCIE_EP_CONF_SIZE, .perst = GPIO(2), @@ -160,14 +160,14 @@ static pcie_cntlr_cfg_t pcie_host = { }; static pcie_qmp_phy_cfg_t pcie1_qmp_phy_3x2 = { - .qmp_phy_base = (void *) PCIE_1_QMP_PHY, - .serdes = (void *) PCE1_QPHY_SERDES, - .tx0 = (void *) PCE1_QPHY_TX0, - .rx0 = (void *) PCE1_QPHY_RX0, - .pcs = (void *) PCIE1_QMP_PHY_PCS_COM, - .tx1 = (void *) PCE1_QPHY_TX1, - .rx1 = (void *) PCE1_QPHY_RX1, - .pcs_misc = (void *) PCE1_QPHY_PCS_MISC, + .qmp_phy_base = (void *)PCIE_1_QMP_PHY, + .serdes = (void *)PCE1_QPHY_SERDES, + .tx0 = (void *)PCE1_QPHY_TX0, + .rx0 = (void *)PCE1_QPHY_RX0, + .pcs = (void *)PCIE1_QMP_PHY_PCS_COM, + .tx1 = (void *)PCE1_QPHY_TX1, + .rx1 = (void *)PCE1_QPHY_RX1, + .pcs_misc = (void *)PCE1_QPHY_PCS_MISC, .serdes_tbl = sc7280_qmp_pcie_serdes_tbl, .serdes_tbl_num = ARRAY_SIZE(sc7280_qmp_pcie_serdes_tbl), .tx_tbl = sc7280_qmp_pcie_tx_tbl, |