- diff --git a/arch/arm/boards/eag-mx25/board.c b/arch/arm/boards/eag-mx25/board.c
- index f581454c1a8f..beb45c01768d 100644
- --- a/arch/arm/boards/eag-mx25/board.c
- +++ b/arch/arm/boards/eag-mx25/board.c
- @@ -11,6 +11,7 @@
- #include <mach/imxfb.h>
- #include <mach/devices-imx25.h>
- #include <gpio.h>
- +#include <i2c/i2c.h>
- static int imx25_eag_pmic_init(void)
- {
- @@ -27,6 +28,33 @@ static int imx25_eag_pmic_init(void)
- }
- late_initcall(imx25_eag_pmic_init);
- +static int imx25_eag_check_osci_stop(void)
- +{
- + int ret=0;
- + struct i2c_adapter *adapter = NULL;
- + struct i2c_client client;
- + u8 buf;
- +
- + adapter = i2c_get_adapter(0);
- + if (!adapter) {
- + return -ENODEV;
- + }
- +
- + client.adapter = adapter;
- + client.addr = 0x51;
- +
- + ret = i2c_read_reg(&client, 0x02, &buf, 1);
- + if (ret == 1) {
- + if( buf & 0x80 ){
- + printf("Osci stop bit is set\n");
- + return 1;
- + }
- + }
- +
- + return 0;
- +}
- +late_initcall(imx25_eag_check_osci_stop);
- +
- static const iomux_v3_cfg_t imx25_eag_ci4000_lcdc_pins[] = {
- MX25_PAD_LD0__LD0,
- MX25_PAD_LD1__LD1,
check osci flag
Posted by Anonymous on Mon 11th Mar 2019 16:05
raw | new post
Submit a correction or amendment below (click here to make a fresh posting)
After submitting an amendment, you'll be able to view the differences between the old and new posts easily.