lkml.org 
[lkml]   [2015]   [Sep]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] staging: dgap: fix returned errno code in dgap_parsefile()
On Tue, Sep 22, 2015 at 08:38:43AM +0200, Javier Martinez Canillas wrote:
> Hello Sudip,
>
> On 09/22/2015 06:52 AM, Sudip Mukherjee wrote:
> > On Tue, Sep 22, 2015 at 02:39:36AM +0200, Javier Martinez Canillas wrote:
> >> The driver is using -1 instead of the -ENOMEM defined macro to specify
> >> that a buffer allocation failed. Since the error number is propagated,
> >> the caller will get a -EPERM which is the wrong error condition.
> > Just a little doubt. caller means the function which is calling this
> > dgap_parsefile() or you meant the user?
<snip>
>
> But I believe the patch and what the commit message says is true regardless
> of the fact that the caller is just checking for != 0. dgap_firmware_load()
> stills gets a wrong error condition whether it's checking it or not.
Yes. I just had a doubt what you meant by caller. If user then I would
have said that "patch is correct but commit message is not". :)

regards
sudip


\
 
 \ /
  Last update: 2015-09-22 09:01    [W:0.183 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site