mfd: wm5110: Make additional DSP registers available to the user
authorCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
Wed, 22 Jan 2014 13:04:24 +0000 (13:04 +0000)
committerLee Jones <lee.jones@linaro.org>
Wed, 19 Mar 2014 08:58:05 +0000 (08:58 +0000)
Expose some DSP registers which are useful for DSP users to be able to
access whilst debugging their firmware.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/wm5110-tables.c
include/linux/mfd/arizona/registers.h

index 11632f135e8c8d7a6f57206b4d09cd8b097815c7..ca996852501778945dcccbb3ee7daa73c55d5a2c 100644 (file)
@@ -2461,6 +2461,27 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP1_STATUS_1:
        case ARIZONA_DSP1_STATUS_2:
        case ARIZONA_DSP1_STATUS_3:
+       case ARIZONA_DSP1_STATUS_4:
+       case ARIZONA_DSP1_WDMA_BUFFER_1:
+       case ARIZONA_DSP1_WDMA_BUFFER_2:
+       case ARIZONA_DSP1_WDMA_BUFFER_3:
+       case ARIZONA_DSP1_WDMA_BUFFER_4:
+       case ARIZONA_DSP1_WDMA_BUFFER_5:
+       case ARIZONA_DSP1_WDMA_BUFFER_6:
+       case ARIZONA_DSP1_WDMA_BUFFER_7:
+       case ARIZONA_DSP1_WDMA_BUFFER_8:
+       case ARIZONA_DSP1_RDMA_BUFFER_1:
+       case ARIZONA_DSP1_RDMA_BUFFER_2:
+       case ARIZONA_DSP1_RDMA_BUFFER_3:
+       case ARIZONA_DSP1_RDMA_BUFFER_4:
+       case ARIZONA_DSP1_RDMA_BUFFER_5:
+       case ARIZONA_DSP1_RDMA_BUFFER_6:
+       case ARIZONA_DSP1_WDMA_CONFIG_1:
+       case ARIZONA_DSP1_WDMA_CONFIG_2:
+       case ARIZONA_DSP1_WDMA_OFFSET_1:
+       case ARIZONA_DSP1_RDMA_CONFIG_1:
+       case ARIZONA_DSP1_RDMA_OFFSET_1:
+       case ARIZONA_DSP1_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP1_SCRATCH_0:
        case ARIZONA_DSP1_SCRATCH_1:
        case ARIZONA_DSP1_SCRATCH_2:
@@ -2470,6 +2491,27 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP2_STATUS_1:
        case ARIZONA_DSP2_STATUS_2:
        case ARIZONA_DSP2_STATUS_3:
+       case ARIZONA_DSP2_STATUS_4:
+       case ARIZONA_DSP2_WDMA_BUFFER_1:
+       case ARIZONA_DSP2_WDMA_BUFFER_2:
+       case ARIZONA_DSP2_WDMA_BUFFER_3:
+       case ARIZONA_DSP2_WDMA_BUFFER_4:
+       case ARIZONA_DSP2_WDMA_BUFFER_5:
+       case ARIZONA_DSP2_WDMA_BUFFER_6:
+       case ARIZONA_DSP2_WDMA_BUFFER_7:
+       case ARIZONA_DSP2_WDMA_BUFFER_8:
+       case ARIZONA_DSP2_RDMA_BUFFER_1:
+       case ARIZONA_DSP2_RDMA_BUFFER_2:
+       case ARIZONA_DSP2_RDMA_BUFFER_3:
+       case ARIZONA_DSP2_RDMA_BUFFER_4:
+       case ARIZONA_DSP2_RDMA_BUFFER_5:
+       case ARIZONA_DSP2_RDMA_BUFFER_6:
+       case ARIZONA_DSP2_WDMA_CONFIG_1:
+       case ARIZONA_DSP2_WDMA_CONFIG_2:
+       case ARIZONA_DSP2_WDMA_OFFSET_1:
+       case ARIZONA_DSP2_RDMA_CONFIG_1:
+       case ARIZONA_DSP2_RDMA_OFFSET_1:
+       case ARIZONA_DSP2_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP2_SCRATCH_0:
        case ARIZONA_DSP2_SCRATCH_1:
        case ARIZONA_DSP2_SCRATCH_2:
@@ -2479,6 +2521,27 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP3_STATUS_1:
        case ARIZONA_DSP3_STATUS_2:
        case ARIZONA_DSP3_STATUS_3:
+       case ARIZONA_DSP3_STATUS_4:
+       case ARIZONA_DSP3_WDMA_BUFFER_1:
+       case ARIZONA_DSP3_WDMA_BUFFER_2:
+       case ARIZONA_DSP3_WDMA_BUFFER_3:
+       case ARIZONA_DSP3_WDMA_BUFFER_4:
+       case ARIZONA_DSP3_WDMA_BUFFER_5:
+       case ARIZONA_DSP3_WDMA_BUFFER_6:
+       case ARIZONA_DSP3_WDMA_BUFFER_7:
+       case ARIZONA_DSP3_WDMA_BUFFER_8:
+       case ARIZONA_DSP3_RDMA_BUFFER_1:
+       case ARIZONA_DSP3_RDMA_BUFFER_2:
+       case ARIZONA_DSP3_RDMA_BUFFER_3:
+       case ARIZONA_DSP3_RDMA_BUFFER_4:
+       case ARIZONA_DSP3_RDMA_BUFFER_5:
+       case ARIZONA_DSP3_RDMA_BUFFER_6:
+       case ARIZONA_DSP3_WDMA_CONFIG_1:
+       case ARIZONA_DSP3_WDMA_CONFIG_2:
+       case ARIZONA_DSP3_WDMA_OFFSET_1:
+       case ARIZONA_DSP3_RDMA_CONFIG_1:
+       case ARIZONA_DSP3_RDMA_OFFSET_1:
+       case ARIZONA_DSP3_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP3_SCRATCH_0:
        case ARIZONA_DSP3_SCRATCH_1:
        case ARIZONA_DSP3_SCRATCH_2:
@@ -2488,6 +2551,27 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP4_STATUS_1:
        case ARIZONA_DSP4_STATUS_2:
        case ARIZONA_DSP4_STATUS_3:
+       case ARIZONA_DSP4_STATUS_4:
+       case ARIZONA_DSP4_WDMA_BUFFER_1:
+       case ARIZONA_DSP4_WDMA_BUFFER_2:
+       case ARIZONA_DSP4_WDMA_BUFFER_3:
+       case ARIZONA_DSP4_WDMA_BUFFER_4:
+       case ARIZONA_DSP4_WDMA_BUFFER_5:
+       case ARIZONA_DSP4_WDMA_BUFFER_6:
+       case ARIZONA_DSP4_WDMA_BUFFER_7:
+       case ARIZONA_DSP4_WDMA_BUFFER_8:
+       case ARIZONA_DSP4_RDMA_BUFFER_1:
+       case ARIZONA_DSP4_RDMA_BUFFER_2:
+       case ARIZONA_DSP4_RDMA_BUFFER_3:
+       case ARIZONA_DSP4_RDMA_BUFFER_4:
+       case ARIZONA_DSP4_RDMA_BUFFER_5:
+       case ARIZONA_DSP4_RDMA_BUFFER_6:
+       case ARIZONA_DSP4_WDMA_CONFIG_1:
+       case ARIZONA_DSP4_WDMA_CONFIG_2:
+       case ARIZONA_DSP4_WDMA_OFFSET_1:
+       case ARIZONA_DSP4_RDMA_CONFIG_1:
+       case ARIZONA_DSP4_RDMA_OFFSET_1:
+       case ARIZONA_DSP4_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP4_SCRATCH_0:
        case ARIZONA_DSP4_SCRATCH_1:
        case ARIZONA_DSP4_SCRATCH_2:
@@ -2543,6 +2627,27 @@ static bool wm5110_volatile_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP1_STATUS_1:
        case ARIZONA_DSP1_STATUS_2:
        case ARIZONA_DSP1_STATUS_3:
+       case ARIZONA_DSP1_STATUS_4:
+       case ARIZONA_DSP1_WDMA_BUFFER_1:
+       case ARIZONA_DSP1_WDMA_BUFFER_2:
+       case ARIZONA_DSP1_WDMA_BUFFER_3:
+       case ARIZONA_DSP1_WDMA_BUFFER_4:
+       case ARIZONA_DSP1_WDMA_BUFFER_5:
+       case ARIZONA_DSP1_WDMA_BUFFER_6:
+       case ARIZONA_DSP1_WDMA_BUFFER_7:
+       case ARIZONA_DSP1_WDMA_BUFFER_8:
+       case ARIZONA_DSP1_RDMA_BUFFER_1:
+       case ARIZONA_DSP1_RDMA_BUFFER_2:
+       case ARIZONA_DSP1_RDMA_BUFFER_3:
+       case ARIZONA_DSP1_RDMA_BUFFER_4:
+       case ARIZONA_DSP1_RDMA_BUFFER_5:
+       case ARIZONA_DSP1_RDMA_BUFFER_6:
+       case ARIZONA_DSP1_WDMA_CONFIG_1:
+       case ARIZONA_DSP1_WDMA_CONFIG_2:
+       case ARIZONA_DSP1_WDMA_OFFSET_1:
+       case ARIZONA_DSP1_RDMA_CONFIG_1:
+       case ARIZONA_DSP1_RDMA_OFFSET_1:
+       case ARIZONA_DSP1_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP1_SCRATCH_0:
        case ARIZONA_DSP1_SCRATCH_1:
        case ARIZONA_DSP1_SCRATCH_2:
@@ -2550,6 +2655,27 @@ static bool wm5110_volatile_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP2_STATUS_1:
        case ARIZONA_DSP2_STATUS_2:
        case ARIZONA_DSP2_STATUS_3:
+       case ARIZONA_DSP2_STATUS_4:
+       case ARIZONA_DSP2_WDMA_BUFFER_1:
+       case ARIZONA_DSP2_WDMA_BUFFER_2:
+       case ARIZONA_DSP2_WDMA_BUFFER_3:
+       case ARIZONA_DSP2_WDMA_BUFFER_4:
+       case ARIZONA_DSP2_WDMA_BUFFER_5:
+       case ARIZONA_DSP2_WDMA_BUFFER_6:
+       case ARIZONA_DSP2_WDMA_BUFFER_7:
+       case ARIZONA_DSP2_WDMA_BUFFER_8:
+       case ARIZONA_DSP2_RDMA_BUFFER_1:
+       case ARIZONA_DSP2_RDMA_BUFFER_2:
+       case ARIZONA_DSP2_RDMA_BUFFER_3:
+       case ARIZONA_DSP2_RDMA_BUFFER_4:
+       case ARIZONA_DSP2_RDMA_BUFFER_5:
+       case ARIZONA_DSP2_RDMA_BUFFER_6:
+       case ARIZONA_DSP2_WDMA_CONFIG_1:
+       case ARIZONA_DSP2_WDMA_CONFIG_2:
+       case ARIZONA_DSP2_WDMA_OFFSET_1:
+       case ARIZONA_DSP2_RDMA_CONFIG_1:
+       case ARIZONA_DSP2_RDMA_OFFSET_1:
+       case ARIZONA_DSP2_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP2_SCRATCH_0:
        case ARIZONA_DSP2_SCRATCH_1:
        case ARIZONA_DSP2_SCRATCH_2:
@@ -2557,6 +2683,27 @@ static bool wm5110_volatile_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP3_STATUS_1:
        case ARIZONA_DSP3_STATUS_2:
        case ARIZONA_DSP3_STATUS_3:
+       case ARIZONA_DSP3_STATUS_4:
+       case ARIZONA_DSP3_WDMA_BUFFER_1:
+       case ARIZONA_DSP3_WDMA_BUFFER_2:
+       case ARIZONA_DSP3_WDMA_BUFFER_3:
+       case ARIZONA_DSP3_WDMA_BUFFER_4:
+       case ARIZONA_DSP3_WDMA_BUFFER_5:
+       case ARIZONA_DSP3_WDMA_BUFFER_6:
+       case ARIZONA_DSP3_WDMA_BUFFER_7:
+       case ARIZONA_DSP3_WDMA_BUFFER_8:
+       case ARIZONA_DSP3_RDMA_BUFFER_1:
+       case ARIZONA_DSP3_RDMA_BUFFER_2:
+       case ARIZONA_DSP3_RDMA_BUFFER_3:
+       case ARIZONA_DSP3_RDMA_BUFFER_4:
+       case ARIZONA_DSP3_RDMA_BUFFER_5:
+       case ARIZONA_DSP3_RDMA_BUFFER_6:
+       case ARIZONA_DSP3_WDMA_CONFIG_1:
+       case ARIZONA_DSP3_WDMA_CONFIG_2:
+       case ARIZONA_DSP3_WDMA_OFFSET_1:
+       case ARIZONA_DSP3_RDMA_CONFIG_1:
+       case ARIZONA_DSP3_RDMA_OFFSET_1:
+       case ARIZONA_DSP3_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP3_SCRATCH_0:
        case ARIZONA_DSP3_SCRATCH_1:
        case ARIZONA_DSP3_SCRATCH_2:
@@ -2564,6 +2711,27 @@ static bool wm5110_volatile_register(struct device *dev, unsigned int reg)
        case ARIZONA_DSP4_STATUS_1:
        case ARIZONA_DSP4_STATUS_2:
        case ARIZONA_DSP4_STATUS_3:
+       case ARIZONA_DSP4_STATUS_4:
+       case ARIZONA_DSP4_WDMA_BUFFER_1:
+       case ARIZONA_DSP4_WDMA_BUFFER_2:
+       case ARIZONA_DSP4_WDMA_BUFFER_3:
+       case ARIZONA_DSP4_WDMA_BUFFER_4:
+       case ARIZONA_DSP4_WDMA_BUFFER_5:
+       case ARIZONA_DSP4_WDMA_BUFFER_6:
+       case ARIZONA_DSP4_WDMA_BUFFER_7:
+       case ARIZONA_DSP4_WDMA_BUFFER_8:
+       case ARIZONA_DSP4_RDMA_BUFFER_1:
+       case ARIZONA_DSP4_RDMA_BUFFER_2:
+       case ARIZONA_DSP4_RDMA_BUFFER_3:
+       case ARIZONA_DSP4_RDMA_BUFFER_4:
+       case ARIZONA_DSP4_RDMA_BUFFER_5:
+       case ARIZONA_DSP4_RDMA_BUFFER_6:
+       case ARIZONA_DSP4_WDMA_CONFIG_1:
+       case ARIZONA_DSP4_WDMA_CONFIG_2:
+       case ARIZONA_DSP4_WDMA_OFFSET_1:
+       case ARIZONA_DSP4_RDMA_CONFIG_1:
+       case ARIZONA_DSP4_RDMA_OFFSET_1:
+       case ARIZONA_DSP4_EXTERNAL_START_SELECT_1:
        case ARIZONA_DSP4_SCRATCH_0:
        case ARIZONA_DSP4_SCRATCH_1:
        case ARIZONA_DSP4_SCRATCH_2:
index 6a3b16993c1a8333b75e29c0709823f393291824..90d57aec34e7e706c8576e6bf1cf850543184347 100644 (file)
 #define ARIZONA_DSP1_STATUS_1                    0x1104
 #define ARIZONA_DSP1_STATUS_2                    0x1105
 #define ARIZONA_DSP1_STATUS_3                    0x1106
+#define ARIZONA_DSP1_STATUS_4                    0x1107
 #define ARIZONA_DSP1_WDMA_BUFFER_1               0x1110
 #define ARIZONA_DSP1_WDMA_BUFFER_2               0x1111
 #define ARIZONA_DSP1_WDMA_BUFFER_3               0x1112
 #define ARIZONA_DSP1_RDMA_BUFFER_6               0x1125
 #define ARIZONA_DSP1_WDMA_CONFIG_1               0x1130
 #define ARIZONA_DSP1_WDMA_CONFIG_2               0x1131
+#define ARIZONA_DSP1_WDMA_OFFSET_1               0x1132
 #define ARIZONA_DSP1_RDMA_CONFIG_1               0x1134
+#define ARIZONA_DSP1_RDMA_OFFSET_1               0x1135
+#define ARIZONA_DSP1_EXTERNAL_START_SELECT_1     0x1138
 #define ARIZONA_DSP1_SCRATCH_0                   0x1140
 #define ARIZONA_DSP1_SCRATCH_1                   0x1141
 #define ARIZONA_DSP1_SCRATCH_2                   0x1142
 #define ARIZONA_DSP2_STATUS_1                    0x1204
 #define ARIZONA_DSP2_STATUS_2                    0x1205
 #define ARIZONA_DSP2_STATUS_3                    0x1206
+#define ARIZONA_DSP2_STATUS_4                    0x1207
+#define ARIZONA_DSP2_WDMA_BUFFER_1               0x1210
+#define ARIZONA_DSP2_WDMA_BUFFER_2               0x1211
+#define ARIZONA_DSP2_WDMA_BUFFER_3               0x1212
+#define ARIZONA_DSP2_WDMA_BUFFER_4               0x1213
+#define ARIZONA_DSP2_WDMA_BUFFER_5               0x1214
+#define ARIZONA_DSP2_WDMA_BUFFER_6               0x1215
+#define ARIZONA_DSP2_WDMA_BUFFER_7               0x1216
+#define ARIZONA_DSP2_WDMA_BUFFER_8               0x1217
+#define ARIZONA_DSP2_RDMA_BUFFER_1               0x1220
+#define ARIZONA_DSP2_RDMA_BUFFER_2               0x1221
+#define ARIZONA_DSP2_RDMA_BUFFER_3               0x1222
+#define ARIZONA_DSP2_RDMA_BUFFER_4               0x1223
+#define ARIZONA_DSP2_RDMA_BUFFER_5               0x1224
+#define ARIZONA_DSP2_RDMA_BUFFER_6               0x1225
+#define ARIZONA_DSP2_WDMA_CONFIG_1               0x1230
+#define ARIZONA_DSP2_WDMA_CONFIG_2               0x1231
+#define ARIZONA_DSP2_WDMA_OFFSET_1               0x1232
+#define ARIZONA_DSP2_RDMA_CONFIG_1               0x1234
+#define ARIZONA_DSP2_RDMA_OFFSET_1               0x1235
+#define ARIZONA_DSP2_EXTERNAL_START_SELECT_1     0x1238
 #define ARIZONA_DSP2_SCRATCH_0                   0x1240
 #define ARIZONA_DSP2_SCRATCH_1                   0x1241
 #define ARIZONA_DSP2_SCRATCH_2                   0x1242
 #define ARIZONA_DSP3_STATUS_1                    0x1304
 #define ARIZONA_DSP3_STATUS_2                    0x1305
 #define ARIZONA_DSP3_STATUS_3                    0x1306
+#define ARIZONA_DSP3_STATUS_4                    0x1307
+#define ARIZONA_DSP3_WDMA_BUFFER_1               0x1310
+#define ARIZONA_DSP3_WDMA_BUFFER_2               0x1311
+#define ARIZONA_DSP3_WDMA_BUFFER_3               0x1312
+#define ARIZONA_DSP3_WDMA_BUFFER_4               0x1313
+#define ARIZONA_DSP3_WDMA_BUFFER_5               0x1314
+#define ARIZONA_DSP3_WDMA_BUFFER_6               0x1315
+#define ARIZONA_DSP3_WDMA_BUFFER_7               0x1316
+#define ARIZONA_DSP3_WDMA_BUFFER_8               0x1317
+#define ARIZONA_DSP3_RDMA_BUFFER_1               0x1320
+#define ARIZONA_DSP3_RDMA_BUFFER_2               0x1321
+#define ARIZONA_DSP3_RDMA_BUFFER_3               0x1322
+#define ARIZONA_DSP3_RDMA_BUFFER_4               0x1323
+#define ARIZONA_DSP3_RDMA_BUFFER_5               0x1324
+#define ARIZONA_DSP3_RDMA_BUFFER_6               0x1325
+#define ARIZONA_DSP3_WDMA_CONFIG_1               0x1330
+#define ARIZONA_DSP3_WDMA_CONFIG_2               0x1331
+#define ARIZONA_DSP3_WDMA_OFFSET_1               0x1332
+#define ARIZONA_DSP3_RDMA_CONFIG_1               0x1334
+#define ARIZONA_DSP3_RDMA_OFFSET_1               0x1335
+#define ARIZONA_DSP3_EXTERNAL_START_SELECT_1     0x1338
 #define ARIZONA_DSP3_SCRATCH_0                   0x1340
 #define ARIZONA_DSP3_SCRATCH_1                   0x1341
 #define ARIZONA_DSP3_SCRATCH_2                   0x1342
 #define ARIZONA_DSP4_STATUS_1                    0x1404
 #define ARIZONA_DSP4_STATUS_2                    0x1405
 #define ARIZONA_DSP4_STATUS_3                    0x1406
+#define ARIZONA_DSP4_STATUS_4                    0x1407
+#define ARIZONA_DSP4_WDMA_BUFFER_1               0x1410
+#define ARIZONA_DSP4_WDMA_BUFFER_2               0x1411
+#define ARIZONA_DSP4_WDMA_BUFFER_3               0x1412
+#define ARIZONA_DSP4_WDMA_BUFFER_4               0x1413
+#define ARIZONA_DSP4_WDMA_BUFFER_5               0x1414
+#define ARIZONA_DSP4_WDMA_BUFFER_6               0x1415
+#define ARIZONA_DSP4_WDMA_BUFFER_7               0x1416
+#define ARIZONA_DSP4_WDMA_BUFFER_8               0x1417
+#define ARIZONA_DSP4_RDMA_BUFFER_1               0x1420
+#define ARIZONA_DSP4_RDMA_BUFFER_2               0x1421
+#define ARIZONA_DSP4_RDMA_BUFFER_3               0x1422
+#define ARIZONA_DSP4_RDMA_BUFFER_4               0x1423
+#define ARIZONA_DSP4_RDMA_BUFFER_5               0x1424
+#define ARIZONA_DSP4_RDMA_BUFFER_6               0x1425
+#define ARIZONA_DSP4_WDMA_CONFIG_1               0x1430
+#define ARIZONA_DSP4_WDMA_CONFIG_2               0x1431
+#define ARIZONA_DSP4_WDMA_OFFSET_1               0x1432
+#define ARIZONA_DSP4_RDMA_CONFIG_1               0x1434
+#define ARIZONA_DSP4_RDMA_OFFSET_1               0x1435
+#define ARIZONA_DSP4_EXTERNAL_START_SELECT_1     0x1438
 #define ARIZONA_DSP4_SCRATCH_0                   0x1440
 #define ARIZONA_DSP4_SCRATCH_1                   0x1441
 #define ARIZONA_DSP4_SCRATCH_2                   0x1442