Path: blob/master/arch/riscv/boot/dts/spacemit/k1-pinctrl.dtsi
26513 views
// SPDX-License-Identifier: GPL-2.0 OR MIT /* * Copyright (c) 2024 Yixun Lan <[email protected]> */ #include <dt-bindings/gpio/gpio.h> #define K1_PADCONF(pin, func) (((pin) << 16) | (func)) /* Map GPIO pin to each bank's <index, offset> */ #define K1_GPIO(x) (x / 32) (x % 32) &pinctrl { uart0_2_cfg: uart0-2-cfg { uart0-2-pins { pinmux = <K1_PADCONF(68, 2)>, <K1_PADCONF(69, 2)>; bias-pull-up = <0>; drive-strength = <32>; }; }; pwm14_1_cfg: pwm14-1-cfg { pwm14-1-pins { pinmux = <K1_PADCONF(44, 4)>; bias-pull-up = <0>; drive-strength = <32>; }; }; };