Просмотр исходного кода

procd: start additional consoles during hotplugging

Now that 'start-console' procd command has reached the main repo,
we can add a rule to start consoles on serial devices which are
created when USB gadget driver reports creation with hotplugging.

Signed-off-by: Michael Heimpold <[email protected]>
Michael Heimpold 6 лет назад
Родитель
Сommit
2249780fb7
2 измененных файлов с 5 добавлено и 1 удалено
  1. 1 1
      package/system/procd/Makefile
  2. 4 0
      package/system/procd/files/hotplug.json

+ 1 - 1
package/system/procd/Makefile

@@ -8,7 +8,7 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=procd
-PKG_RELEASE:=3
+PKG_RELEASE:=4
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL=$(PROJECT_GIT)/project/procd.git

+ 4 - 0
package/system/procd/files/hotplug.json

@@ -37,6 +37,10 @@
 					[ "load-firmware", "/lib/firmware" ],
 					[ "return" ]
 				]
+			],
+			[ "if",
+				[ "regex", "DEVNAME", "^ttyGS" ],
+				[ "start-console", "%DEVNAME%" ]
 			]
 		],
 		"remove" : [