From: Jeff Layton Date: Fri, 3 Apr 2015 13:04:03 +0000 (-0400) Subject: locks: don't allocate a lock context for an F_UNLCK request X-Git-Tag: omap-for-v4.2/o2_dc~121^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c1c669a1b2435e071d566b6db1a8e6b26542ba1;p=pandora-kernel.git locks: don't allocate a lock context for an F_UNLCK request In the event that we get an F_UNLCK request on an inode that has no lock context, there is no reason to allocate one. Change locks_get_lock_context to take a "type" pointer and avoid allocating a new context if it's F_UNLCK. Then, fix the callers to return appropriately if that function returns NULL. Signed-off-by: Jeff Layton --- Reading git-diff-tree failed