1. 18 Jan, 2004 3 commits
    • Russell King's avatar
      [PCMCIA] Remove write-only socket_dev · 393f4a7b
      Russell King authored
      No need for a local pointer for the struct device, especially when
      it is only ever written.  If necessary, the device can be accessed
      using s->parent->dev.dev
      393f4a7b
    • Russell King's avatar
      [PCMCIA] Get rid of racy interruptible_sleep_on() · 64baa00b
      Russell King authored
      ds.c uses interruptible_sleep_on() without any protection.  Use
      wait_event_interruptible() instead.
      
      In addition, fix a bug where threads waiting for cardmgr events to
      complete were left waiting if cardmgr exited.
      64baa00b
    • Russell King's avatar
      [PCMCIA] Add refcounting to struct pcmcia_bus_socket · 3b32a7e7
      Russell King authored
      If you perform the following commands in order:
      
       # cardctl eject
       # rmmod yenta_socket
       # insmod drivers/pcmcia/yenta_socket.ko
       # killall cardmgr
      
      the rmmod ends up freeing the pcmcia_bus_socket while the wait
      queue is still active.  The killall cardmgr cases the the select()
      to complete, and users to be removed from the "queue" - which ends
      up writing to freed memory.
      
      The following patch adds refcounting to pcmcia_bus_socket so we
      won't free it until all users have gone.  We also add "SOCKET_DEAD"
      to mark the condition where the socket is no longer present in the
      system.
      
      Note that we don't wake up cardmgr when we remove sockets -
      unfortunately cardmgr doesn't like receiving errors from read().
      Really, cardmgr should treat EIO from read() as a fatal error
      for that socket, and stop listening for events from it.
      3b32a7e7
  2. 15 Jan, 2004 15 commits
  3. 14 Jan, 2004 22 commits