restorecon:  Only call setfilecon if the context is not already correct.

We already have this optimization in the libselinux and toolbox
restorecon code.  I think it was omitted from the init built-in
because originally we only applied it to individual files (not
recursively) and only when we knew the context would not be correct
in the first place.  Regardless, getfilecon() should be less
expensive than setfilecon() even when setting the same value,
and the common case should be that the file has the right context
already.

Change-Id: Icc1dcf6968429b7519aafea4972ed422eb8f413d
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
restorecon:  Avoid extra stat calls.

nftw/fts already perform lstat of the file and provide the
sb structure, so do not stat it again.  Refactor restorecon
into a common helper so that we can avoid the extra stat calls
on recursive restorecon.  This is already correct in the toolbox
restorecon.

Change-Id: Id0dd4c28d4f1cd774f88694af92acb76366193b7
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
Add required permissions and files for data

 - Add /data/radio
 - Set gateway property after DNS
 - Allow radio users to set properties associated with
   all rmnet interfaces. Not just rmnet0

Change-Id: Ia60fcb8f90aa73ffd40e839b93356ee50a9e5072
restorecon_recursive("/sys") speed boot time

Currently, the restorecon_recursive("/sys") call in
init.c takes approx 2 seconds on hammerhead. This change
reduces the delay to 1.2 seconds.

1) Avoid double stat call when using nftw (time savings
of 0.3 seconds)
2) Avoid the repeated calls to is_selinux_enabled() (time
savings of 0.5 seconds)

Avoid calling lsetfilecon if the file is already properly
labeled. This doesn't speed up the restorecon on /sys,
but it should help when handling files on /data.

Bug: 11640230
Change-Id: Ie212ce4f4acade208c5676d60c1f03f50e2388a4

Conflicts:
	init/util.c