• spiiroin's avatar
    [modesetting] Replace questionable async timer with sleep loop. JB#42757 · 1d9e91e4
    spiiroin authored
    In case of network setup failure usb-moded utilizes glib timer to retry
    the operation once once after 3 second delay. How well that has worked is
    a bit questionable as the dynamic mode setup continues with things that
    probably require functional network. Also, while it used to be guaranteed
    that the timer would not trigger before the synchronous mode switch
    operations have finished, this is no longer guaranteed due to the use of
    worker thread for the mode switch.
    
    Use retry three times with one second delay between retries instead of
    relying on a three second asynchronous timer with hazardous triggering
    time and context.
    Signed-off-by: spiiroin's avatarSimo Piiroinen <simo.piiroinen@jollamobile.com>
    1d9e91e4
usb_moded-modesetting.c 27.3 KB