Re: [PATCH 10/11] VF610: zii-vf610-dev: Replace board code with gpio-hog nodes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Oct 29, 2018 at 4:13 AM Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> wrote:
>
> On Fri, Oct 26, 2018 at 06:31:56PM -0700, Andrey Smirnov wrote:
> > diff --git a/arch/arm/dts/vf610-zii-cfu1.dts b/arch/arm/dts/vf610-zii-cfu1.dts
> > index 149333596..74ec9fd1d 100644
> > --- a/arch/arm/dts/vf610-zii-cfu1.dts
> > +++ b/arch/arm/dts/vf610-zii-cfu1.dts
> > @@ -19,3 +19,28 @@
> >       };
> >  };
> >
> > +
> > +&gpio3 {
> > +     fim-tdis {
> > +             gpio-hog;
> > +             gpios = <22 GPIO_ACTIVE_HIGH>;
> > +             output-low;
> > +             line-name = "fim_tdis";
> > +     };
> > +
> > +     e6352-intn {
> > +             gpio-hog;
> > +             gpios = <2 GPIO_ACTIVE_HIGH>;
> > +             input;
> > +             line-name = "e6352_intn";
> > +     };
> > +};
> > +
> > +&gpio4 {
> > +     fim-sd {
> > +             gpio-hog;
> > +             gpios = <4 GPIO_ACTIVE_HIGH>;
> > +             input;
> > +             line-name = "fim_sd";
> > +     };
> > +};
>
> Hog GPIOs are GPIOs that are initialized once in the Kernel and from
> then on can never be changed. Is this true for these GPIOs you change
> here? I just want to make sure that you do not use gpio-hog in barebox
> to configure it and do something different in the Kernel because you
> pass another devicetree to the kernel. Or, to put it differently, you
> should be able to pass the barebox devicetree to Linux and still have
> a fully operating system.
>

Those GPIOs are exposed for debugging/board bringup purposes mostly:
"fim_*" are "signal detect" and "tx disable" signals from an fiber
optic transmitter module and "e6352_intn" is an interrupt line from
Marvell switch. Linux kernel has appropriate drivers that "consume"
those GPIOs, so passing BB's DT might result in conflicts in those
drivers (I am not 100% sure), so this is probably a violation of the
rule you laid out above.

This is not really crucial code to have in general, so I'll move the
DT changes out into a separate patch that I can carry in our upstream
patch delta (It'll probably be dropped eventually).

Thanks,
Andrey Smirnov

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



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux