Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1464533

Use of copy_from_user in msm_gem_submit.c while holding a spin_lock

From Vaishali Thakkar <vaishali.thakkar@oracle.com>
Newsgroups linux.kernel
Subject Use of copy_from_user in msm_gem_submit.c while holding a spin_lock
Date 2016-08-17 13:50 +0200
Message-ID <s77w5-t7-13@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hello,

I was wondering about the call to copy_from_user in function submit_lookup_objects for drive
/gpu/drm/msm/msm_gem_submit.c  It calls copy_from_user[1] in a spin_lock, which is not normally
allowed, due to the possibility of a deadlock.  

Is there some reason that I am overlooking why it is OK in this case? Is there some code in the
same file which ensures that page fault will not occur when we are calling the function holding
spin_lock?

Thank you.

[1] http://lxr.free-electrons.com/source/drivers/gpu/drm/msm/msm_gem_submit.c#L85

-- 
Vaishali

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Vaishali Thakkar <vaishali.thakkar@oracle.com> - 2016-08-17 13:50 +0200
  Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-17 17:10 +0200
    Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Al Viro <viro@ZenIV.linux.org.uk> - 2016-08-17 19:10 +0200
      Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-17 20:50 +0200
        Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Al Viro <viro@ZenIV.linux.org.uk> - 2016-08-17 21:20 +0200
          Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-17 21:30 +0200
            Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Al Viro <viro@ZenIV.linux.org.uk> - 2016-08-17 21:40 +0200
              Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Daniel Vetter <daniel@ffwll.ch> - 2016-08-18 10:40 +0200
          Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-18 00:20 +0200
            Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Daniel Vetter <daniel@ffwll.ch> - 2016-08-18 11:40 +0200
              Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-18 13:00 +0200
                Re: Use of copy_from_user in msm_gem_submit.c while holding a  spin_lock Daniel Vetter <daniel@ffwll.ch> - 2016-08-18 15:10 +0200
                Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-18 15:20 +0200
        Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Rob Clark <robdclark@gmail.com> - 2016-08-17 21:20 +0200

csiph-web