1. 22 Nov, 2004 10 commits
  2. 21 Nov, 2004 24 commits
  3. 20 Nov, 2004 6 commits
    • Linus Torvalds's avatar
      Merge bk://bk.arm.linux.org.uk/linux-2.6-pcmcia · 36aed6eb
      Linus Torvalds authored
      into ppc970.osdl.org:/home/torvalds/v2.6/linux
      36aed6eb
    • Michal Rokos's avatar
      [PCMCIA] Exclude uneeded code when ! CONFIG_PROC_FS · 7b89a607
      Michal Rokos authored
      Patch from Michal Rokos
      
      proc_pccard is declared twice, so remove the first declaration such
      that it is only in ifdef CONFIG_PROC_FS block.
      Signed-off-by: default avatarRussell King <rmk@arm.linux.org.uk>
      7b89a607
    • Adrian Bunk's avatar
      [PCMCIA] make cardbus_type static · 7d5e9e6a
      Adrian Bunk authored
      Patch from Adrian Bunk
      
      Since there's no user outside this file, cardbus_type in
      drivers/pcmcia/yenta_socket.c can be made static.
      
      Signed-off-by: Adrian Bunk
      Signed-off-by: Russell King
      7d5e9e6a
    • Maximilian Attems's avatar
      [PCMCIA] replace schedule_timeout() with msleep() · 2590f545
      Maximilian Attems authored
      Use msleep() instead of schedule_timeout() to guarantee the
      task delays as expected.
      
      Signed-off-by: Nishanth Aravamudan
      Signed-off-by: Maximilian Attems
      Signed-off-by: default avatarRussell King <rmk@arm.linux.org.uk>
      2590f545
    • Alexander Kern's avatar
      [PATCH] USB quirk section fix · c74dbc6c
      Alexander Kern authored
      usb_early_handoff is referenced from __devinit and hence should be
      __devinitdata.
      Acked-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      c74dbc6c
    • Andreas Gruenbacher's avatar
      [PATCH] compat_sys_fcntl[64] contain superfluous, buggy test · 2761f394
      Andreas Gruenbacher authored
      here is a fix to a previous ChangeSet from John; 32-bit emulation of flock(fd,
      F_GETLK, &lock) currently is broken.
      
      The ChangeSet:
      http://linux.bkbits.net:8080/linux-2.5/cset%404152257aJKu1UClRcfvhsK6IjGYSeQ?nav=index.html|ChangeSet@-12w
      from John Engel <jhe@us.ibm.com> fixes an off-by-one error and according
      to the ChangeSet comment, it also contains a fix to handle l_len < 0 which
      is now defined in POSIX 1003.1-2001 from the fcntl man page.
      
      Gordon Jin <gordon.jin@intel.com> reports that the added test causes
      compat_sys_fcntl[64] to fail: If fcntl(fd, F_GETLK, &lock) finds no
      conflicting lock it sets l_whence to F_UNLCK, leaves all the other fields
      unchanged, and returns 0.  The (f.l_start < 0) test wrongly converts this
      to an EINVAL result.
      
      The underlying sys_fcntl function which compat_sys_fcntl and
      compat_sys_fcntl64 invoke already handles POSIX behavior correctly.  The
      additional tests in the compat wrappers are not needed.
      
      Here is a test case; its expected result is:
      
      PASS
      get flock: l_type=1, l_whence=0, l_start=145, l_len=10
      
      #include <stdlib.h>
      #include <unistd.h>
      #include <fcntl.h>
      #include <errno.h>
      #include <stdio.h>
      
      int
      main(int argc, char *argv[])
      {
          int fd;
          struct flock fl;
          char buf[255];
      
          fl.l_type = F_WRLCK;
          fl.l_whence = SEEK_END;
          fl.l_start = -100;
          fl.l_len = -10;
          /*
          fl.l_whence = SEEK_SET;
          fl.l_start = 100;
          fl.l_len = 10;
          */
      
          switch(fork()) {
      	case -1:
      	    perror("fork");
      	    exit(-1);
      
      	case 0:
      	    fd = open("/tmp/testfile", O_RDWR|O_CREAT, 0600);
      	    if (fd == -1) {
      		perror("open");
      		exit(-1);
      	    }
      
      	    if (write(fd, buf, 255) == -1) {
      		perror("write");
      		exit(-1);
      	    }
      	    if (fcntl(fd, F_SETLK, &fl) == -1) {
      		perror("F_SETLK");
      		exit(-1);
      	    }
      	    sleep(2);
      	    break;
      
      	default:
      	    sleep(1);
      	    fd = open("/tmp/testfile", O_RDWR|O_CREAT, 0600);
      	    if (fd == -1) {
      		perror("open");
      		exit(-1);
      	    }
      
      	    if (fcntl(fd, F_SETLK, &fl) != -1 || errno != EAGAIN) {
      		perror("F_SETLK");
      		exit(1);
      	    }
      
      	    fl.l_type = F_WRLCK;
      	    /*
      	    fl.l_whence = SEEK_SET;
      	    fl.l_start = 0;
      	    fl.l_len = 0;
      	    */
      	    if (fcntl(fd, F_GETLK, &fl) == -1) {
      		perror("F_GETLK");
      		printf("FAIL\n");
      		exit(-1);
      	    }
      	    printf("PASS\n");
      	    printf("get flock: l_type=%d, l_whence=%d, l_start=%zd, "
      	    	   "l_len=%zd\n", fl.l_type, fl.l_whence,
      		   (size_t) fl.l_start, (size_t) fl.l_len);
      	    break;
          }
          exit(0);
      }
      Signed-off-by: default avatarAndreas Gruenbacher <agruen@suse.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      2761f394