#include "cape-atp.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>

&soc {
	gpio_keys {
		compatible = "gpio-keys";
		label = "gpio-keys";

		pinctrl-names = "default";
		pinctrl-0 = <&key_vol_up_default>;

		vol_up {
			label = "volume_up";
			gpios = <&pm8350_gpios 6 GPIO_ACTIVE_LOW>;
			linux,input-type = <1>;
			linux,code = <KEY_VOLUMEUP>;
			gpio-key,wakeup;
			debounce-interval = <15>;
			linux,can-disable;
		};
	};
};

&pm8350b_haptics {
	qcom,vmax-mv = <1300>;
	qcom,lra-period-us = <5880>;
	status = "ok";

	effect_0 {
		/* CLICK */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};

	effect_1 {
		/* DOUBLE_CLICK */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};

	effect_2 {
		/* TICK */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};

	effect_3 {
		/* THUD */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};

	effect_4 {
		/* POP */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};

	effect_5 {
		/* HEAVY CLICK */
		qcom,wf-vmax-mv = <1800>;
		qcom,wf-pattern-period-us = <5880>;
	};
};

&pm8350c_switch0 {
	qcom,led-mask = <9>; /* Channels 1 & 4 */
	qcom,symmetry-en;
};

&pm8350c_switch1 {
	qcom,led-mask = <6>; /* Channels 2 & 3 */
	qcom,symmetry-en;
};

&pm8350c_switch2 {
	qcom,led-mask = <15>; /* All Channels */
	qcom,symmetry-en;
};

&pm8350c_flash {
	status = "ok";
};

&battery_charger {
	qcom,thermal-mitigation = <11500000 11000000 10500000 10000000 9500000
				9000000 8500000 8000000 7500000 7000000 6500000
				6000000 5500000 5000000 4500000 4000000 3500000
				3000000 2500000 2000000 1500000 1000000 500000>;
	qcom,wireless-fw-name = "idt9415.bin";
};
