wpa_cli ping-pong and power management

Jouni Malinen j at w1.fi
Fri Oct 31 09:32:50 EDT 2008


On Sun, Oct 19, 2008 at 11:43:37AM +0200, Alon Bar-Lev wrote:

> wpa_cli use alarm(1) in order to ping/pong the daemon.
> This wakes up both processes once a seconds which consumes power.
> Can you please find a different way for keep alive? Why not wait for fd close?

This is used in the interactive mode as a simple mechanism to fetch any
pending message and to notice if the connection to wpa_supplicant has
died. It is not strictly speaking required and for example, Windows
build of wpa_cli does not use it. The drawback there is that user will
need to press enter to get wpa_cli to fetch any potentially received
messages.

wpa_cli is supposed to be a simple example program and command line tool
that can be used to interact with wpa_supplicant. In what kind of usage
case do you see this type of polling as an issue? I'm somewhat surprised
if one were to run wpa_cli in interactive mode all the time..

-- 
Jouni Malinen                                            PGP id EFC895FA


More information about the HostAP mailing list