Commit 1fe184c8 authored by Russell King's avatar Russell King

[PCMCIA] Prevent duplicate insertion events calling socket_insert()

Some socket hardware appears to "bounce" when a card is inserted - we
seem to receive more than one SS_DETECT event.  Unfortunately, this
causes us to initialise, setup the socket, and create the necessary
devices multiple times.

Fix this by ignoring card insertion events when we already know that
there is a card in the socket.
parent fc4833a2
......@@ -816,7 +816,8 @@ static int pccardd(void *__skt)
if ((skt->state & SOCKET_PRESENT) &&
!(status & SS_DETECT))
socket_shutdown(skt);
if (status & SS_DETECT)
if (!(skt->state & SOCKET_PRESENT) &&
(status & SS_DETECT))
socket_insert(skt);
}
if (events & SS_BATDEAD)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment