lkml.org 
[lkml]   [2019]   [Dec]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ASoC: Add MediaTek MT6660 Speaker Amp Driver
On Thu, Dec 12, 2019 at 07:08:54PM +0800, Jeff Chang wrote:
ookup("ext_dev_io", NULL);
> + if (!d->rt_root) {
> + d->rt_root = debugfs_create_dir("ext_dev_io", NULL);
> + if (!d->rt_root)
> + return -ENODEV;

No need to ever check the result of this function

> + d->rt_dir_create = true;
> + }
> + d->ic_root = debugfs_create_dir(di->dirname, d->rt_root);
> + if (!d->ic_root)
> + goto err_cleanup_rt;

Same here.

> + if (!debugfs_create_u16("reg", 0644, d->ic_root, &d->reg))
> + goto err_cleanup_ic;

No need to ever check any result of any debugfs_create_* function. In
fact, this function doesn't even return a value anymore, so if you tried
to build this against Linus's latest tree, it wouldn't work :)

thanks,

greg k-h

\
 
 \ /
  Last update: 2019-12-17 16:17    [W:0.033 / U:1.784 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site