1 /* 2 * Autogenerated file 3 * 4 * SPDX-License-Identifier: Apache 2.0 5 */ 6 7 #include "gd32-af.h" 8 9 /* ADC_IN0 */ 10 #define ADC_IN0_PA0 \ 11 GD32_PINMUX_AF('A', 0, ANALOG) 12 13 /* ADC_IN1 */ 14 #define ADC_IN1_PA1 \ 15 GD32_PINMUX_AF('A', 1, ANALOG) 16 17 /* ADC_IN2 */ 18 #define ADC_IN2_PA2 \ 19 GD32_PINMUX_AF('A', 2, ANALOG) 20 21 /* ADC_IN3 */ 22 #define ADC_IN3_PA3 \ 23 GD32_PINMUX_AF('A', 3, ANALOG) 24 25 /* ADC_IN4 */ 26 #define ADC_IN4_PA4 \ 27 GD32_PINMUX_AF('A', 4, ANALOG) 28 29 /* ADC_IN5 */ 30 #define ADC_IN5_PA5 \ 31 GD32_PINMUX_AF('A', 5, ANALOG) 32 33 /* ADC_IN6 */ 34 #define ADC_IN6_PA6 \ 35 GD32_PINMUX_AF('A', 6, ANALOG) 36 37 /* ADC_IN7 */ 38 #define ADC_IN7_PA7 \ 39 GD32_PINMUX_AF('A', 7, ANALOG) 40 41 /* ADC_IN8 */ 42 #define ADC_IN8_PB0 \ 43 GD32_PINMUX_AF('B', 0, ANALOG) 44 45 /* ADC_IN9 */ 46 #define ADC_IN9_PB1 \ 47 GD32_PINMUX_AF('B', 1, ANALOG) 48 49 /* ANALOG */ 50 #define ANALOG_PA0 \ 51 GD32_PINMUX_AF('A', 0, ANALOG) 52 #define ANALOG_PA1 \ 53 GD32_PINMUX_AF('A', 1, ANALOG) 54 #define ANALOG_PA2 \ 55 GD32_PINMUX_AF('A', 2, ANALOG) 56 #define ANALOG_PA3 \ 57 GD32_PINMUX_AF('A', 3, ANALOG) 58 #define ANALOG_PA4 \ 59 GD32_PINMUX_AF('A', 4, ANALOG) 60 #define ANALOG_PA5 \ 61 GD32_PINMUX_AF('A', 5, ANALOG) 62 #define ANALOG_PA6 \ 63 GD32_PINMUX_AF('A', 6, ANALOG) 64 #define ANALOG_PA7 \ 65 GD32_PINMUX_AF('A', 7, ANALOG) 66 #define ANALOG_PA8 \ 67 GD32_PINMUX_AF('A', 8, ANALOG) 68 #define ANALOG_PA9 \ 69 GD32_PINMUX_AF('A', 9, ANALOG) 70 #define ANALOG_PA10 \ 71 GD32_PINMUX_AF('A', 10, ANALOG) 72 #define ANALOG_PA11 \ 73 GD32_PINMUX_AF('A', 11, ANALOG) 74 #define ANALOG_PA12 \ 75 GD32_PINMUX_AF('A', 12, ANALOG) 76 #define ANALOG_PA13 \ 77 GD32_PINMUX_AF('A', 13, ANALOG) 78 #define ANALOG_PA14 \ 79 GD32_PINMUX_AF('A', 14, ANALOG) 80 #define ANALOG_PA15 \ 81 GD32_PINMUX_AF('A', 15, ANALOG) 82 #define ANALOG_PB0 \ 83 GD32_PINMUX_AF('B', 0, ANALOG) 84 #define ANALOG_PB1 \ 85 GD32_PINMUX_AF('B', 1, ANALOG) 86 #define ANALOG_PB2 \ 87 GD32_PINMUX_AF('B', 2, ANALOG) 88 #define ANALOG_PB3 \ 89 GD32_PINMUX_AF('B', 3, ANALOG) 90 #define ANALOG_PB4 \ 91 GD32_PINMUX_AF('B', 4, ANALOG) 92 #define ANALOG_PB5 \ 93 GD32_PINMUX_AF('B', 5, ANALOG) 94 #define ANALOG_PB6 \ 95 GD32_PINMUX_AF('B', 6, ANALOG) 96 #define ANALOG_PB7 \ 97 GD32_PINMUX_AF('B', 7, ANALOG) 98 #define ANALOG_PB8 \ 99 GD32_PINMUX_AF('B', 8, ANALOG) 100 #define ANALOG_PF0 \ 101 GD32_PINMUX_AF('F', 0, ANALOG) 102 103 /* CEC */ 104 #define CEC_PA5 \ 105 GD32_PINMUX_AF('A', 5, AF1) 106 #define CEC_PB8 \ 107 GD32_PINMUX_AF('B', 8, AF0) 108 109 /* CK_OUT */ 110 #define CK_OUT_PA8 \ 111 GD32_PINMUX_AF('A', 8, AF0) 112 113 /* CMP0_OUT */ 114 #define CMP0_OUT_PA0 \ 115 GD32_PINMUX_AF('A', 0, AF7) 116 #define CMP0_OUT_PA6 \ 117 GD32_PINMUX_AF('A', 6, AF7) 118 #define CMP0_OUT_PA11 \ 119 GD32_PINMUX_AF('A', 11, AF7) 120 121 /* CMP1_OUT */ 122 #define CMP1_OUT_PA2 \ 123 GD32_PINMUX_AF('A', 2, AF7) 124 #define CMP1_OUT_PA7 \ 125 GD32_PINMUX_AF('A', 7, AF7) 126 #define CMP1_OUT_PA12 \ 127 GD32_PINMUX_AF('A', 12, AF7) 128 129 /* CTC_SYNC */ 130 #define CTC_SYNC_PA8 \ 131 GD32_PINMUX_AF('A', 8, AF6) 132 #define CTC_SYNC_PF0 \ 133 GD32_PINMUX_AF('F', 0, AF0) 134 135 /* DAC0_OUT */ 136 #define DAC0_OUT_PA4 \ 137 GD32_PINMUX_AF('A', 4, ANALOG) 138 139 /* EVENTOUT */ 140 #define EVENTOUT_PA1 \ 141 GD32_PINMUX_AF('A', 1, AF0) 142 #define EVENTOUT_PA6 \ 143 GD32_PINMUX_AF('A', 6, AF6) 144 #define EVENTOUT_PA7 \ 145 GD32_PINMUX_AF('A', 7, AF6) 146 #define EVENTOUT_PA8 \ 147 GD32_PINMUX_AF('A', 8, AF3) 148 #define EVENTOUT_PA11 \ 149 GD32_PINMUX_AF('A', 11, AF0) 150 #define EVENTOUT_PA12 \ 151 GD32_PINMUX_AF('A', 12, AF0) 152 #define EVENTOUT_PA15 \ 153 GD32_PINMUX_AF('A', 15, AF3) 154 #define EVENTOUT_PB0 \ 155 GD32_PINMUX_AF('B', 0, AF0) 156 #define EVENTOUT_PB3 \ 157 GD32_PINMUX_AF('B', 3, AF1) 158 #define EVENTOUT_PB4 \ 159 GD32_PINMUX_AF('B', 4, AF2) 160 161 /* I2C0_SCL */ 162 #define I2C0_SCL_PA9 \ 163 GD32_PINMUX_AF('A', 9, AF4) 164 #define I2C0_SCL_PB6 \ 165 GD32_PINMUX_AF('B', 6, AF1) 166 #define I2C0_SCL_PB8 \ 167 GD32_PINMUX_AF('B', 8, AF1) 168 169 /* I2C0_SDA */ 170 #define I2C0_SDA_PA10 \ 171 GD32_PINMUX_AF('A', 10, AF4) 172 #define I2C0_SDA_PB7 \ 173 GD32_PINMUX_AF('B', 7, AF1) 174 175 /* I2C0_SMBA */ 176 #define I2C0_SMBA_PB5 \ 177 GD32_PINMUX_AF('B', 5, AF3) 178 179 /* I2S0_CK */ 180 #define I2S0_CK_PA5 \ 181 GD32_PINMUX_AF('A', 5, AF0) 182 #define I2S0_CK_PB3 \ 183 GD32_PINMUX_AF('B', 3, AF0) 184 185 /* I2S0_MCK */ 186 #define I2S0_MCK_PA6 \ 187 GD32_PINMUX_AF('A', 6, AF0) 188 #define I2S0_MCK_PB4 \ 189 GD32_PINMUX_AF('B', 4, AF0) 190 191 /* I2S0_SD */ 192 #define I2S0_SD_PA7 \ 193 GD32_PINMUX_AF('A', 7, AF0) 194 #define I2S0_SD_PB5 \ 195 GD32_PINMUX_AF('B', 5, AF0) 196 197 /* I2S0_WS */ 198 #define I2S0_WS_PA4 \ 199 GD32_PINMUX_AF('A', 4, AF0) 200 #define I2S0_WS_PA15 \ 201 GD32_PINMUX_AF('A', 15, AF0) 202 203 /* IFRP_OUT */ 204 #define IFRP_OUT_PA13 \ 205 GD32_PINMUX_AF('A', 13, AF1) 206 207 /* SPI0_MISO */ 208 #define SPI0_MISO_PA6 \ 209 GD32_PINMUX_AF('A', 6, AF0) 210 #define SPI0_MISO_PB4 \ 211 GD32_PINMUX_AF('B', 4, AF0) 212 213 /* SPI0_MOSI */ 214 #define SPI0_MOSI_PA7 \ 215 GD32_PINMUX_AF('A', 7, AF0) 216 #define SPI0_MOSI_PB5 \ 217 GD32_PINMUX_AF('B', 5, AF0) 218 219 /* SPI0_NSS */ 220 #define SPI0_NSS_PA4 \ 221 GD32_PINMUX_AF('A', 4, AF0) 222 #define SPI0_NSS_PA15 \ 223 GD32_PINMUX_AF('A', 15, AF0) 224 225 /* SPI0_SCK */ 226 #define SPI0_SCK_PA5 \ 227 GD32_PINMUX_AF('A', 5, AF0) 228 #define SPI0_SCK_PB3 \ 229 GD32_PINMUX_AF('B', 3, AF0) 230 231 /* SWCLK */ 232 #define SWCLK_PA14 \ 233 GD32_PINMUX_AF('A', 14, AF0) 234 235 /* SWDIO */ 236 #define SWDIO_PA13 \ 237 GD32_PINMUX_AF('A', 13, AF0) 238 239 /* TIMER0_BKIN */ 240 #define TIMER0_BKIN_PA6 \ 241 GD32_PINMUX_AF('A', 6, AF2) 242 243 /* TIMER0_CH0 */ 244 #define TIMER0_CH0_PA8 \ 245 GD32_PINMUX_AF('A', 8, AF2) 246 247 /* TIMER0_CH0_ON */ 248 #define TIMER0_CH0_ON_PA7 \ 249 GD32_PINMUX_AF('A', 7, AF2) 250 251 /* TIMER0_CH1 */ 252 #define TIMER0_CH1_PA9 \ 253 GD32_PINMUX_AF('A', 9, AF2) 254 255 /* TIMER0_CH1_ON */ 256 #define TIMER0_CH1_ON_PB0 \ 257 GD32_PINMUX_AF('B', 0, AF2) 258 259 /* TIMER0_CH2 */ 260 #define TIMER0_CH2_PA10 \ 261 GD32_PINMUX_AF('A', 10, AF2) 262 263 /* TIMER0_CH2_ON */ 264 #define TIMER0_CH2_ON_PB1 \ 265 GD32_PINMUX_AF('B', 1, AF2) 266 267 /* TIMER0_CH3 */ 268 #define TIMER0_CH3_PA11 \ 269 GD32_PINMUX_AF('A', 11, AF2) 270 271 /* TIMER0_ETI */ 272 #define TIMER0_ETI_PA12 \ 273 GD32_PINMUX_AF('A', 12, AF2) 274 275 /* TIMER13_CH0 */ 276 #define TIMER13_CH0_PA4 \ 277 GD32_PINMUX_AF('A', 4, AF4) 278 #define TIMER13_CH0_PA7 \ 279 GD32_PINMUX_AF('A', 7, AF4) 280 #define TIMER13_CH0_PB1 \ 281 GD32_PINMUX_AF('B', 1, AF0) 282 283 /* TIMER14_BKIN */ 284 #define TIMER14_BKIN_PA9 \ 285 GD32_PINMUX_AF('A', 9, AF0) 286 287 /* TIMER14_CH0 */ 288 #define TIMER14_CH0_PA2 \ 289 GD32_PINMUX_AF('A', 2, AF0) 290 291 /* TIMER14_CH1 */ 292 #define TIMER14_CH1_PA3 \ 293 GD32_PINMUX_AF('A', 3, AF0) 294 295 /* TIMER15_BKIN */ 296 #define TIMER15_BKIN_PB5 \ 297 GD32_PINMUX_AF('B', 5, AF2) 298 299 /* TIMER15_CH0 */ 300 #define TIMER15_CH0_PA6 \ 301 GD32_PINMUX_AF('A', 6, AF5) 302 #define TIMER15_CH0_PB8 \ 303 GD32_PINMUX_AF('B', 8, AF2) 304 305 /* TIMER15_CH0_ON */ 306 #define TIMER15_CH0_ON_PB6 \ 307 GD32_PINMUX_AF('B', 6, AF2) 308 309 /* TIMER16_BKIN */ 310 #define TIMER16_BKIN_PA10 \ 311 GD32_PINMUX_AF('A', 10, AF0) 312 313 /* TIMER16_CH0 */ 314 #define TIMER16_CH0_PA7 \ 315 GD32_PINMUX_AF('A', 7, AF5) 316 317 /* TIMER16_CH0_ON */ 318 #define TIMER16_CH0_ON_PB7 \ 319 GD32_PINMUX_AF('B', 7, AF2) 320 321 /* TIMER1_CH0 */ 322 #define TIMER1_CH0_PA0 \ 323 GD32_PINMUX_AF('A', 0, AF2) 324 #define TIMER1_CH0_PA5 \ 325 GD32_PINMUX_AF('A', 5, AF2) 326 #define TIMER1_CH0_PA15 \ 327 GD32_PINMUX_AF('A', 15, AF2) 328 329 /* TIMER1_CH1 */ 330 #define TIMER1_CH1_PA1 \ 331 GD32_PINMUX_AF('A', 1, AF2) 332 #define TIMER1_CH1_PB3 \ 333 GD32_PINMUX_AF('B', 3, AF2) 334 335 /* TIMER1_CH2 */ 336 #define TIMER1_CH2_PA2 \ 337 GD32_PINMUX_AF('A', 2, AF2) 338 339 /* TIMER1_CH3 */ 340 #define TIMER1_CH3_PA3 \ 341 GD32_PINMUX_AF('A', 3, AF2) 342 343 /* TIMER1_ETI */ 344 #define TIMER1_ETI_PA0 \ 345 GD32_PINMUX_AF('A', 0, AF2) 346 #define TIMER1_ETI_PA5 \ 347 GD32_PINMUX_AF('A', 5, AF2) 348 #define TIMER1_ETI_PA15 \ 349 GD32_PINMUX_AF('A', 15, AF2) 350 351 /* TIMER2_CH0 */ 352 #define TIMER2_CH0_PA6 \ 353 GD32_PINMUX_AF('A', 6, AF1) 354 #define TIMER2_CH0_PB4 \ 355 GD32_PINMUX_AF('B', 4, AF1) 356 357 /* TIMER2_CH1 */ 358 #define TIMER2_CH1_PA7 \ 359 GD32_PINMUX_AF('A', 7, AF1) 360 #define TIMER2_CH1_PB5 \ 361 GD32_PINMUX_AF('B', 5, AF1) 362 363 /* TIMER2_CH2 */ 364 #define TIMER2_CH2_PB0 \ 365 GD32_PINMUX_AF('B', 0, AF1) 366 367 /* TIMER2_CH3 */ 368 #define TIMER2_CH3_PB1 \ 369 GD32_PINMUX_AF('B', 1, AF1) 370 371 /* TSITG */ 372 #define TSITG_PB8 \ 373 GD32_PINMUX_AF('B', 8, AF3) 374 375 /* TSI_G0_IO0 */ 376 #define TSI_G0_IO0_PA0 \ 377 GD32_PINMUX_AF('A', 0, AF3) 378 379 /* TSI_G0_IO1 */ 380 #define TSI_G0_IO1_PA1 \ 381 GD32_PINMUX_AF('A', 1, AF3) 382 383 /* TSI_G0_IO2 */ 384 #define TSI_G0_IO2_PA2 \ 385 GD32_PINMUX_AF('A', 2, AF3) 386 387 /* TSI_G0_IO3 */ 388 #define TSI_G0_IO3_PA3 \ 389 GD32_PINMUX_AF('A', 3, AF3) 390 391 /* TSI_G1_IO0 */ 392 #define TSI_G1_IO0_PA4 \ 393 GD32_PINMUX_AF('A', 4, AF3) 394 395 /* TSI_G1_IO1 */ 396 #define TSI_G1_IO1_PA5 \ 397 GD32_PINMUX_AF('A', 5, AF3) 398 399 /* TSI_G1_IO2 */ 400 #define TSI_G1_IO2_PA6 \ 401 GD32_PINMUX_AF('A', 6, AF3) 402 403 /* TSI_G1_IO3 */ 404 #define TSI_G1_IO3_PA7 \ 405 GD32_PINMUX_AF('A', 7, AF3) 406 407 /* TSI_G2_IO1 */ 408 #define TSI_G2_IO1_PB0 \ 409 GD32_PINMUX_AF('B', 0, AF3) 410 411 /* TSI_G2_IO2 */ 412 #define TSI_G2_IO2_PB1 \ 413 GD32_PINMUX_AF('B', 1, AF3) 414 415 /* TSI_G2_IO3 */ 416 #define TSI_G2_IO3_PB2 \ 417 GD32_PINMUX_AF('B', 2, AF3) 418 419 /* TSI_G3_IO0 */ 420 #define TSI_G3_IO0_PA9 \ 421 GD32_PINMUX_AF('A', 9, AF3) 422 423 /* TSI_G3_IO1 */ 424 #define TSI_G3_IO1_PA10 \ 425 GD32_PINMUX_AF('A', 10, AF3) 426 427 /* TSI_G3_IO2 */ 428 #define TSI_G3_IO2_PA11 \ 429 GD32_PINMUX_AF('A', 11, AF3) 430 431 /* TSI_G3_IO3 */ 432 #define TSI_G3_IO3_PA12 \ 433 GD32_PINMUX_AF('A', 12, AF3) 434 435 /* TSI_G4_IO0 */ 436 #define TSI_G4_IO0_PB3 \ 437 GD32_PINMUX_AF('B', 3, AF3) 438 439 /* TSI_G4_IO1 */ 440 #define TSI_G4_IO1_PB4 \ 441 GD32_PINMUX_AF('B', 4, AF3) 442 443 /* TSI_G4_IO2 */ 444 #define TSI_G4_IO2_PB6 \ 445 GD32_PINMUX_AF('B', 6, AF3) 446 447 /* TSI_G4_IO3 */ 448 #define TSI_G4_IO3_PB7 \ 449 GD32_PINMUX_AF('B', 7, AF3) 450 451 /* USART0_CK */ 452 #define USART0_CK_PA4 \ 453 GD32_PINMUX_AF('A', 4, AF1) 454 #define USART0_CK_PA8 \ 455 GD32_PINMUX_AF('A', 8, AF1) 456 457 /* USART0_CTS */ 458 #define USART0_CTS_PA0 \ 459 GD32_PINMUX_AF('A', 0, AF1) 460 #define USART0_CTS_PA11 \ 461 GD32_PINMUX_AF('A', 11, AF1) 462 463 /* USART0_RTS */ 464 #define USART0_RTS_PA1 \ 465 GD32_PINMUX_AF('A', 1, AF1) 466 #define USART0_RTS_PA12 \ 467 GD32_PINMUX_AF('A', 12, AF1) 468 469 /* USART0_RX */ 470 #define USART0_RX_PA3 \ 471 GD32_PINMUX_AF('A', 3, AF1) 472 #define USART0_RX_PA10 \ 473 GD32_PINMUX_AF('A', 10, AF1) 474 #define USART0_RX_PA15 \ 475 GD32_PINMUX_AF('A', 15, AF1) 476 #define USART0_RX_PB7 \ 477 GD32_PINMUX_AF('B', 7, AF0) 478 479 /* USART0_TX */ 480 #define USART0_TX_PA2 \ 481 GD32_PINMUX_AF('A', 2, AF1) 482 #define USART0_TX_PA9 \ 483 GD32_PINMUX_AF('A', 9, AF1) 484 #define USART0_TX_PA14 \ 485 GD32_PINMUX_AF('A', 14, AF1) 486 #define USART0_TX_PB6 \ 487 GD32_PINMUX_AF('B', 6, AF0) 488 489 /* USBFS_ID */ 490 #define USBFS_ID_PA10 \ 491 GD32_PINMUX_AF('A', 10, AF5) 492 493 /* USBFS_SOF */ 494 #define USBFS_SOF_PA8 \ 495 GD32_PINMUX_AF('A', 8, AF5) 496 497 /* USBFS_VBUS */ 498 #define USBFS_VBUS_PA9 \ 499 GD32_PINMUX_AF('A', 9, AF5) 500