mirror of https://github.com/torvalds/linux.git
mmc: loongson2: Unify the function prefixes for loongson2_mmc_pdata
The function prefixes for loongson2_mmc_pdata follow two naming conventions: SoC-based and DMA-based. First, DMA-based prefixes are the preferred choice, as they clearly highlight differences, such as prepare_dma; however, for functions related to SoC, such as reorder_cmd_data, it is agreed to use the smallest SoC name as the fallback prefix, such as ls2k0500. No functional change intended. Suggested-by: Huacai Chen <chenhuacai@loongson.cn> Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn> Reviewed-by: Huacai Chen <chenhuacai@loongson.cn> Link: https://lore.kernel.org/r/20250716064421.3823418-1-zhoubinbin@loongson.cn Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
This commit is contained in:
parent
553d382340
commit
e70821288f
|
|
@ -594,7 +594,7 @@ static struct mmc_host_ops loongson2_mmc_ops = {
|
|||
.ack_sdio_irq = loongson2_mmc_ack_sdio_irq,
|
||||
};
|
||||
|
||||
static const struct regmap_config ls2k1000_mmc_regmap_config = {
|
||||
static const struct regmap_config ls2k0500_mmc_regmap_config = {
|
||||
.reg_bits = 32,
|
||||
.val_bits = 32,
|
||||
.reg_stride = 4,
|
||||
|
|
@ -610,7 +610,7 @@ static int loongson2_reorder_cmd_list[] = { SD_APP_SEND_SCR, SD_APP_SEND_NUM_WR_
|
|||
* However sdio controller will send these datas in usual data format,
|
||||
* so we need to adjust these datas to a protocol consistent byte order.
|
||||
*/
|
||||
static void loongson2_mmc_reorder_cmd_data(struct loongson2_mmc_host *host,
|
||||
static void ls2k0500_mmc_reorder_cmd_data(struct loongson2_mmc_host *host,
|
||||
struct mmc_command *cmd)
|
||||
{
|
||||
struct scatterlist *sg;
|
||||
|
|
@ -704,8 +704,8 @@ static int ls2k0500_mmc_set_external_dma(struct loongson2_mmc_host *host,
|
|||
}
|
||||
|
||||
static struct loongson2_mmc_pdata ls2k0500_mmc_pdata = {
|
||||
.regmap_config = &ls2k1000_mmc_regmap_config,
|
||||
.reorder_cmd_data = loongson2_mmc_reorder_cmd_data,
|
||||
.regmap_config = &ls2k0500_mmc_regmap_config,
|
||||
.reorder_cmd_data = ls2k0500_mmc_reorder_cmd_data,
|
||||
.setting_dma = ls2k0500_mmc_set_external_dma,
|
||||
.prepare_dma = loongson2_mmc_prepare_external_dma,
|
||||
.release_dma = loongson2_mmc_release_external_dma,
|
||||
|
|
@ -736,8 +736,8 @@ static int ls2k1000_mmc_set_external_dma(struct loongson2_mmc_host *host,
|
|||
}
|
||||
|
||||
static struct loongson2_mmc_pdata ls2k1000_mmc_pdata = {
|
||||
.regmap_config = &ls2k1000_mmc_regmap_config,
|
||||
.reorder_cmd_data = loongson2_mmc_reorder_cmd_data,
|
||||
.regmap_config = &ls2k0500_mmc_regmap_config,
|
||||
.reorder_cmd_data = ls2k0500_mmc_reorder_cmd_data,
|
||||
.setting_dma = ls2k1000_mmc_set_external_dma,
|
||||
.prepare_dma = loongson2_mmc_prepare_external_dma,
|
||||
.release_dma = loongson2_mmc_release_external_dma,
|
||||
|
|
@ -838,7 +838,7 @@ static int loongson2_mmc_prepare_internal_dma(struct loongson2_mmc_host *host,
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int loongson2_mmc_set_internal_dma(struct loongson2_mmc_host *host,
|
||||
static int ls2k2000_mmc_set_internal_dma(struct loongson2_mmc_host *host,
|
||||
struct platform_device *pdev)
|
||||
{
|
||||
host->sg_cpu = dma_alloc_coherent(&pdev->dev, PAGE_SIZE,
|
||||
|
|
@ -860,7 +860,7 @@ static struct loongson2_mmc_pdata ls2k2000_mmc_pdata = {
|
|||
.regmap_config = &ls2k2000_mmc_regmap_config,
|
||||
.reorder_cmd_data = ls2k2000_mmc_reorder_cmd_data,
|
||||
.fix_data_timeout = ls2k2000_mmc_fix_data_timeout,
|
||||
.setting_dma = loongson2_mmc_set_internal_dma,
|
||||
.setting_dma = ls2k2000_mmc_set_internal_dma,
|
||||
.prepare_dma = loongson2_mmc_prepare_internal_dma,
|
||||
.release_dma = loongson2_mmc_release_internal_dma,
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in New Issue