diff options
author | Dave Airlie <airlied@redhat.com> | 2013-08-09 09:09:37 +1000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2013-08-09 09:09:37 +1000 |
commit | e42f5814212079aecd5826dba10588a896ac0862 (patch) | |
tree | c12e30ac9094addc09f2a636720ba9ab85f820a3 /mm/shmem.c | |
parent | e91abf80a0998f326107874c88d549f94839f13c (diff) | |
parent | 3f577573cd5482a32f85bd131e52f7cb4b9ac518 (diff) |
Merge tag 'drm-intel-fixes-2013-08-08' of git://people.freedesktop.org/~danvet/drm-intel into drm-fixes
Daniel writes:
A few bugfixes for serious stuff and regressions. Highlight is the
reinstated hack to keep the i915 backlight on when running on an optimus
machine, this prevents black screens especially with some radeon muxed
platforms. And the patch to quiet dmesg on Linus' old mac mini ;-)
* tag 'drm-intel-fixes-2013-08-08' of git://people.freedesktop.org/~danvet/drm-intel:
drm/i915: do not disable backlight on vgaswitcheroo switch off
drm/i915: Don't call encoder's get_config unless encoder is active
drm/i915: avoid brightness overflow when doing scale
drm/i915: update last_vblank when disabling the power well
drm/i915: fix gen4 digital port hotplug definitions
Diffstat (limited to 'mm/shmem.c')
-rw-r--r-- | mm/shmem.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/shmem.c b/mm/shmem.c index a87990cf9f9..8335dbd3fc3 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -1798,7 +1798,8 @@ static loff_t shmem_file_llseek(struct file *file, loff_t offset, int whence) } } - offset = vfs_setpos(file, offset, MAX_LFS_FILESIZE); + if (offset >= 0) + offset = vfs_setpos(file, offset, MAX_LFS_FILESIZE); mutex_unlock(&inode->i_mutex); return offset; } |