1. 20 Jul, 2011 1 commit
    • John Stultz's avatar
      time: Fix stupid KERN_WARN compile issue · cbaa5152
      John Stultz authored
      Terribly embarassing. Don't know how I committed this, but its
      KERN_WARNING not KERN_WARN.
      
      This fixes the following compile error:
      kernel/time/timekeeping.c: In function ‘__timekeeping_inject_sleeptime’:
      kernel/time/timekeeping.c:608: error: ‘KERN_WARN’ undeclared (first use in this function)
      kernel/time/timekeeping.c:608: error: (Each undeclared identifier is reported only once
      kernel/time/timekeeping.c:608: error: for each function it appears in.)
      kernel/time/timekeeping.c:608: error: expected ‘)’ before string constant
      make[2]: *** [kernel/time/timekeeping.o] Error 1
      Reported-by: default avatarIngo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
      cbaa5152
  2. 21 Jun, 2011 12 commits
    • John Stultz's avatar
      rtc: Avoid accumulating time drift in suspend/resume · 3dcad5ff
      John Stultz authored
      Because the RTC interface is only a second granular interface,
      each time we read from the RTC for suspend/resume, we introduce a
      half second (on average) of error.
      
      In order to avoid this error accumulating as the system is suspended
      over and over, this patch measures the time delta between the RTC
      and the system CLOCK_REALTIME.
      
      If the delta is less then 2 seconds from the last suspend, we compensate
      by using the previous time delta (keeping it close). If it is larger
      then 2 seconds, we assume the clock was set or has been changed, so we
      do no correction and update the delta.
      
      Note: If NTP is running, ths could seem to "fight" with the NTP corrected
      time, where as if the system time was off by 1 second, and NTP slewed the
      value in, a suspend/resume cycle could undo this correction, by trying to
      restore the previous offset from the RTC. However, without this patch,
      since each read could cause almost a full second worth of error, its
      possible to get almost 2 seconds of error just from the suspend/resume
      cycle alone, so this about equal to any offset added by the compensation.
      
      Further on systems that suspend/resume frequently, this should keep time
      closer then NTP could compensate for if the errors were allowed to
      accumulate.
      
      Credits to Arve Hjønnevåg for suggesting this solution.
      
      This patch also improves some of the variable names and adds more clear
      comments.
      
      CC: Arve Hjønnevåg <arve@android.com>
      CC: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
      3dcad5ff
    • John Stultz's avatar
      time: Avoid accumulating time drift in suspend/resume · cb33217b
      John Stultz authored
      Because the read_persistent_clock interface is usually backed by
      only a second granular interface, each time we read from the persistent
      clock for suspend/resume, we introduce a half second (on average) of error.
      
      In order to avoid this error accumulating as the system is suspended
      over and over, this patch measures the time delta between the persistent
      clock and the system CLOCK_REALTIME.
      
      If the delta is less then 2 seconds from the last suspend, we compensate
      by using the previous time delta (keeping it close). If it is larger
      then 2 seconds, we assume the clock was set or has been changed, so we
      do no correction and update the delta.
      
      Note: If NTP is running, ths could seem to "fight" with the NTP corrected
      time, where as if the system time was off by 1 second, and NTP slewed the
      value in, a suspend/resume cycle could undo this correction, by trying to
      restore the previous offset from the persistent clock.  However, without
      this patch, since each read could cause almost a full second worth of
      error, its possible to get almost 2 seconds of error just from the
      suspend/resume cycle alone, so this about equal to any offset added by
      the compensation.
      
      Further on systems that suspend/resume frequently, this should keep time
      closer then NTP could compensate for if the errors were allowed to
      accumulate.
      
      Credits to Arve Hjønnevåg for suggesting this solution.
      
      CC: Arve Hjønnevåg <arve@android.com>
      CC: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
      cb33217b
    • John Stultz's avatar
      time: Catch invalid timespec sleep values in __timekeeping_inject_sleeptime · cb5de2f8
      John Stultz authored
      Arve suggested making sure we catch possible negative sleep time
      intervals that could be passed into timekeeping_inject_sleeptime.
      
      CC: Arve Hjønnevåg <arve@android.com>
      CC: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: default avatarJohn Stultz <john.stultz@linaro.org>
      cb5de2f8
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband · e08f6d41
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
        IB/qib: Ensure that LOS and DFE are being turned off
        RDMA/cxgb4: Couple of abort fixes
        RDMA/cxgb4: Don't truncate MR lengths
        RDMA/cxgb4: Don't exceed hw IQ depth limit for user CQs
      e08f6d41
    • Linus Torvalds's avatar
      Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · 890879cf
      Linus Torvalds authored
      * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
        jbd2: Fix oops in jbd2_journal_remove_journal_head()
        jbd2: Remove obsolete parameters in the comments for some jbd2 functions
        ext4: fixed tracepoints cleanup
        ext4: use FIEMAP_EXTENT_LAST flag for last extent in fiemap
        ext4: Fix max file size and logical block counting of extent format file
        ext4: correct comments for ext4_free_blocks()
      890879cf
    • Linus Torvalds's avatar
      Linux 3.0-rc4 · 56299378
      Linus Torvalds authored
      56299378
    • Linus Torvalds's avatar
      vfs: i_state needs to be 'unsigned long' for now · 79568f5b
      Linus Torvalds authored
      Commit 13e12d14 ("vfs: reorganize 'struct inode' layout a bit")
      moved things around a bit changed i_state to be unsigned int instead of
      unsigned long.  That was to help structure layout for the 64-bit case,
      and shrink 'struct inode' a bit (admittedly that only happened when
      spinlock debugging was on and i_flags didn't pack with i_lock).
      
      However, Meelis Roos reports that this results in unaligned exceptions
      on sprc, and it turns out that the bit-locking primitives that we use
      for the I_NEW bit want to use the bitops.  Which want 'unsigned long',
      not 'unsigned int'.
      
      We really should fix the bit locking code to not have that kind of
      requirement, but that's a much bigger change.  So for now, revert that
      field back to 'unsigned long' (but keep the other re-ordering changes
      from the commit that caused this).
      
      Andi points out that we have played games with this in 'struct page', so
      it's solvable with other hacks too, but since right now the struct inode
      size advantage only happens with some rare config options, it's not
      worth fighting.
      
      It _would_ be worth fixing the bitlocking code, though.  Especially
      since there is no type safety in the bitlocking code (this never caused
      any warnings, and worked fine on x86-64, because the bitlocks take a
      'void *' and x86-64 doesn't care that deeply about alignment).  So it's
      currently a very easy problem to trigger by mistake and never notice.
      Reported-by: default avatarMeelis Roos <mroos@linux.ee>
      Cc: Andi Kleen <andi@firstfloor.org>
      Cc: David Miller <davem@davemloft.net>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      79568f5b
    • Linus Torvalds's avatar
      Merge branch 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 · f5fc5567
      Linus Torvalds authored
      * 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
        drm/radeon/kms/r6xx+: voltage fixes
        drm/nouveau: drop leftover debugging
        drm/radeon: avoid warnings from r600/eg irq handlers on powered off card.
        drm/radeon/kms: add missing param for dce3.2 DP transmitter setup
        drm/radeon/kms/atom: fix duallink on some early DCE3.2 cards
        drm/nouveau: fix assumption that semaphore dmaobj is valid in x-chan sync
        drm/nv50/disp: fix gamma with page flipping overlay turned on
        drm/nouveau/pm: Prevent overflow in nouveau_perf_init()
        drm/nouveau: fix big-endian switch
      f5fc5567
    • Linus Torvalds's avatar
      Merge branch 'msm-fix' of git://codeaurora.org/quic/kernel/davidb/linux-msm · 85d45ade
      Linus Torvalds authored
      * 'msm-fix' of git://codeaurora.org/quic/kernel/davidb/linux-msm:
        msm: timer: Fix DGT rate on 8960 and 8660
        msm: timer: compensate for timer shift in msm_read_timer_count
        msm: timer: Fix SMP build error
      85d45ade
    • Linus Torvalds's avatar
      Merge branch 'for-2.6.40' of git://linux-nfs.org/~bfields/linux · eda08410
      Linus Torvalds authored
      * 'for-2.6.40' of git://linux-nfs.org/~bfields/linux:
        nfsd4: fix break_lease flags on nfsd open
        nfsd: link returns nfserr_delay when breaking lease
        nfsd: v4 support requires CRYPTO
        nfsd: fix dependency of nfsd on auth_rpcgss
      eda08410
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 · 6e158d21
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (40 commits)
        pxa168_eth: fix race in transmit path.
        ipv4, ping: Remove duplicate icmp.h include
        netxen: fix race in skb->len access
        sgi-xp: fix a use after free
        hp100: fix an skb->len race
        netpoll: copy dev name of slaves to struct netpoll
        ipv4: fix multicast losses
        r8169: fix static initializers.
        inet_diag: fix inet_diag_bc_audit()
        gigaset: call module_put before restart of if_open()
        farsync: add module_put to error path in fst_open()
        net: rfs: enable RFS before first data packet is received
        fs_enet: fix freescale FCC ethernet dp buffer alignment
        netdev: bfin_mac: fix memory leak when freeing dma descriptors
        vlan: don't call ndo_vlan_rx_register on hardware that doesn't have vlan support
        caif: Bugfix - XOFF removed channel from caif-mux
        tun: teach the tun/tap driver to support netpoll
        dp83640: drop PHY status frames in the driver.
        dp83640: fix phy status frame event parsing
        phylib: Allow BCM63XX PHY to be selected only on BCM63XX.
        ...
      6e158d21
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6 · 36698206
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
        devcgroup_inode_permission: take "is it a device node" checks to inlined wrapper
        fix comment in generic_permission()
        kill obsolete comment for follow_down()
        proc_sys_permission() is OK in RCU mode
        reiserfs_permission() doesn't need to bail out in RCU mode
        proc_fd_permission() is doesn't need to bail out in RCU mode
        nilfs2_permission() doesn't need to bail out in RCU mode
        logfs doesn't need ->permission() at all
        coda_ioctl_permission() is safe in RCU mode
        cifs_permission() doesn't need to bail out in RCU mode
        bad_inode_permission() is safe from RCU mode
        ubifs: dereferencing an ERR_PTR in ubifs_mount()
      36698206
  3. 20 Jun, 2011 25 commits
  4. 19 Jun, 2011 2 commits