Re: [PATCH] orangefs: Dan Carpenter influenced cleanups...

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -EFAULT isn't right here.  It should propogate
> the return from orangefs_prepare_debugfs_help_string().

I'll gladly change it, but I remain confused about it.

orangefs_prepare_debugfs_help_string could potentially
return ENOMEM, which would eventually be returned to
the userspace program that called ioctl(2). ioctl's man
page doesn't list ENOMEM as a valid return code...

-Mike

On Tue, Feb 7, 2017 at 3:35 AM, Dan Carpenter <dan.carpenter@xxxxxxxxxx> wrote:
> On Mon, Feb 06, 2017 at 11:21:20AM -0500, Mike Marshall wrote:
>> @@ -996,7 +996,7 @@ int orangefs_debugfs_new_client_string(void __user *arg)
>>               if (orangefs_prepare_debugfs_help_string(0)) {
>>                       gossip_err("%s: no debug help string \n",
>>                                  __func__);
>> -                     return -EIO;
>> +                     return -EFAULT;
>>               }
>
> The rest looks nice but -EFAULT isn't right here.  It should propogate
> the return from orangefs_prepare_debugfs_help_string().
>
>                 ret = orangefs_prepare_debugfs_help_string(0);
>                 if (ret) {
>                         gossip_err("%s: no debug help string \n",
>                                    __func__);
>                         return ret;
>                 }
>
> regards,
> dan carpenter
>
>



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux