@@ -2294,6 +2294,56 @@ static const char * const sdm845_pciephy_reset_l[] = {
2294
2294
"phy" ,
2295
2295
};
2296
2296
2297
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_qhp = {
2298
+ .serdes = 0 ,
2299
+ .pcs = 0x1800 ,
2300
+ .tx = 0x0800 ,
2301
+ /* no .rx for QHP */
2302
+ };
2303
+
2304
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_v2 = {
2305
+ .serdes = 0 ,
2306
+ .pcs = 0x0800 ,
2307
+ .tx = 0x0200 ,
2308
+ .rx = 0x0400 ,
2309
+ };
2310
+
2311
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_v3 = {
2312
+ .serdes = 0 ,
2313
+ .pcs = 0x0800 ,
2314
+ .pcs_misc = 0x0600 ,
2315
+ .tx = 0x0200 ,
2316
+ .rx = 0x0400 ,
2317
+ };
2318
+
2319
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_v4x1 = {
2320
+ .serdes = 0 ,
2321
+ .pcs = 0x0800 ,
2322
+ .pcs_misc = 0x0c00 ,
2323
+ .tx = 0x0200 ,
2324
+ .rx = 0x0400 ,
2325
+ };
2326
+
2327
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_v4x2 = {
2328
+ .serdes = 0 ,
2329
+ .pcs = 0x0a00 ,
2330
+ .pcs_misc = 0x0e00 ,
2331
+ .tx = 0x0200 ,
2332
+ .rx = 0x0400 ,
2333
+ .tx2 = 0x0600 ,
2334
+ .rx2 = 0x0800 ,
2335
+ };
2336
+
2337
+ static const struct qmp_pcie_offsets qmp_pcie_offsets_v4_20 = {
2338
+ .serdes = 0x1000 ,
2339
+ .pcs = 0x1200 ,
2340
+ .pcs_misc = 0x1600 ,
2341
+ .tx = 0x0000 ,
2342
+ .rx = 0x0200 ,
2343
+ .tx2 = 0x0800 ,
2344
+ .rx2 = 0x0a00 ,
2345
+ };
2346
+
2297
2347
static const struct qmp_pcie_offsets qmp_pcie_offsets_v5 = {
2298
2348
.serdes = 0 ,
2299
2349
.pcs = 0x0200 ,
@@ -2338,6 +2388,8 @@ static const struct qmp_pcie_offsets qmp_pcie_offsets_v6_20 = {
2338
2388
static const struct qmp_phy_cfg ipq8074_pciephy_cfg = {
2339
2389
.lanes = 1 ,
2340
2390
2391
+ .offsets = & qmp_pcie_offsets_v2 ,
2392
+
2341
2393
.tbls = {
2342
2394
.serdes = ipq8074_pcie_serdes_tbl ,
2343
2395
.serdes_num = ARRAY_SIZE (ipq8074_pcie_serdes_tbl ),
@@ -2361,6 +2413,8 @@ static const struct qmp_phy_cfg ipq8074_pciephy_cfg = {
2361
2413
static const struct qmp_phy_cfg ipq8074_pciephy_gen3_cfg = {
2362
2414
.lanes = 1 ,
2363
2415
2416
+ .offsets = & qmp_pcie_offsets_v4x1 ,
2417
+
2364
2418
.tbls = {
2365
2419
.serdes = ipq8074_pcie_gen3_serdes_tbl ,
2366
2420
.serdes_num = ARRAY_SIZE (ipq8074_pcie_gen3_serdes_tbl ),
@@ -2388,6 +2442,8 @@ static const struct qmp_phy_cfg ipq8074_pciephy_gen3_cfg = {
2388
2442
static const struct qmp_phy_cfg ipq6018_pciephy_cfg = {
2389
2443
.lanes = 1 ,
2390
2444
2445
+ .offsets = & qmp_pcie_offsets_v4x1 ,
2446
+
2391
2447
.tbls = {
2392
2448
.serdes = ipq6018_pcie_serdes_tbl ,
2393
2449
.serdes_num = ARRAY_SIZE (ipq6018_pcie_serdes_tbl ),
@@ -2413,6 +2469,8 @@ static const struct qmp_phy_cfg ipq6018_pciephy_cfg = {
2413
2469
static const struct qmp_phy_cfg sdm845_qmp_pciephy_cfg = {
2414
2470
.lanes = 1 ,
2415
2471
2472
+ .offsets = & qmp_pcie_offsets_v3 ,
2473
+
2416
2474
.tbls = {
2417
2475
.serdes = sdm845_qmp_pcie_serdes_tbl ,
2418
2476
.serdes_num = ARRAY_SIZE (sdm845_qmp_pcie_serdes_tbl ),
@@ -2438,6 +2496,8 @@ static const struct qmp_phy_cfg sdm845_qmp_pciephy_cfg = {
2438
2496
static const struct qmp_phy_cfg sdm845_qhp_pciephy_cfg = {
2439
2497
.lanes = 1 ,
2440
2498
2499
+ .offsets = & qmp_pcie_offsets_qhp ,
2500
+
2441
2501
.tbls = {
2442
2502
.serdes = sdm845_qhp_pcie_serdes_tbl ,
2443
2503
.serdes_num = ARRAY_SIZE (sdm845_qhp_pcie_serdes_tbl ),
@@ -2459,6 +2519,8 @@ static const struct qmp_phy_cfg sdm845_qhp_pciephy_cfg = {
2459
2519
static const struct qmp_phy_cfg sm8250_qmp_gen3x1_pciephy_cfg = {
2460
2520
.lanes = 1 ,
2461
2521
2522
+ .offsets = & qmp_pcie_offsets_v4x1 ,
2523
+
2462
2524
.tbls = {
2463
2525
.serdes = sm8250_qmp_pcie_serdes_tbl ,
2464
2526
.serdes_num = ARRAY_SIZE (sm8250_qmp_pcie_serdes_tbl ),
@@ -2494,6 +2556,8 @@ static const struct qmp_phy_cfg sm8250_qmp_gen3x1_pciephy_cfg = {
2494
2556
static const struct qmp_phy_cfg sm8250_qmp_gen3x2_pciephy_cfg = {
2495
2557
.lanes = 2 ,
2496
2558
2559
+ .offsets = & qmp_pcie_offsets_v4x2 ,
2560
+
2497
2561
.tbls = {
2498
2562
.serdes = sm8250_qmp_pcie_serdes_tbl ,
2499
2563
.serdes_num = ARRAY_SIZE (sm8250_qmp_pcie_serdes_tbl ),
@@ -2529,6 +2593,8 @@ static const struct qmp_phy_cfg sm8250_qmp_gen3x2_pciephy_cfg = {
2529
2593
static const struct qmp_phy_cfg msm8998_pciephy_cfg = {
2530
2594
.lanes = 1 ,
2531
2595
2596
+ .offsets = & qmp_pcie_offsets_v3 ,
2597
+
2532
2598
.tbls = {
2533
2599
.serdes = msm8998_pcie_serdes_tbl ,
2534
2600
.serdes_num = ARRAY_SIZE (msm8998_pcie_serdes_tbl ),
@@ -2554,6 +2620,8 @@ static const struct qmp_phy_cfg msm8998_pciephy_cfg = {
2554
2620
static const struct qmp_phy_cfg sc8180x_pciephy_cfg = {
2555
2621
.lanes = 2 ,
2556
2622
2623
+ .offsets = & qmp_pcie_offsets_v4x2 ,
2624
+
2557
2625
.tbls = {
2558
2626
.serdes = sc8180x_qmp_pcie_serdes_tbl ,
2559
2627
.serdes_num = ARRAY_SIZE (sc8180x_qmp_pcie_serdes_tbl ),
@@ -2681,6 +2749,8 @@ static const struct qmp_phy_cfg sc8280xp_qmp_gen3x4_pciephy_cfg = {
2681
2749
static const struct qmp_phy_cfg sdx55_qmp_pciephy_cfg = {
2682
2750
.lanes = 2 ,
2683
2751
2752
+ .offsets = & qmp_pcie_offsets_v4_20 ,
2753
+
2684
2754
.tbls = {
2685
2755
.serdes = sdx55_qmp_pcie_serdes_tbl ,
2686
2756
.serdes_num = ARRAY_SIZE (sdx55_qmp_pcie_serdes_tbl ),
@@ -2818,6 +2888,8 @@ static const struct qmp_phy_cfg sdx65_qmp_pciephy_cfg = {
2818
2888
static const struct qmp_phy_cfg sm8450_qmp_gen3x1_pciephy_cfg = {
2819
2889
.lanes = 1 ,
2820
2890
2891
+ .offsets = & qmp_pcie_offsets_v5 ,
2892
+
2821
2893
.tbls = {
2822
2894
.serdes = sm8450_qmp_gen3_pcie_serdes_tbl ,
2823
2895
.serdes_num = ARRAY_SIZE (sm8450_qmp_gen3_pcie_serdes_tbl ),
@@ -2851,6 +2923,8 @@ static const struct qmp_phy_cfg sm8450_qmp_gen3x1_pciephy_cfg = {
2851
2923
static const struct qmp_phy_cfg sm8450_qmp_gen4x2_pciephy_cfg = {
2852
2924
.lanes = 2 ,
2853
2925
2926
+ .offsets = & qmp_pcie_offsets_v5_20 ,
2927
+
2854
2928
.tbls = {
2855
2929
.serdes = sm8450_qmp_gen4x2_pcie_serdes_tbl ,
2856
2930
.serdes_num = ARRAY_SIZE (sm8450_qmp_gen4x2_pcie_serdes_tbl ),
0 commit comments