1. 05 Feb, 2005 9 commits
    • Jeff Garzik's avatar
      Merge pobox.com:/garz/repo/linux-2.6 · e16d7fc3
      Jeff Garzik authored
      into pobox.com:/garz/repo/libata-dev/remove-one-fix
      e16d7fc3
    • Adam J. Richter's avatar
      [PATCH] ata_pci_remove_one used freed memory · e284f9aa
      Adam J. Richter authored
      	Attempting to unload a serial ATA driver module gave me a kernel
      memory fault.  I think this problem occurs in all configurations, but
      I should mention that my configuration may be slightly unusual in that
      I configured my BIOS not to do IDE emulation with SATA disks, and I don't
      actually have any disks plugged in.
      
      	The problem was that ata_pci_remove_one would call
      scsi_host_put(ap->host), which would free the memory used to hold
      host_set->ports, but host_set->ports was used later in ata_pci_remove_one.
      
      	So, the following patch reorders some of the steps in
      ata_pci_remove_one and seems to eliminate the problem, at least to
      the extent that I can unload and reload the module, although I do not
      have a SATA disk handy for testing (I'm expecting one to arrive later
      today).
      
      	The patch actually makes the code four lines shorter, although
      two of those lines come from putting an assignement and variable
      declaration in the same line.  Since the patch is a little hard to
      read, here is a description of the edit steps.
      
      	1. Moved pci_release_regions() to toward the end of the routine
      to facilitate merging the loops before and after it.  Also, I think that
      calls that are good candidates for consolidating into the bus-level code
      in the future (instead of individual drivers) are best put at the beginning
      or end of the driver routines so that it is clearer if there would be
      problems doing such consolidation.
      
      	2. Moved the cacluation of ioaddr into the only if-branch that
      uses it.
      
      	3. Moved the call to scsi_host_put to after the code that
      checks ATA_FLAG_NO_LEGACY.
      Signed-off-by: default avatarJeff Garzik <jgarzik@pobox.com>
      e284f9aa
    • Fabio Massimo Di Nitto's avatar
      [PATCH] x86_64: parse noexec=[on|off] · 2093d532
      Fabio Massimo Di Nitto authored
      The patch fixes the noexec= boot option on x86_64 to actually work when
      other options come after it.
      
      Credits (if any ;)) should go to Matt Zimmerman and Colin Watson for
      spotting the problem and providing/testing the fix.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      2093d532
    • Andi Kleen's avatar
      [PATCH] x86-64: CONFIG_PM=n build fix · 99161612
      Andi Kleen authored
      This patch fixes a compile problem on x86-64 when CONFIG_PM is turned off. 
      Signed-off-by: default avatarAndi Kleen <ak@suse.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      99161612
    • Matthias-Christian Ott's avatar
      [PATCH] speedstep-lib.c: fix frequency multiplier for Pentium4 models 0&1 · 294eeb4f
      Matthias-Christian Ott authored
      The Pentium4 models 0&1 have a longer MSR_EBC_FREQUENCY_ID register as the
      models 2&3, so the bit shift must be bigger.
      Signed-off-by: default avatarMatthias-Christian Ott <matthias.christian@tiscali.de>
      Signed-off-by: default avatarDominik Brodowski <linux@brodo.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      294eeb4f
    • Hugh Dickins's avatar
      [PATCH] do_munmap() hugetlb fix · 3c5533e1
      Hugh Dickins authored
      The hugetlb_page test in do_munmap is too permissive.  It checks start vma,
      but forgets that end vma might be different and huge though start is not:
      so hits unmap_hugepage_range BUG if misaligned end was given.
      
      And it's too restrictive: munmap has always succeeded on unmapped areas
      within its range, why should it behave differently near a hugepage vma?
      
      And the additional checks in is_aligned_hugepage_range are irrelevant here,
      when the hugepage vma already exists.  But the function is still required
      (on some arches), as the default for prepare_hugepage_range - leave
      renaming cleanup to another occasion.
      Signed-off-by: default avatarHugh Dickins <hugh@veritas.com>
      Acked-by: default avatarWilliam Irwin <wli@holomorphy.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      3c5533e1
    • Andreas Gruenbacher's avatar
      [PATCH] Long-standing xattr sharing bug · c2a7650d
      Andreas Gruenbacher authored
      When looking for identical xattr blocks to share, we were not comparing the
      name_index fields.  This could lead to false sharing when two xattr blocks
      ended up with identical attribute names and values, and the only default
      acls.  Because acls are cached, the bug was hidden until the next reload of
      the affected inode.
      
        $ mkdir -m 700 a b
        $ setfacl -m u:bin:rwx a
      	< acl of a goes in the mbcache
      
        $ setfacl -dm u:bin:rwx b
      	< acl of b differs only in name_index, so a's acl is reused
      
        $ getfacl b
      	< shows the result from the inode cache
      
        < empty inode cache (remount, etc.)
      
        $ getfacl b
      	< shows an access acl instead of a default acl.
      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>
      c2a7650d
    • Hugh Dickins's avatar
      [PATCH] remove truncate mapped BUG · 315cbe59
      Hugh Dickins authored
      It's time to remove truncate_complete_page's BUG_ON(page_mapped(page)): it
      was there to give confidence in the new vm_truncate_count mechanism. 
      Earlier releases had no such check, and it wouldn't be at all helpful if it
      ever bugged up file truncation on a production system - though we don't
      know of any scenario in which that could happen now.
      Signed-off-by: default avatarHugh Dickins <hugh@veritas.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      315cbe59
    • Hugh Dickins's avatar
      [PATCH] tmpfs caused truncate BUG · dfceb6d6
      Hugh Dickins authored
      Just before removing truncate_complete_page's BUG_ON(page_mapped(page)),
      thought I'd recheck on a few filesystems.  The shame!  Easily triggered
      with tmpfs: not because of recent changes, but because shmem_nopage omitted
      the i_size_read from Andrea's careful truncate_count/i_size_read
      /cachelookup/truncate_count sequence.  For varying reasons, other users of
      shmem_getpage can't go beyond i_size, so just add it to shmem_nopage.
      Signed-off-by: default avatarHugh Dickins <hugh@veritas.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      dfceb6d6
  2. 04 Feb, 2005 31 commits