1.修改menuconfig文件
2.DTS文件的修改
修改的后的文件为:
/*
* Copyright (C) 2015 Freescale Semiconductor, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/
/dts-v1/;
#include <dt-bindings/input/input.h>
#include "imx6g2c-base.dtsi"
/ {
model = "ZLG EPC-M6G2C Board";
compatible = "fsl,imx6ul-14x14-evk", "fsl,imx6ul";
chosen {
stdout-path = &uart1;
};
memory {
reg = <0x80000000 0x10000000>; /* 256M */
};
reserved-memory {
#address-cells = <1>;
#size-cells = <1>;
ranges;
linux,cma {
compatible = "shared-dma-pool";
reusable;
size = <0x2000000>; /* 32M */
linux,cma-default;
};
};
watchdog: watchdog {
compatible = "cat82x-gpio-wdt";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_wdt>;
gpios = <&gpio5 0 0>;
hw_margin_ms = <700>;
};
backlight {
compatible = "pwm-backlight";
pwms = <&pwm5 0 5000000>;
brightness-levels = <0 4 8 16 32 64 128 255>;
default-brightness-level = <7>;
status = "okay";
};
beep {
compatible = "pwm-leds";
beep-leds {
label = "beeper-pwm";
pwms = <&pwm6 0 400000>;
max-brightness = <127>;
};
};
pxp_v4l2 {
compatible = "fsl,imx6ul-pxp-v4l2", "fsl,imx6sx-pxp-v4l2", "fsl,imx6sl-pxp-v4l2";
status = "okay";
};
/*
sound-mqs {
compatible = "fsl,imx-audio-mqs";
model = "mqs-audio";
cpu-dai = <&sai1>;
asrc-controller = <&asrc>;
audio-codec = <&mqs>;
};
*/
leds {
compatible = "gpio-leds";
green-led {
label = "led-run";
gpios = <&gpio4 16 1>;
linux,default-trigger = "heartbeat";
};
red-led {
label = "led-err";
gpios = <&gpio4 14 1>;
default-state = "keep";
};
};
/* add by Codebreaker */
regulators {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <0>;
reg_3p3v: 3p3v {
compatible = "regulator-fixed";
regulator-name = "3P3V";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-always-on;
};
reg_1p8v: 1p8v {
compatible = "regulator-fixed";
regulator-name = "1P8V";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};
};
i2c_gpio: analog-i2c {
compatible = "i2c-gpio";
gpios = <&gpio5 8 0 /* sda */
&gpio5 7 0 /* scl */
>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c>;
i2c-gpio,delay-us = <5>;
i2c-gpio,timeout-ms = <100>;
#address-cells = <1>;
#size-cells = <0>;
rtc@51 {
compatible = "nxp,pcf85063";
reg = <0x51>;
};
adv7180: adv7180@20 {
compatible = "adv,adv7180";
reg = <0x20>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_csi0>;
clocks = <&clks IMX6UL_CLK_CSI>;
clock-names = "csi_mclk";
DOVDD-supply = <®_3p3v>;
AVDD-supply = <®_1p8v>;
DVDD-supply = <®_1p8v>;
PVDD-supply = <®_1p8v>;
pwn-gpios = <&gpio5 6 0>;
rst-gpios = <&gpio5 5 0>;
csi_id = <0>;
mclk = <22000000>;
mclk_source = <0>;
cvbs = <1>;
status = "disabled";
port {
adv7180_ep: adv-endpoint {
remote-endpoint = <&csi1_ep>;
};
};
};
};
/*
gpio_keys {
compatible = "gpio-keys";
#address-cells = <1>;
#size-cells = <0>;
autorepeat;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_gpiokey>;
button0 {
label = "up";
linux,code = <171>;
gpios = <&gpio3 28 GPIO_ACTIVE_LOW>;
};
button1 {
label = "d