Re: [PATCH] staging: axis-fifo: Fix three real issues

From: Dan Carpenter

Date: Fri Oct 23 2026 - 05:27:46 EST


On Fri, Oct 23, 2026 at 05:52:00AM -0300, Breno Rodrigues Alves wrote:
> Hi Greg,
>
> You are right, and I apologize for the noise. No tool told me this -
> it was my own reasoning. I had the (outdated) impression that passing
> an ERR_PTR parent from debugfs_create_dir() to debugfs_create_file()
> would trigger a WARN in the debugfs core. That was true years ago, but
> modern debugfs handles ERR_PTR parents gracefully, and I should have
> verified the claim on a CONFIG_DEBUG_FS=n kernel before sending the
> patch.

It's been quite that way for quite a while. Since Jan 2019.

>
> The other two changes are independent of that assumption:
>
> - the -EINVAL -> -ENOBUFS change in axis_fifo_read(), which changes
> the errno returned when the user buffer is smaller than the
> available data;

I would argue that -EINVAL is the most common error code in this
situation. I would accept other returns as well. As a reviewer I
would probably leave this up to the author.

>
> - the removal of the unused 'struct resource *r_mem' local.

This is fine as a cleanup.

regards,
dan carpenter