[alsa-devel] [PATCH] ASoC: Add MediaTek MT6660 Speaker Amp Driver
Greg KH
gregkh at linuxfoundation.org
Tue Dec 17 16:17:06 CET 2019
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
More information about the Alsa-devel
mailing list