mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* Re: gpio-keys on barebox 2015.11
       [not found] <CAARUG94j21s-AC0-gXYG81SjnCa1ahPfH1oaq=fb+rFgEpSE8A@mail.gmail.com>
@ 2017-04-12 15:35 ` Zdenek Svachula
  2017-04-19  6:42   ` Sascha Hauer
  0 siblings, 1 reply; 6+ messages in thread
From: Zdenek Svachula @ 2017-04-12 15:35 UTC (permalink / raw)
  To: barebox

Hi all,

I'm working with barebox 2015.11 phy4 (from phytex.de) I try add to dts
        gpio_keys {
                compatible = "gpio-keys";
                #address-cells = <1>;
                #size-cells = <0>;
                autorepeat;
                up {
                                label = "GPIO Key up";
                                linux,code = <103>;
                                gpios = <&gpio2 24 1>;
                };
                enter {
                                label = "GPIO Key ENTER";
                                linux,code = <28>;
                                gpios = <&gpio5 8 1>;
                };


        };

to allow boot selection boot menu via 2 gpio button  I also enable
GPIO-buttons in menuconfig but it seem not workin.

Can you please me point to some method how to debug if gpio polling
works or if dts is for barebox wrong.

Zdenek S.

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gpio-keys on barebox 2015.11
  2017-04-12 15:35 ` gpio-keys on barebox 2015.11 Zdenek Svachula
@ 2017-04-19  6:42   ` Sascha Hauer
  2017-04-19  8:49     ` Zdenek Svachula
  0 siblings, 1 reply; 6+ messages in thread
From: Sascha Hauer @ 2017-04-19  6:42 UTC (permalink / raw)
  To: Zdenek Svachula; +Cc: barebox

On Wed, Apr 12, 2017 at 05:35:46PM +0200, Zdenek Svachula wrote:
> Hi all,
> 
> I'm working with barebox 2015.11 phy4 (from phytex.de) I try add to dts
>         gpio_keys {
>                 compatible = "gpio-keys";
>                 #address-cells = <1>;
>                 #size-cells = <0>;
>                 autorepeat;
>                 up {
>                                 label = "GPIO Key up";
>                                 linux,code = <103>;
>                                 gpios = <&gpio2 24 1>;
>                 };
>                 enter {
>                                 label = "GPIO Key ENTER";
>                                 linux,code = <28>;
>                                 gpios = <&gpio5 8 1>;
>                 };
> 
> 
>         };
> 
> to allow boot selection boot menu via 2 gpio button  I also enable
> GPIO-buttons in menuconfig but it seem not workin.
> 
> Can you please me point to some method how to debug if gpio polling
> works or if dts is for barebox wrong.

Generally the above looks ok and should work like this. Try 'devinfo'
command and identify the gpio-keys device (usually named gpio-keys.<x>).
Use 'devinfo gpio-keys.<x>' to find out if there is a driver attached to
this device. If there isn't, do you find something about gpio-keys in
the boot log?

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gpio-keys on barebox 2015.11
  2017-04-19  6:42   ` Sascha Hauer
@ 2017-04-19  8:49     ` Zdenek Svachula
  2017-04-19  9:50       ` Sascha Hauer
  0 siblings, 1 reply; 6+ messages in thread
From: Zdenek Svachula @ 2017-04-19  8:49 UTC (permalink / raw)
  To: Sascha Hauer; +Cc: barebox

Hi Sascha,

My board is  Phytec phyFLEX-i.MX6 Quad Carrier-Board.
I look to commit 7a037a952da8083e2eddcb2b2e180f0629e83758 Author:
Sascha Hauer <s.hauer@pengutronix.de>
Date:   Fri Feb 14 11:55:02 2014 +0100

    input: gpio-keys: Add devicetree probe support

    Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>

that seem ok.
I look also in boot-up info that nothing indicate that gpio-keys
driver is loaded

I loog to .config that seem be ok
(from my .config)
#
# Drivers
#
CONFIG_OFTREE=y
CONFIG_OFTREE_MEM_GENERIC=y
CONFIG_DTC=y
CONFIG_OFDEVICE=y
CONFIG_OF_NET=y
CONFIG_OF_GPIO=y
CONFIG_OF_BAREBOX_DRIVERS=y

rereading to changes in arch/arm/boards/archosg9 and commit 28ce80f5
it seems that some parts missing in phtec ini sequence but I'm not
sure about it.

Thaks you

Zdenek
___________________________
zdenek.svachula@medictech.com


On Wed, Apr 19, 2017 at 8:42 AM, Sascha Hauer <s.hauer@pengutronix.de> wrote:
> On Wed, Apr 12, 2017 at 05:35:46PM +0200, Zdenek Svachula wrote:
>> Hi all,
>>
>> I'm working with barebox 2015.11 phy4 (from phytex.de) I try add to dts
>>         gpio_keys {
>>                 compatible = "gpio-keys";
>>                 #address-cells = <1>;
>>                 #size-cells = <0>;
>>                 autorepeat;
>>                 up {
>>                                 label = "GPIO Key up";
>>                                 linux,code = <103>;
>>                                 gpios = <&gpio2 24 1>;
>>                 };
>>                 enter {
>>                                 label = "GPIO Key ENTER";
>>                                 linux,code = <28>;
>>                                 gpios = <&gpio5 8 1>;
>>                 };
>>
>>
>>         };
>>
>> to allow boot selection boot menu via 2 gpio button  I also enable
>> GPIO-buttons in menuconfig but it seem not workin.
>>
>> Can you please me point to some method how to debug if gpio polling
>> works or if dts is for barebox wrong.
>
> Generally the above looks ok and should work like this. Try 'devinfo'
> command and identify the gpio-keys device (usually named gpio-keys.<x>).
> Use 'devinfo gpio-keys.<x>' to find out if there is a driver attached to
> this device. If there isn't, do you find something about gpio-keys in
> the boot log?
>
> Sascha
>
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gpio-keys on barebox 2015.11
  2017-04-19  8:49     ` Zdenek Svachula
@ 2017-04-19  9:50       ` Sascha Hauer
       [not found]         ` <CAARUG96Bij4emjci_EO=yzeus22omFK_ajBH4d0muc=ViEMrAA@mail.gmail.com>
  0 siblings, 1 reply; 6+ messages in thread
From: Sascha Hauer @ 2017-04-19  9:50 UTC (permalink / raw)
  To: Zdenek Svachula; +Cc: barebox

On Wed, Apr 19, 2017 at 10:49:48AM +0200, Zdenek Svachula wrote:
> Hi Sascha,
> 
> My board is  Phytec phyFLEX-i.MX6 Quad Carrier-Board.
> I look to commit 7a037a952da8083e2eddcb2b2e180f0629e83758 Author:
> Sascha Hauer <s.hauer@pengutronix.de>
> Date:   Fri Feb 14 11:55:02 2014 +0100
> 
>     input: gpio-keys: Add devicetree probe support
> 
>     Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> 
> that seem ok.
> I look also in boot-up info that nothing indicate that gpio-keys
> driver is loaded
> 
> I loog to .config that seem be ok
> (from my .config)
> #
> # Drivers
> #
> CONFIG_OFTREE=y
> CONFIG_OFTREE_MEM_GENERIC=y
> CONFIG_DTC=y
> CONFIG_OFDEVICE=y
> CONFIG_OF_NET=y
> CONFIG_OF_GPIO=y
> CONFIG_OF_BAREBOX_DRIVERS=y
> 
> rereading to changes in arch/arm/boards/archosg9 and commit 28ce80f5
> it seems that some parts missing in phtec ini sequence but I'm not
> sure about it.

Have you looked at the output of devinfo like described in my last mail?
Also you can look at the output of of_dump to see if your new device
node made it to the runtime device tree.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Fwd: gpio-keys on barebox 2015.11
       [not found]         ` <CAARUG96Bij4emjci_EO=yzeus22omFK_ajBH4d0muc=ViEMrAA@mail.gmail.com>
@ 2017-04-19 10:56           ` Zdenek Svachula
  2017-04-19 10:56           ` Sascha Hauer
  1 sibling, 0 replies; 6+ messages in thread
From: Zdenek Svachula @ 2017-04-19 10:56 UTC (permalink / raw)
  To: barebox

Hi Sascha

yes. I look in these
I also  enable initcall debug output and see
initcall-> at25_driver_register+0x1/0x14
initcall-> at24_init+0x1/0x18
initcall-> gpio_keys_driver_register+0x1/0xc
initcall-> imx_keypad_driver_register+0x1/0xc
initcall-> imx_wd_driver_register+0x1/0xc
initcall-> null_init+0x1/0x24

in of_dump is nothing about gpio_keys
drvinfo:
at24
        24c320
gpio_keys
imx-kpp
imx-watchdog
        20bc000.wdog
mem

barebox@Phytec phyFLEX-i.MX6 Quad Carrier-Board:/ devinfo gpio_keys
devinfo: No such device


Thanks you
Zdenek

On Wed, Apr 19, 2017 at 11:50 AM, Sascha Hauer <s.hauer@pengutronix.de> wrote:
>
> On Wed, Apr 19, 2017 at 10:49:48AM +0200, Zdenek Svachula wrote:
> > Hi Sascha,
> >
> > My board is  Phytec phyFLEX-i.MX6 Quad Carrier-Board.
> > I look to commit 7a037a952da8083e2eddcb2b2e180f0629e83758 Author:
> > Sascha Hauer <s.hauer@pengutronix.de>
> > Date:   Fri Feb 14 11:55:02 2014 +0100
> >
> >     input: gpio-keys: Add devicetree probe support
> >
> >     Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> >
> > that seem ok.
> > I look also in boot-up info that nothing indicate that gpio-keys
> > driver is loaded
> >
> > I loog to .config that seem be ok
> > (from my .config)
> > #
> > # Drivers
> > #
> > CONFIG_OFTREE=y
> > CONFIG_OFTREE_MEM_GENERIC=y
> > CONFIG_DTC=y
> > CONFIG_OFDEVICE=y
> > CONFIG_OF_NET=y
> > CONFIG_OF_GPIO=y
> > CONFIG_OF_BAREBOX_DRIVERS=y
> >
> > rereading to changes in arch/arm/boards/archosg9 and commit 28ce80f5
> > it seems that some parts missing in phtec ini sequence but I'm not
> > sure about it.
>
> Have you looked at the output of devinfo like described in my last mail?
> Also you can look at the output of of_dump to see if your new device
> node made it to the runtime device tree.
>
> Sascha
>
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gpio-keys on barebox 2015.11
       [not found]         ` <CAARUG96Bij4emjci_EO=yzeus22omFK_ajBH4d0muc=ViEMrAA@mail.gmail.com>
  2017-04-19 10:56           ` Fwd: " Zdenek Svachula
@ 2017-04-19 10:56           ` Sascha Hauer
  1 sibling, 0 replies; 6+ messages in thread
From: Sascha Hauer @ 2017-04-19 10:56 UTC (permalink / raw)
  To: Zdenek Svachula; +Cc: barebox

Hi Zdenek,

On Wed, Apr 19, 2017 at 12:39:14PM +0200, Zdenek Svachula wrote:
>    Hi Sascha
> 
>    yes. I look in these
>    I also  enable initcall debug output and see
>    initcall-> at25_driver_register+0x1/0x14
>    initcall-> at24_init+0x1/0x18
>    initcall-> gpio_keys_driver_register+0x1/0xc
>    initcall-> imx_keypad_driver_register+0x1/0xc
>    initcall-> imx_wd_driver_register+0x1/0xc
>    initcall-> null_init+0x1/0x24
> 
>    in of_dump is nothing about gpio_keys
>    drvinfo:
>    at24
>            24c320
>    gpio_keys
>    imx-kpp
>    imx-watchdog
>            20bc000.wdog
>    mem
> 
>    barebox@Phytec phyFLEX-i.MX6 Quad Carrier-Board:/ devinfo gpio_keys
>    devinfo: No such device

Maybe you have modified the wrong dts file. Which one have you modified?
Just to be sure: You modified some dts file in the barebox source tree,
compiled barebox and started the resulting binary, right?

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-04-19 10:56 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAARUG94j21s-AC0-gXYG81SjnCa1ahPfH1oaq=fb+rFgEpSE8A@mail.gmail.com>
2017-04-12 15:35 ` gpio-keys on barebox 2015.11 Zdenek Svachula
2017-04-19  6:42   ` Sascha Hauer
2017-04-19  8:49     ` Zdenek Svachula
2017-04-19  9:50       ` Sascha Hauer
     [not found]         ` <CAARUG96Bij4emjci_EO=yzeus22omFK_ajBH4d0muc=ViEMrAA@mail.gmail.com>
2017-04-19 10:56           ` Fwd: " Zdenek Svachula
2017-04-19 10:56           ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox