> Op 25 okt. 2014, om 09:14 heeft Antal Koós <[email protected]> het volgende 
> geschreven:
> 
> 
> 
> On Saturday, October 25, 2014 6:36:43 AM UTC+2, Jhon Yi wrote:
> >I think you can just add a config file in user space program to achieve 
> >this. 
> 
> This would change nothing, in every new distrib/version the config file must 
> be corrected.
> The kernel, the most authenticated source should make a "config file" in the 
> /proc.

Or, you know, in debugfs:

root@thing:~# cat /sys/kernel/debug/gpio 
GPIOs 0-31, gpio:
 gpio-6   (mmc_cd              ) in  hi IRQ

GPIOs 32-63, gpio:
 gpio-53  (beaglebone:green:hea) out lo    
 gpio-54  (beaglebone:green:mmc) out lo    
 gpio-55  (beaglebone:green:usr) out hi    
 gpio-56  (beaglebone:green:usr) out lo    

GPIOs 64-95, gpio:

GPIOs 96-127, gpio:

It did change a bit in recent kernels (iirc 3.16+):

root@arietta-g25:~# cat /sys/kernel/debug/gpio 
GPIOs 0-31, platform/fffff400.gpio, fffff400.gpio:
[spi32766.1] GPIOfffff400.gpio0: [gpio] set

GPIOs 32-50, platform/fffff600.gpio, fffff600.gpio:
[arietta_led] GPIOfffff600.gpio8: [gpio] clear

GPIOs 64-95, platform/fffff800.gpio, fffff800.gpio:
[arietta_key] GPIOfffff800.gpio17: [gpio] set

GPIOs 96-117, platform/fffffa00.gpio, fffffa00.gpio:

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to