Skip to content

Commit 1546cd4

Browse files
committed
Merge tag 'ata-6.5-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata
Pull ata updates from Damien Le Moal: - Add support for the .remove_new callback to the ata_platform code to simplify device removal interface (Uwe) - Code simplification in ata_dev_revalidate() (Yahu) - Fix code indentation and coding style in the pata_parport protocol modules to avoid warnings from static code analyzers (me) - Clarify ata_eh_qc_retry() behavior with better comments (Niklas) - Simplify and improve ata_change_queue_depth() behavior to have a consistent behavior between libsas managed devices and libata managed devices (e.g. AHCI connected devices) (me) - Cleanup libata-scsi and libata-eh code to use the ata_ncq_enabled() and ata_ncq_supported() helpers instead of open coding flags tests (me) - Cleanup ahci_reset_controller() code (me) - Change the pata_octeon_cf and sata_svw drivers to use of_property_read_reg() to simplify the code (Rob, me) - Remove unnecessary include files from ahci_octeon driver (me) - Modify the DesignWare ahci dt bindings to add support for the Rockchip RK3588 AHCI (Sebastian) * tag 'ata-6.5-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata: (29 commits) dt-bindings: phy: rockchip: rk3588 has two reset lines dt-bindings: ata: dwc-ahci: add Rockchip RK3588 dt-bindings: ata: dwc-ahci: add PHY clocks ata: ahci_octeon: Remove unnecessary include ata: pata_octeon_cf: Add missing header include ata: ahci: Cleanup ahci_reset_controller() ata: Use of_property_read_reg() to parse "reg" ata: libata-scsi: Use ata_ncq_supported in ata_scsi_dev_config() ata: libata-eh: Use ata_ncq_enabled() in ata_eh_speed_down() ata: libata-sata: Improve ata_change_queue_depth() ata: libata-sata: Simplify ata_change_queue_depth() ata: libata-eh: Clarify ata_eh_qc_retry() behavior at call site ata: pata_parport: Fix on26 module code indentation and style ata: pata_parport: Fix on20 module code indentation and style ata: pata_parport: Fix ktti module code indentation and style ata: pata_parport: Fix kbic module code indentation and style ata: pata_parport: Fix friq module code indentation and style ata: pata_parport: Fix fit3 module code indentation and style ata: pata_parport: Fix fit2 module code indentation and style ata: pata_parport: Fix epia module code indentation and style ...
2 parents b30d7a7 + fd3ac6e commit 1546cd4

Some content is hidden

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

48 files changed

+2317
-1927
lines changed
Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/ata/rockchip,dwc-ahci.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Synopsys DWC AHCI SATA controller for Rockchip devices
8+
9+
maintainers:
10+
- Serge Semin <fancer.lancer@gmail.com>
11+
12+
description:
13+
This document defines device tree bindings for the Synopsys DWC
14+
implementation of the AHCI SATA controller found in Rockchip
15+
devices.
16+
17+
select:
18+
properties:
19+
compatible:
20+
contains:
21+
enum:
22+
- rockchip,rk3568-dwc-ahci
23+
- rockchip,rk3588-dwc-ahci
24+
required:
25+
- compatible
26+
27+
properties:
28+
compatible:
29+
items:
30+
- enum:
31+
- rockchip,rk3568-dwc-ahci
32+
- rockchip,rk3588-dwc-ahci
33+
- const: snps,dwc-ahci
34+
35+
ports-implemented:
36+
const: 1
37+
38+
sata-port@0:
39+
$ref: /schemas/ata/snps,dwc-ahci-common.yaml#/$defs/dwc-ahci-port
40+
41+
properties:
42+
reg:
43+
const: 0
44+
45+
unevaluatedProperties: false
46+
47+
patternProperties:
48+
"^sata-port@[1-9a-e]$": false
49+
50+
required:
51+
- compatible
52+
- reg
53+
- interrupts
54+
- clocks
55+
- clock-names
56+
- ports-implemented
57+
58+
allOf:
59+
- $ref: snps,dwc-ahci-common.yaml#
60+
- if:
61+
properties:
62+
compatible:
63+
contains:
64+
enum:
65+
- rockchip,rk3588-dwc-ahci
66+
then:
67+
properties:
68+
clocks:
69+
maxItems: 5
70+
clock-names:
71+
items:
72+
- const: sata
73+
- const: pmalive
74+
- const: rxoob
75+
- const: ref
76+
- const: asic
77+
- if:
78+
properties:
79+
compatible:
80+
contains:
81+
enum:
82+
- rockchip,rk3568-dwc-ahci
83+
then:
84+
properties:
85+
clocks:
86+
maxItems: 3
87+
clock-names:
88+
items:
89+
- const: sata
90+
- const: pmalive
91+
- const: rxoob
92+
93+
unevaluatedProperties: false
94+
95+
examples:
96+
- |
97+
#include <dt-bindings/clock/rockchip,rk3588-cru.h>
98+
#include <dt-bindings/interrupt-controller/arm-gic.h>
99+
#include <dt-bindings/ata/ahci.h>
100+
#include <dt-bindings/phy/phy.h>
101+
102+
sata@fe210000 {
103+
compatible = "rockchip,rk3588-dwc-ahci", "snps,dwc-ahci";
104+
reg = <0xfe210000 0x1000>;
105+
clocks = <&cru ACLK_SATA0>, <&cru CLK_PMALIVE0>,
106+
<&cru CLK_RXOOB0>, <&cru CLK_PIPEPHY0_REF>,
107+
<&cru CLK_PIPEPHY0_PIPE_ASIC_G>;
108+
clock-names = "sata", "pmalive", "rxoob", "ref", "asic";
109+
interrupts = <GIC_SPI 273 IRQ_TYPE_LEVEL_HIGH 0>;
110+
ports-implemented = <0x1>;
111+
#address-cells = <1>;
112+
#size-cells = <0>;
113+
114+
sata-port@0 {
115+
reg = <0>;
116+
hba-port-cap = <HBA_PORT_FBSCP>;
117+
phys = <&combphy0_ps PHY_TYPE_SATA>;
118+
phy-names = "sata-phy";
119+
snps,rx-ts-max = <32>;
120+
snps,tx-ts-max = <32>;
121+
};
122+
};
123+
124+
...

Documentation/devicetree/bindings/ata/snps,dwc-ahci-common.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ properties:
3131
PM-alive clock, RxOOB detection clock, embedded PHYs reference (Rx/Tx)
3232
clock, etc.
3333
minItems: 1
34-
maxItems: 4
34+
maxItems: 6
3535

3636
clock-names:
3737
minItems: 1
38-
maxItems: 4
38+
maxItems: 6
3939
items:
4040
oneOf:
4141
- description: Application APB/AHB/AXI BIU clock
@@ -48,6 +48,10 @@ properties:
4848
const: pmalive
4949
- description: RxOOB detection clock
5050
const: rxoob
51+
- description: PHY Transmit Clock
52+
const: asic
53+
- description: PHY Receive Clock
54+
const: rbc
5155
- description: SATA Ports reference clock
5256
const: ref
5357

Documentation/devicetree/bindings/ata/snps,dwc-ahci.yaml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,15 @@ description:
1313
This document defines device tree bindings for the generic Synopsys DWC
1414
implementation of the AHCI SATA controller.
1515

16+
select:
17+
properties:
18+
compatible:
19+
enum:
20+
- snps,dwc-ahci
21+
- snps,spear-ahci
22+
required:
23+
- compatible
24+
1625
allOf:
1726
- $ref: snps,dwc-ahci-common.yaml#
1827

@@ -23,10 +32,6 @@ properties:
2332
const: snps,dwc-ahci
2433
- description: SPEAr1340 AHCI SATA device
2534
const: snps,spear-ahci
26-
- description: Rockhip RK3568 AHCI controller
27-
items:
28-
- const: rockchip,rk3568-dwc-ahci
29-
- const: snps,dwc-ahci
3035

3136
patternProperties:
3237
"^sata-port@[0-9a-e]$":

Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,14 @@ properties:
3131
- const: pipe
3232

3333
resets:
34+
minItems: 1
35+
maxItems: 2
36+
37+
reset-names:
38+
minItems: 1
3439
items:
35-
- description: exclusive PHY reset line
40+
- const: phy
41+
- const: apb
3642

3743
rockchip,enable-ssc:
3844
type: boolean
@@ -78,6 +84,32 @@ required:
7884
- rockchip,pipe-phy-grf
7985
- "#phy-cells"
8086

87+
allOf:
88+
- if:
89+
properties:
90+
compatible:
91+
contains:
92+
const: rockchip,rk3568-naneng-combphy
93+
then:
94+
properties:
95+
resets:
96+
maxItems: 1
97+
reset-names:
98+
maxItems: 1
99+
- if:
100+
properties:
101+
compatible:
102+
contains:
103+
const: rockchip,rk3588-naneng-combphy
104+
then:
105+
properties:
106+
resets:
107+
minItems: 2
108+
reset-names:
109+
minItems: 2
110+
required:
111+
- reset-names
112+
81113
additionalProperties: false
82114

83115
examples:

drivers/ata/ahci_brcm.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -544,15 +544,15 @@ static int brcm_ahci_probe(struct platform_device *pdev)
544544
return ret;
545545
}
546546

547-
static int brcm_ahci_remove(struct platform_device *pdev)
547+
static void brcm_ahci_remove(struct platform_device *pdev)
548548
{
549549
struct ata_host *host = dev_get_drvdata(&pdev->dev);
550550
struct ahci_host_priv *hpriv = host->private_data;
551551
struct brcm_ahci_priv *priv = hpriv->plat_data;
552552

553553
brcm_sata_phys_disable(priv);
554554

555-
return ata_platform_remove_one(pdev);
555+
ata_platform_remove_one(pdev);
556556
}
557557

558558
static void brcm_ahci_shutdown(struct platform_device *pdev)
@@ -573,7 +573,7 @@ static SIMPLE_DEV_PM_OPS(ahci_brcm_pm_ops, brcm_ahci_suspend, brcm_ahci_resume);
573573

574574
static struct platform_driver brcm_ahci_driver = {
575575
.probe = brcm_ahci_probe,
576-
.remove = brcm_ahci_remove,
576+
.remove_new = brcm_ahci_remove,
577577
.shutdown = brcm_ahci_shutdown,
578578
.driver = {
579579
.name = DRV_NAME,

drivers/ata/ahci_ceva.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ MODULE_DEVICE_TABLE(of, ceva_ahci_of_match);
369369

370370
static struct platform_driver ceva_ahci_driver = {
371371
.probe = ceva_ahci_probe,
372-
.remove = ata_platform_remove_one,
372+
.remove_new = ata_platform_remove_one,
373373
.driver = {
374374
.name = DRV_NAME,
375375
.of_match_table = ceva_ahci_of_match,

drivers/ata/ahci_da850.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ MODULE_DEVICE_TABLE(of, ahci_da850_of_match);
238238

239239
static struct platform_driver ahci_da850_driver = {
240240
.probe = ahci_da850_probe,
241-
.remove = ata_platform_remove_one,
241+
.remove_new = ata_platform_remove_one,
242242
.driver = {
243243
.name = DRV_NAME,
244244
.of_match_table = ahci_da850_of_match,

drivers/ata/ahci_dm816.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ MODULE_DEVICE_TABLE(of, ahci_dm816_of_match);
182182

183183
static struct platform_driver ahci_dm816_driver = {
184184
.probe = ahci_dm816_probe,
185-
.remove = ata_platform_remove_one,
185+
.remove_new = ata_platform_remove_one,
186186
.driver = {
187187
.name = AHCI_DM816_DRV_NAME,
188188
.of_match_table = ahci_dm816_of_match,

drivers/ata/ahci_dwc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ MODULE_DEVICE_TABLE(of, ahci_dwc_of_match);
478478

479479
static struct platform_driver ahci_dwc_driver = {
480480
.probe = ahci_dwc_probe,
481-
.remove = ata_platform_remove_one,
481+
.remove_new = ata_platform_remove_one,
482482
.shutdown = ahci_platform_shutdown,
483483
.driver = {
484484
.name = DRV_NAME,

drivers/ata/ahci_imx.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1223,7 +1223,7 @@ static SIMPLE_DEV_PM_OPS(ahci_imx_pm_ops, imx_ahci_suspend, imx_ahci_resume);
12231223

12241224
static struct platform_driver imx_ahci_driver = {
12251225
.probe = imx_ahci_probe,
1226-
.remove = ata_platform_remove_one,
1226+
.remove_new = ata_platform_remove_one,
12271227
.driver = {
12281228
.name = DRV_NAME,
12291229
.of_match_table = imx_ahci_of_match,

0 commit comments

Comments
 (0)