elan: Only queue state changes once
The driver would warn about the fact that a state change is queued, but still queue it a second time. This would result in deactivation to run twice. See: #216
This commit is contained in:
parent
32bdd8d5c4
commit
40ed353666
1 changed files with 4 additions and 1 deletions
|
@ -1015,7 +1015,10 @@ dev_change_state (FpImageDevice *dev, FpiImageDeviceState state)
|
||||||
state = FPI_IMAGE_DEVICE_STATE_INACTIVE;
|
state = FPI_IMAGE_DEVICE_STATE_INACTIVE;
|
||||||
|
|
||||||
if (self->dev_state_next == state)
|
if (self->dev_state_next == state)
|
||||||
|
{
|
||||||
fp_dbg ("change to state %d already queued", state);
|
fp_dbg ("change to state %d already queued", state);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
switch (state)
|
switch (state)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue