Fix: SIGPIPE issue while querying softap enabled status

Before downloading commands to driver through softap SDK we are
checking if SoftAP is enabled are not by running ps in popen.
This sometime throws SIGPIPE error (signal) which is not handled,
due to this we were facing application crash. To fix this we modify
to check the operation mode of the driver through ioctl.

Change-Id: Ia0703ff343d401801655d3b666ade66107a4789e
CRs-Fixed: 535340