mirror of
https://git.yoctoproject.org/poky
synced 2026-05-09 05:29:32 +00:00
busybox/find-touchscreen.sh: Simplify script and recognize USB devices
Simplify the grep expression, use the more common "grep" command instead of "egrep", avoid forking extra processes, join multiple invokations into a single combined expression. Change the touchscreen regex so that it also recognizes various USB touchscreen controllers and the ad7879 i2c device. Based on code used in OpenPLi and meta-topic. (From OE-Core rev: e82353eb9f76b582122fda27c93339eac5553eb2) Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
f50c622239
commit
f9392a539e
@@ -1,9 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ `egrep "input:.*-e0.*,3,.*a0,1,.*18,.*" /sys/class/input/$MDEV/device/modalias|wc -l` -gt 0 ]; then
|
||||
ln -sf /dev/input/$MDEV /dev/input/touchscreen0
|
||||
if grep -q "input:.*-e0.*,3,.*a0,1,\|ads7846" /sys/class/$MDEV/device/modalias ; then
|
||||
ln -sf /dev/$MDEV /dev/input/touchscreen0
|
||||
fi
|
||||
|
||||
if [ `egrep "ads7846" /sys/class/input/$MDEV/device/modalias|wc -l` -gt 0 ]; then
|
||||
ln -sf /dev/input/$MDEV /dev/input/touchscreen0
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user