Skip to content

Commit 359f3d7

Browse files
committed
Merge tag 'mmc-v5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc
Pull MMC and MEMSTICK updates from Ulf Hansson: "MMC core: - Return a proper response in case of an ioctl error - Issue HPI to interrupt BKOPS for eMMC if it timed out - Avoid hogging the CPU while polling for busy - Extend sd8787 pwrseq to support the wilc1000 SDIO - Remove a couple of confusing warning messages - Clarify comment for ->card_busy() host ops MMC host: - dw_mmc: Add data CRC error injection - mmci: De-assert reset during ->probe() - rtsx_pci: Fix long reads when clock is pre-scaled - sdhci: Correct the tuning command handle for PIO mode - sdhci-esdhc-imx: Improve support for auto tuning - sdhci-msm: Add support for the sc7280 - sdhci-of-arasan: Don't auto tune for DDR50 mode for ZynqMP - sdhci-of-arasan: Enable support for auto cmd12 - sdhci-of-arasan: Use 19MHz for SD default speed for ZynqMP for level shifter - usdhi6rol0: Implement the ->card_busy() host ops MEMSTICK: - A couple of minor cleanups" * tag 'mmc-v5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc: (52 commits) mmc: queue: Remove unused parameters(request_queue) mmc: pwrseq: sd8787: fix compilation warning mmc: core: Return correct emmc response in case of ioctl error mmc: sdhci-esdhc-imx: Select the correct mode for auto tuning mmc: sdhci-esdhc-imx: Remove redundant code for manual tuning mmc: core: Issue HPI in case the BKOPS timed out mmc: queue: Match the data type of max_segments mmc: switch from 'pci_' to 'dma_' API memstick: switch from 'pci_' to 'dma_' API memstick: r592: Change the name of the 'pci_driver' structure to be consistent mmc: pwrseq: add wilc1000_sdio dependency for pwrseq_sd8787 mmc: pwrseq: sd8787: add support for wilc1000 dt-bindings: mmc: Extend pwrseq-sd8787 binding for wilc1000 dt-bindings: mmc: fsl-imx-esdhc: change the pinctrl-names rule dt-bindings: mmc: fsl-imx-esdhc: add a new compatible string dt-bindings: mmc: renesas,sdhi: Document RZ/G2L bindings dt-bindings: mmc: renesas,sdhi: Fix dtbs-check warning mmc: core: Update ->card_busy() callback comment mmc: usdhi6rol0: Implement card_busy function mmc: sdhci: Correct the tuning command handle for PIO mode ...
2 parents 8e235ff + a75c956 commit 359f3d7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+647
-374
lines changed

Documentation/devicetree/bindings/mmc/fsl-imx-esdhc.yaml

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ properties:
2929
- fsl,imx53-esdhc
3030
- fsl,imx6q-usdhc
3131
- fsl,imx6sl-usdhc
32+
- fsl,imx6sll-usdhc
3233
- fsl,imx6sx-usdhc
3334
- fsl,imx6ull-usdhc
3435
- fsl,imx7d-usdhc
@@ -115,12 +116,17 @@ properties:
115116
- const: per
116117

117118
pinctrl-names:
118-
minItems: 1
119-
items:
120-
- const: default
121-
- const: state_100mhz
122-
- const: state_200mhz
123-
- const: sleep
119+
oneOf:
120+
- minItems: 3
121+
items:
122+
- const: default
123+
- const: state_100mhz
124+
- const: state_200mhz
125+
- const: sleep
126+
- minItems: 1
127+
items:
128+
- const: default
129+
- const: sleep
124130

125131
required:
126132
- compatible

Documentation/devicetree/bindings/mmc/mmc-pwrseq-sd8787.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ maintainers:
1111

1212
properties:
1313
compatible:
14-
const: mmc-pwrseq-sd8787
14+
enum:
15+
- mmc-pwrseq-sd8787
16+
- mmc-pwrseq-wilc1000
1517

1618
powerdown-gpios:
1719
minItems: 1

Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml

Lines changed: 89 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ title: Renesas SDHI SD/MMC controller
99
maintainers:
1010
- Wolfram Sang <[email protected]>
1111

12-
allOf:
13-
- $ref: "mmc-controller.yaml"
14-
1512
properties:
1613
compatible:
1714
oneOf:
@@ -47,19 +44,20 @@ properties:
4744
- const: renesas,sdhi-mmc-r8a77470 # RZ/G1C (SDHI/MMC IP)
4845
- items:
4946
- enum:
50-
- renesas,sdhi-r8a774a1 # RZ/G2M
51-
- renesas,sdhi-r8a774b1 # RZ/G2N
52-
- renesas,sdhi-r8a774c0 # RZ/G2E
53-
- renesas,sdhi-r8a774e1 # RZ/G2H
54-
- renesas,sdhi-r8a7795 # R-Car H3
55-
- renesas,sdhi-r8a7796 # R-Car M3-W
56-
- renesas,sdhi-r8a77961 # R-Car M3-W+
57-
- renesas,sdhi-r8a77965 # R-Car M3-N
58-
- renesas,sdhi-r8a77970 # R-Car V3M
59-
- renesas,sdhi-r8a77980 # R-Car V3H
60-
- renesas,sdhi-r8a77990 # R-Car E3
61-
- renesas,sdhi-r8a77995 # R-Car D3
62-
- renesas,sdhi-r8a779a0 # R-Car V3U
47+
- renesas,sdhi-r8a774a1 # RZ/G2M
48+
- renesas,sdhi-r8a774b1 # RZ/G2N
49+
- renesas,sdhi-r8a774c0 # RZ/G2E
50+
- renesas,sdhi-r8a774e1 # RZ/G2H
51+
- renesas,sdhi-r8a7795 # R-Car H3
52+
- renesas,sdhi-r8a7796 # R-Car M3-W
53+
- renesas,sdhi-r8a77961 # R-Car M3-W+
54+
- renesas,sdhi-r8a77965 # R-Car M3-N
55+
- renesas,sdhi-r8a77970 # R-Car V3M
56+
- renesas,sdhi-r8a77980 # R-Car V3H
57+
- renesas,sdhi-r8a77990 # R-Car E3
58+
- renesas,sdhi-r8a77995 # R-Car D3
59+
- renesas,sdhi-r8a779a0 # R-Car V3U
60+
- renesas,sdhi-r9a07g044 # RZ/G2{L,LC}
6361
- const: renesas,rcar-gen3-sdhi # R-Car Gen3 or RZ/G2
6462

6563
reg:
@@ -69,15 +67,9 @@ properties:
6967
minItems: 1
7068
maxItems: 3
7169

72-
clocks:
73-
minItems: 1
74-
maxItems: 2
70+
clocks: true
7571

76-
clock-names:
77-
minItems: 1
78-
items:
79-
- const: core
80-
- const: cd
72+
clock-names: true
8173

8274
dmas:
8375
minItems: 4
@@ -104,36 +96,89 @@ properties:
10496
pinctrl-1:
10597
maxItems: 1
10698

107-
pinctrl-names:
108-
minItems: 1
109-
items:
110-
- const: default
111-
- const: state_uhs
99+
pinctrl-names: true
112100

113101
max-frequency: true
114102

103+
allOf:
104+
- $ref: "mmc-controller.yaml"
105+
106+
- if:
107+
properties:
108+
compatible:
109+
contains:
110+
const: renesas,sdhi-r9a07g044
111+
then:
112+
properties:
113+
clocks:
114+
items:
115+
- description: IMCLK, SDHI channel main clock1.
116+
- description: IMCLK2, SDHI channel main clock2. When this clock is
117+
turned off, external SD card detection cannot be
118+
detected.
119+
- description: CLK_HS, SDHI channel High speed clock which operates
120+
4 times that of SDHI channel main clock1.
121+
- description: ACLK, SDHI channel bus clock.
122+
clock-names:
123+
items:
124+
- const: imclk
125+
- const: imclk2
126+
- const: clk_hs
127+
- const: aclk
128+
required:
129+
- clock-names
130+
- resets
131+
else:
132+
properties:
133+
clocks:
134+
minItems: 1
135+
maxItems: 2
136+
clock-names:
137+
minItems: 1
138+
items:
139+
- const: core
140+
- const: cd
141+
142+
- if:
143+
properties:
144+
compatible:
145+
contains:
146+
const: renesas,sdhi-mmc-r8a77470
147+
then:
148+
properties:
149+
pinctrl-names:
150+
items:
151+
- const: state_uhs
152+
else:
153+
properties:
154+
pinctrl-names:
155+
minItems: 1
156+
items:
157+
- const: default
158+
- const: state_uhs
159+
160+
- if:
161+
properties:
162+
compatible:
163+
contains:
164+
enum:
165+
- renesas,sdhi-r7s72100
166+
- renesas,sdhi-r7s9210
167+
then:
168+
required:
169+
- clock-names
170+
description:
171+
The internal card detection logic that exists in these controllers is
172+
sectioned off to be run by a separate second clock source to allow
173+
the main core clock to be turned off to save power.
174+
115175
required:
116176
- compatible
117177
- reg
118178
- interrupts
119179
- clocks
120180
- power-domains
121181

122-
if:
123-
properties:
124-
compatible:
125-
contains:
126-
enum:
127-
- renesas,sdhi-r7s72100
128-
- renesas,sdhi-r7s9210
129-
then:
130-
required:
131-
- clock-names
132-
description:
133-
The internal card detection logic that exists in these controllers is
134-
sectioned off to be run by a separate second clock source to allow
135-
the main core clock to be turned off to save power.
136-
137182
unevaluatedProperties: false
138183

139184
examples:

Documentation/devicetree/bindings/mmc/sdhci-msm.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Required properties:
1919
"qcom,msm8996-sdhci", "qcom,sdhci-msm-v4"
2020
"qcom,qcs404-sdhci", "qcom,sdhci-msm-v5"
2121
"qcom,sc7180-sdhci", "qcom,sdhci-msm-v5";
22+
"qcom,sc7280-sdhci", "qcom,sdhci-msm-v5";
2223
"qcom,sdm845-sdhci", "qcom,sdhci-msm-v5"
2324
"qcom,sdx55-sdhci", "qcom,sdhci-msm-v5";
2425
"qcom,sm8250-sdhci", "qcom,sdhci-msm-v5"

drivers/memstick/core/ms_block.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1105,7 +1105,7 @@ static u16 msb_get_free_block(struct msb_data *msb, int zone)
11051105
dbg_verbose("result of the free blocks scan: pba %d", pba);
11061106

11071107
if (pba == msb->block_count || (msb_get_zone_from_pba(pba)) != zone) {
1108-
pr_err("BUG: cant get a free block");
1108+
pr_err("BUG: can't get a free block");
11091109
msb->read_only = true;
11101110
return MS_BLOCK_INVALID;
11111111
}

drivers/memstick/host/r592.c

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ static int r592_transfer_fifo_dma(struct r592_device *dev)
293293

294294
/* TODO: hidden assumption about nenth beeing always 1 */
295295
sg_count = dma_map_sg(&dev->pci_dev->dev, &dev->req->sg, 1, is_write ?
296-
PCI_DMA_TODEVICE : PCI_DMA_FROMDEVICE);
296+
DMA_TO_DEVICE : DMA_FROM_DEVICE);
297297

298298
if (sg_count != 1 || sg_dma_len(&dev->req->sg) < R592_LFIFO_SIZE) {
299299
message("problem in dma_map_sg");
@@ -310,8 +310,7 @@ static int r592_transfer_fifo_dma(struct r592_device *dev)
310310
}
311311

312312
dma_unmap_sg(&dev->pci_dev->dev, &dev->req->sg, 1, is_write ?
313-
PCI_DMA_TODEVICE : PCI_DMA_FROMDEVICE);
314-
313+
DMA_TO_DEVICE : DMA_FROM_DEVICE);
315314

316315
return dev->dma_error;
317316
}
@@ -877,15 +876,15 @@ static SIMPLE_DEV_PM_OPS(r592_pm_ops, r592_suspend, r592_resume);
877876

878877
MODULE_DEVICE_TABLE(pci, r592_pci_id_tbl);
879878

880-
static struct pci_driver r852_pci_driver = {
879+
static struct pci_driver r592_pci_driver = {
881880
.name = DRV_NAME,
882881
.id_table = r592_pci_id_tbl,
883882
.probe = r592_probe,
884883
.remove = r592_remove,
885884
.driver.pm = &r592_pm_ops,
886885
};
887886

888-
module_pci_driver(r852_pci_driver);
887+
module_pci_driver(r592_pci_driver);
889888

890889
module_param_named(enable_dma, r592_enable_dma, bool, S_IRUGO);
891890
MODULE_PARM_DESC(enable_dma, "Enable usage of the DMA (default)");

drivers/memstick/host/tifm_ms.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -279,8 +279,8 @@ static int tifm_ms_issue_cmd(struct tifm_ms *host)
279279
if (host->use_dma) {
280280
if (1 != tifm_map_sg(sock, &host->req->sg, 1,
281281
host->req->data_dir == READ
282-
? PCI_DMA_FROMDEVICE
283-
: PCI_DMA_TODEVICE)) {
282+
? DMA_FROM_DEVICE
283+
: DMA_TO_DEVICE)) {
284284
host->req->error = -ENOMEM;
285285
return host->req->error;
286286
}
@@ -350,8 +350,8 @@ static void tifm_ms_complete_cmd(struct tifm_ms *host)
350350
if (host->use_dma) {
351351
tifm_unmap_sg(sock, &host->req->sg, 1,
352352
host->req->data_dir == READ
353-
? PCI_DMA_FROMDEVICE
354-
: PCI_DMA_TODEVICE);
353+
? DMA_FROM_DEVICE
354+
: DMA_TO_DEVICE);
355355
}
356356

357357
writel((~TIFM_CTRL_LED) & readl(sock->addr + SOCK_CONTROL),
@@ -607,8 +607,8 @@ static void tifm_ms_remove(struct tifm_dev *sock)
607607
if (host->use_dma)
608608
tifm_unmap_sg(sock, &host->req->sg, 1,
609609
host->req->data_dir == READ
610-
? PCI_DMA_TODEVICE
611-
: PCI_DMA_FROMDEVICE);
610+
? DMA_TO_DEVICE
611+
: DMA_FROM_DEVICE);
612612
host->req->error = -ETIME;
613613

614614
do {

drivers/mmc/core/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ config PWRSEQ_EMMC
1515

1616
config PWRSEQ_SD8787
1717
tristate "HW reset support for SD8787 BT + Wifi module"
18-
depends on OF && (MWIFIEX || BT_MRVL_SDIO || LIBERTAS_SDIO)
18+
depends on OF && (MWIFIEX || BT_MRVL_SDIO || LIBERTAS_SDIO || WILC1000_SDIO)
1919
help
2020
This selects hardware reset support for the SD8787 BT + Wifi
2121
module. By default this option is set to n.

0 commit comments

Comments
 (0)