TEST: change sysfs permission as 'network_fw'
authorsaerome.kim <saerome.kim@samsung.com>
Thu, 8 Feb 2018 07:55:43 +0000 (16:55 +0900)
committersaerome.kim <saerome.kim@samsung.com>
Thu, 8 Feb 2018 07:55:43 +0000 (16:55 +0900)
Change-Id: I901391ecaebadf0651bd8db19483bdbaf0018c6d
Signed-off-by: saerome.kim <saerome.kim@samsung.com>
files/99-wifi-mesh.rules [new file with mode: 0644]
packaging/wifi-mesh-manager.spec

diff --git a/files/99-wifi-mesh.rules b/files/99-wifi-mesh.rules
new file mode 100644 (file)
index 0000000..bbf752c
--- /dev/null
@@ -0,0 +1 @@
+KERNEL=="wlan*", SUBSYSTEM=="net", RUN+="/bin/sh -c '/bin/chown network_fw:network_fw /sys/class/net/br*/bridge/forward_delay'" 
index 305c1bf..06afe28 100644 (file)
@@ -58,6 +58,9 @@ rm -rf %{buildroot}
 
 %make_install
 
+mkdir -p %{buildroot}/%{_prefix}/lib/udev/rules.d
+cp files/99-wifi-mesh.rules %{buildroot}/%{_prefix}/lib/udev/rules.d/99-wifi-mesh.rules
+
 %if %{CHECK_WMESH_PRIVILEGE} == "True"
 mkdir -p %{buildroot}%{_sysconfdir}/dbus-1/system.d
 cp wmeshd.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/wmeshd.conf
@@ -74,10 +77,11 @@ chmod 755 %{_sbindir}/wmesh.sh
 %manifest wmeshd.manifest
 %license LICENSE
 %defattr(-,root,root,-)
+%{_prefix}/lib/udev/rules.d/99-wifi-mesh.rules
 %attr(750,network_fw,network_fw) %{_bindir}/wmeshd
 %if %{CHECK_WMESH_PRIVILEGE} == "True"
 %config %{_sysconfdir}/dbus-1/system.d/wmeshd.conf
 %endif
-%attr(644,root,root) %{_datadir}/dbus-1/system-services/*
+%attr(644,network_fw,network_fw) %{_datadir}/dbus-1/system-services/*
 %attr(644,root,root) %{_unitdir}/wmeshd.service
 %attr(750,root,root) %{_sbindir}/wmesh.sh